11 #ifndef OOPS_ASSIMILATION_LBMINIMIZER_H_
12 #define OOPS_ASSIMILATION_LBMINIMIZER_H_
18 #include "eckit/config/Configuration.h"
24 #include "oops/util/Logger.h"
61 template<
typename MODEL,
typename OBS>
64 int ninner = config.getInt(
"ninner");
65 double gnreduc = config.getDouble(
"gradient norm reduction");
68 gradJb_.reset(
new CtrlInc_(J_.jb().resolution(), *gradJb_));
70 gradJb_.reset(
new CtrlInc_(J_.jb()));
73 Log::info() << std::endl;
74 Log::info() << classname() <<
": max iter = " << ninner
75 <<
", requested norm reduction = " << gnreduc << std::endl;
84 J_.computeGradientFG(rhs);
85 J_.jb().multiplyB(rhs, brhs);
86 J_.jb().addGradientFG(brhs, *gradJb_);
89 Log::info() << classname() <<
" rhs" << brhs << std::endl;
97 Log::info() << classname() <<
" output increment:" << *dx << std::endl;
LB (Left B-preconditioned) Minimizers.
LBMinimizer(const CostFct_ &J)
Minimizer< MODEL, OBS > Minimizer_
LBHessianMatrix< MODEL, OBS > LBHessianMatrix_
const std::string classname() const override=0
CostFunction< MODEL, OBS > CostFct_
BMatrix< MODEL, OBS > Bmat_
std::unique_ptr< CtrlInc_ > gradJb_
virtual void solve(CtrlInc_ &, CtrlInc_ &, const LBHessianMatrix_ &, const int, const double)=0
ControlIncrement< MODEL, OBS > CtrlInc_
CtrlInc_ * doMinimize(const eckit::Configuration &) override
A Minimizer knows how to minimize a cost function.
The namespace for the main oops code.