How to use the quadpy.t2._helpers.T2Scheme function in quadpy

To help you get started, we’ve selected a few quadpy examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github nschloe / quadpy / quadpy / t2 / _lyness_jespersen.py View on Github external
def lyness_jespersen_06():
    a0, a1 = [(3 + i * sqrt(3)) / 6 for i in [+1, -1]]

    weights, points = concat(
        s3(+frac(9, 20)), s2([-frac(1, 60), 0]), s1([+frac(1, 10), a0, a1])
    )
    return T2Scheme("Lyness-Jespersen 6", weights, points, 4, source)
github nschloe / quadpy / quadpy / t2 / _taylor_wingate_bos.py View on Github external
def taylor_wingate_bos_1():
    weights, points = s2([frac(2, 3), frac(1, 6)])
    weights /= 2
    return T2Scheme("Taylor-Wingate-Bos 1", weights, points, 2, source)
github nschloe / quadpy / quadpy / t2 / _laursen_gellert.py View on Github external
def laursen_gellert_02b():
    weights, points = s2([frac(1, 3), frac(1, 2)])
    return T2Scheme("Laursen-Gellert 2b", weights, points, 2, source)
github nschloe / quadpy / quadpy / t2 / _laursen_gellert.py View on Github external
def laursen_gellert_15a():
    weights, points = concat(
        s3(0.079894504741240),
        s2(
            [0.071123802232377, 0.425086210602091],
            [0.008223818690464, 0.023308867510000],
        ),
        s1(
            [0.045430592296170, 0.147925626209534, 0.223766973576973],
            [0.037359856234305, 0.029946031954171, 0.358740141864431],
            [0.030886656884564, 0.035632559587504, 0.143295370426867],
        ),
    )
    return T2Scheme("Laursen-Gellert 15a", weights, points, 10, source)
github nschloe / quadpy / quadpy / t2 / _liu_vinokur.py View on Github external
def liu_vinokur_03():
    weights, points = alpha([frac(1, 3), -frac(1, 2)])
    return T2Scheme("Liu-Vinokur 3", weights, points, 2, source)
github nschloe / quadpy / quadpy / t2 / _strang_fix_cowper.py View on Github external
def strang_fix_cowper_06():
    weights, points = concat(
        s3(3.0 / 8.0), s1([5.0 / 48.0, 0.736712498968435, 0.237932366472434])
    )
    return T2Scheme("Strang-Fix-Cowper 6", weights, points, 4, source)
github nschloe / quadpy / quadpy / t2 / _hammer_marlowe_stroud.py View on Github external
def hammer_marlowe_stroud_5():
    w1, w2 = [(155 - i * sqrt(15)) / 1200 for i in [+1, -1]]
    x1, x2 = [(1 + i * sqrt(15)) / 7 for i in [+1, -1]]
    weights, points = concat(s3(frac(9, 40)), r([w1, x1], [w2, x2]))
    return T2Scheme("Hammer-Marlowe-Stroud 5", weights, points, 5, source, 2.776e-16)
github nschloe / quadpy / quadpy / t2 / _witherden_vincent / __init__.py View on Github external
def witherden_vincent_13():
    return T2Scheme("Witherden-Vincent 13", *_read("wv13.json"))
github nschloe / quadpy / quadpy / t2 / _papanicolopulos / __init__.py View on Github external
def papanicolopulos_sym_4():
    return T2Scheme("Papanicolopulos 4 (full symmetry)", *_read("full04.json"))
github nschloe / quadpy / quadpy / t2 / _witherden_vincent / __init__.py View on Github external
def witherden_vincent_14():
    return T2Scheme("Witherden-Vincent 14", *_read("wv14.json"))