How to use the quadpy.t2._helpers.s2 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 / _laursen_gellert.py View on Github external
def laursen_gellert_02a():
    weights, points = s2([frac(1, 3), frac(1, 6)])
    return T2Scheme("Laursen-Gellert 2a", weights, points, 2, source)
github nschloe / quadpy / quadpy / t2 / _laursen_gellert.py View on Github external
def laursen_gellert_10():
    weights, points = concat(
        s3(-0.149570044467670),
        s2(
            [+0.175615257433204, 0.260345966079038],
            [+0.053347235608839, 0.065130102902216],
        ),
        s1([+0.077113760890257, 0.638444188569809, 0.312865496004875]),
    )
    return T2Scheme("Laursen-Gellert 10", weights, points, 7, source)
github nschloe / quadpy / quadpy / t2 / _strang_fix_cowper.py View on Github external
def strang_fix_cowper_09():
    weights, points = concat(
        s2(
            [0.050844906370207, 0.063089014491502],
            [0.116786275726379, 0.249286745170910],
        ),
        s1([0.082851075618374, 0.636502499121399, 0.310352451033785]),
    )
    return T2Scheme("Strang-Fix-Cowper 9", weights, points, 6, source)
github nschloe / quadpy / quadpy / t2 / _vertex.py View on Github external
def vertex():
    weights, points = s2([frac(1, 3), 0])
    return T2Scheme("Vertex scheme", weights, points, 1)
github nschloe / quadpy / quadpy / t2 / _lyness_jespersen.py View on Github external
def lyness_jespersen_05():
    weights, points = s2(
        [3.298552309659655e-01 / 3, 9.157621350977073e-02],
        [6.701447690340345e-01 / 3, 4.459484909159649e-01],
    )
    return T2Scheme("Lyness-Jespersen 5", weights, points, 4, source)
github nschloe / quadpy / quadpy / t2 / _williams_shunn_jameson.py View on Github external
def williams_shunn_jameson_8():
    weights, points = concat(
        s2(
            [0.005639123786910, 0.021171422779465],
            [0.027148968192278, 0.100584397395888],
            [0.063100912533359, 0.271038307711932],
            [0.051752795679899, 0.440191258403832],
        ),
        s1(
            [0.009866753574646, 0.101763679498021, 0.879979641427232],
            [0.022008204800147, 0.394033271669987, 0.582562022863673],
            [0.016644570076736, 0.226245530909229, 0.751530614542782],
            [0.044326238118914, 0.635737183263105, 0.249079227621332],
        ),
    )
    return T2Scheme("Williams-Shunn-Jameson 8", weights, points, 12, source, 1.316e-12)
github nschloe / quadpy / quadpy / t2 / _laursen_gellert.py View on Github external
def laursen_gellert_07():
    weights, points = concat(
        s3(9.0 / 40.0),
        s2(
            [0.125939180544827, 0.101286507323456],
            [0.132394152788506, 0.470142064105115],
        ),
    )
    return T2Scheme("Laursen-Gellert 7", weights, points, 5, source)
github nschloe / quadpy / quadpy / t2 / _dunavant / __init__.py View on Github external
def dunavant_16():
    weights, points = concat(
        s3(0.046875697427642),
        s2(
            [0.006405878578585, 0.497380541948438],
            [0.041710296739387, 0.413469438549352],
            [0.026891484250064, 0.470458599066991],
            [0.042132522761650, 0.240553749969521],
            [0.030000266842773, 0.147965794222573],
            [0.014200098925024, 0.075465187657474],
            [0.003582462351273, 0.016596402623025],
        ),
        s1(
            [0.032773147460627, +0.103575692245252, 0.296555596579887],
            [0.015298306248441, +0.020083411655416, 0.337723063403079],
            [0.002386244192839, -0.004341002614139, 0.204748281642812],
            [0.019084792755899, +0.041941786468010, 0.189358492130623],
            [0.006850054546542, +0.014317320230681, 0.085283615682657],
        ),
    )
github nschloe / quadpy / quadpy / t2 / _seven_point.py View on Github external
def seven_point():
    weights, points = concat(
        s3(frac(9, 20)), s2([frac(1, 20), 0], [frac(2, 15), frac(1, 2)])
    )
    return T2Scheme("Seven-point scheme", weights, points, 3)
github nschloe / quadpy / quadpy / t2 / _albrecht_collatz.py View on Github external
def albrecht_collatz():
    weights, points = s2([frac(2, 30), frac(1, 2)], [frac(9, 15), frac(1, 6)])
    weights /= 2
    return T2Scheme("Albrecht-Collatz", weights, points, 3, source, 2.776e-16)