login  home  contents  what's new  discussion  bug reports help  links  subscribe  changes  refresh  edit

# Edit detail for NumericalQuadrature revision 3 of 3

 1 2 3 Editor: Bill Page Time: 2015/06/02 21:09:43 GMT+0 Note:

added:
Numeric integration routines


Numeric integration routines

fricas
)sh NumericalQuadrature
NumericalQuadrature(F: FloatingPointSystem) is a package constructor
This constructor is exposed in this frame.
------------------------------- Operations --------------------------------
aromberg : ((F -> F), F, F, F, F, Integer, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)
asimpson : ((F -> F), F, F, F, F, Integer, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)
atrapezoidal : ((F -> F), F, F, F, F, Integer, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)
romberg : ((F -> F), F, F, F, F, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)
rombergo : ((F -> F), F, F, F, F, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)
simpson : ((F -> F), F, F, F, F, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)
simpsono : ((F -> F), F, F, F, F, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)
trapezoidal : ((F -> F), F, F, F, F, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)
trapezoidalo : ((F -> F), F, F, F, F, Integer, Integer) -> Record(value: F,error: F,totalpts: Integer,success: Boolean)

Example

fricas
f(x) == sin(x)
Type: Void
fricas
-- aromberg(fn, a, b, epsrel, epsabs, nmin, nmax, nint)
-- uses the adaptive romberg method to numerically integrate function
aromberg(f, -%pi, %pi, 0.0001, 0.001, 2, 5, 20)
Compiling function f with type Float -> Float