mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-01-24 14:45:14 +08:00
provide some default values for important results. So that we can read them
even before *Init() and do no get random values.
This commit is contained in:
parent
8c3f7d8e94
commit
ab88ba6f7f
@ -4,7 +4,7 @@ class HybridNonLinearSolver
|
||||
{
|
||||
public:
|
||||
HybridNonLinearSolver(FunctorType &_functor)
|
||||
: functor(_functor) {}
|
||||
: functor(_functor) { nfev=njev=iter = 0; fnorm= 0.; }
|
||||
|
||||
enum Status {
|
||||
Running = -1,
|
||||
@ -79,6 +79,7 @@ public:
|
||||
int nfev;
|
||||
int njev;
|
||||
int iter;
|
||||
Scalar fnorm;
|
||||
private:
|
||||
FunctorType &functor;
|
||||
int n;
|
||||
@ -89,7 +90,6 @@ private:
|
||||
bool jeval;
|
||||
int ncsuc;
|
||||
Scalar ratio;
|
||||
Scalar fnorm;
|
||||
Scalar pnorm, xnorm, fnorm1;
|
||||
int nslow1, nslow2;
|
||||
int ncfail;
|
||||
|
@ -4,7 +4,7 @@ class LevenbergMarquardt
|
||||
{
|
||||
public:
|
||||
LevenbergMarquardt(FunctorType &_functor)
|
||||
: functor(_functor) {}
|
||||
: functor(_functor) { nfev = njev = iter = 0; fnorm=gnorm = 0.; }
|
||||
|
||||
enum Status {
|
||||
Running = -1,
|
||||
@ -100,6 +100,7 @@ public:
|
||||
int nfev;
|
||||
int njev;
|
||||
int iter;
|
||||
Scalar fnorm, gnorm;
|
||||
private:
|
||||
FunctorType &functor;
|
||||
int n;
|
||||
@ -110,7 +111,6 @@ private:
|
||||
Scalar temp, temp1, temp2;
|
||||
Scalar delta;
|
||||
Scalar ratio;
|
||||
Scalar fnorm, gnorm;
|
||||
Scalar pnorm, xnorm, fnorm1, actred, dirder, prered;
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user