public class Riemann extends Object implements Integrator
Constructor and Description |
---|
Riemann()
Construct an integrator.
|
Riemann(double precision,
int maxIterations)
Construct an integrator.
|
Modifier and Type | Method and Description |
---|---|
double |
getPrecision()
Get the convergence threshold.
|
double |
integrate(UnivariateRealFunction f,
double a,
double b)
Integrate function f from a to b,
\[
\int_a^b\! f(x)\, dx
\]
|
double |
integrate(UnivariateRealFunction f,
double a,
double b,
SubstitutionRule change)
Integrate a function, f, from a to b possibly using change of variable.
|
public Riemann(double precision, int maxIterations)
precision
- the convergence thresholdmaxIterations
- the maximum number of iterationspublic Riemann()
public double integrate(UnivariateRealFunction f, double a, double b)
Integrator
integrate
in interface Integrator
f
- a univariate functiona
- the lower limitb
- the upper limitpublic double integrate(UnivariateRealFunction f, double a, double b, SubstitutionRule change)
f
- a univariate functiona
- the lower limitb
- the upper limitchange
- the substitution rule; null
for a definite integral (no singularity)public double getPrecision()
Integrator
IterativeIntegrator
,
the integral is considered converged if the relative error of two successive sums is less than the threshold.getPrecision
in interface Integrator
Copyright © 2010-2020 NM FinTech Ltd.. All Rights Reserved.