Nanoprogrammed Penultimate Musicianship

    triangle-quadrature

    1.0.0 • Public • Published

    triangle-quadrature

    experimental

    Gaussian quadrature for a triangle.

    Usage

    NPM

    var bunny      = require('bunny')
    var quadrature = require('triangle-quadrature')([bunny.positions[0], bunny.positions[1], bunny.positions[2])
    console.log(quadrature) # <- {positions: [...], weights: [...]}

    require("triangle-quadrature")(positions, [order = 5])

    Computes Gaussian quadrature for a triangle defined by positions (three vec3s). Optionally, you can set a custom order, higher implying greater accuracy. To actually integrate using these quadrature points, simply take a sum of your integrand at positions weighted by weights.

    Contributing

    See stackgl/contributing for details.

    License

    MIT. See LICENSE.md for details.

    Install

    npm i triangle-quadrature

    DownloadsWeekly Downloads

    4

    Version

    1.0.0

    License

    MIT

    Last publish

    Collaborators

    • ataber