|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.math3.ode.JacobianMatrices.MainStateJacobianWrapper
private static class JacobianMatrices.MainStateJacobianWrapper
Wrapper class to compute jacobian matrices by finite differences for ODE which do not compute them by themselves.
Field Summary | |
---|---|
private double[] |
hY
Steps for finite difference computation of the jacobian df/dy w.r.t. |
private FirstOrderDifferentialEquations |
ode
Raw ODE without jacobians computation skill to be wrapped into a MainStateJacobianProvider. |
Constructor Summary | |
---|---|
JacobianMatrices.MainStateJacobianWrapper(FirstOrderDifferentialEquations ode,
double[] hY)
Wrap a FirstOrderDifferentialEquations into a MainStateJacobianProvider . |
Method Summary | |
---|---|
void |
computeDerivatives(double t,
double[] y,
double[] yDot)
Get the current time derivative of the state vector. |
void |
computeMainStateJacobian(double t,
double[] y,
double[] yDot,
double[][] dFdY)
Compute the jacobian matrix of ODE with respect to main state. |
int |
getDimension()
Get the dimension of the problem. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private final FirstOrderDifferentialEquations ode
private final double[] hY
Constructor Detail |
---|
public JacobianMatrices.MainStateJacobianWrapper(FirstOrderDifferentialEquations ode, double[] hY) throws DimensionMismatchException
FirstOrderDifferentialEquations
into a MainStateJacobianProvider
.
ode
- original ODE problem, without jacobians computation skillhY
- step sizes to compute the jacobian df/dy
DimensionMismatchException
- if there is a dimension mismatch between
the steps array hY
and the equation dimensionJacobianMatrices#setMainStateSteps(double[])
Method Detail |
---|
public int getDimension()
getDimension
in interface FirstOrderDifferentialEquations
public void computeDerivatives(double t, double[] y, double[] yDot) throws MaxCountExceededException, DimensionMismatchException
computeDerivatives
in interface FirstOrderDifferentialEquations
t
- current value of the independent time variabley
- array containing the current value of the state vectoryDot
- placeholder array where to put the time derivative of the state vector
MaxCountExceededException
- if the number of functions evaluations is exceeded
DimensionMismatchException
- if arrays dimensions do not match equations settingspublic void computeMainStateJacobian(double t, double[] y, double[] yDot, double[][] dFdY) throws MaxCountExceededException, DimensionMismatchException
computeMainStateJacobian
in interface MainStateJacobianProvider
t
- current value of the independent time variabley
- array containing the current value of the main state vectoryDot
- array containing the current value of the time derivative of the main state vectordFdY
- placeholder array where to put the jacobian matrix of the ODE w.r.t. the main state vector
MaxCountExceededException
- if the number of functions evaluations is exceeded
DimensionMismatchException
- if arrays dimensions do not match equations settings
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |