orbithunter.core.Orbit.costgrad¶
-
Orbit.
costgrad
(eqn=None, **kwargs)[source]¶ Matrix-vector product corresponding to gradient of scalar cost functional \(1/2 F^2\)
- Parameters
- eqnOrbit
Orbit instance whose state is an evaluation of the governing equations
- kwargsdict
extra arguments for rmatvec method.
- Returns
- gradient :
Orbit instance whose state contains (dF/dv)^T * F ; (adjoint Jacobian * eqn)
Notes
Withing optimization routines, the eqn orbit is used for other calculations and hence should not be recalculated; this is why eqn is passed rather than recalculated.
Default cost functional is \(1/2 F^2\).