mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
use operator() so that to be coherent with eigen AutoDiff functor
This commit is contained in:
@@ -157,7 +157,7 @@ HybridNonLinearSolver<FunctorType,Scalar>::solveInit(
|
||||
/* and calculate its norm. */
|
||||
|
||||
nfev = 1;
|
||||
if ( functor.f(x, fvec) < 0)
|
||||
if ( functor(x, fvec) < 0)
|
||||
return UserAksed;
|
||||
fnorm = fvec.stableNorm();
|
||||
|
||||
@@ -273,7 +273,7 @@ HybridNonLinearSolver<FunctorType,Scalar>::solveOneStep(
|
||||
|
||||
/* evaluate the function at x + p and calculate its norm. */
|
||||
|
||||
if ( functor.f(wa2, wa4) < 0)
|
||||
if ( functor(wa2, wa4) < 0)
|
||||
return UserAksed;
|
||||
++nfev;
|
||||
fnorm1 = wa4.stableNorm();
|
||||
@@ -472,7 +472,7 @@ HybridNonLinearSolver<FunctorType,Scalar>::solveNumericalDiffInit(
|
||||
/* and calculate its norm. */
|
||||
|
||||
nfev = 1;
|
||||
if ( functor.f(x, fvec) < 0)
|
||||
if ( functor(x, fvec) < 0)
|
||||
return UserAksed;
|
||||
fnorm = fvec.stableNorm();
|
||||
|
||||
@@ -590,7 +590,7 @@ HybridNonLinearSolver<FunctorType,Scalar>::solveNumericalDiffOneStep(
|
||||
|
||||
/* evaluate the function at x + p and calculate its norm. */
|
||||
|
||||
if ( functor.f(wa2, wa4) < 0)
|
||||
if ( functor(wa2, wa4) < 0)
|
||||
return UserAksed;
|
||||
++nfev;
|
||||
fnorm1 = wa4.stableNorm();
|
||||
|
||||
@@ -188,7 +188,7 @@ LevenbergMarquardt<FunctorType,Scalar>::minimizeInit(
|
||||
/* and calculate its norm. */
|
||||
|
||||
nfev = 1;
|
||||
if ( functor.f(x, fvec) < 0)
|
||||
if ( functor(x, fvec) < 0)
|
||||
return UserAsked;
|
||||
fnorm = fvec.stableNorm();
|
||||
|
||||
@@ -304,7 +304,7 @@ LevenbergMarquardt<FunctorType,Scalar>::minimizeOneStep(
|
||||
|
||||
/* evaluate the function at x + p and calculate its norm. */
|
||||
|
||||
if ( functor.f(wa2, wa4) < 0)
|
||||
if ( functor(wa2, wa4) < 0)
|
||||
return UserAsked;
|
||||
++nfev;
|
||||
fnorm1 = wa4.stableNorm();
|
||||
@@ -451,7 +451,7 @@ LevenbergMarquardt<FunctorType,Scalar>::minimizeNumericalDiffInit(
|
||||
/* and calculate its norm. */
|
||||
|
||||
nfev = 1;
|
||||
if ( functor.f(x, fvec) < 0)
|
||||
if ( functor(x, fvec) < 0)
|
||||
return UserAsked;
|
||||
fnorm = fvec.stableNorm();
|
||||
|
||||
@@ -567,7 +567,7 @@ LevenbergMarquardt<FunctorType,Scalar>::minimizeNumericalDiffOneStep(
|
||||
|
||||
/* evaluate the function at x + p and calculate its norm. */
|
||||
|
||||
if ( functor.f(wa2, wa4) < 0)
|
||||
if ( functor(wa2, wa4) < 0)
|
||||
return UserAsked;
|
||||
++nfev;
|
||||
fnorm1 = wa4.stableNorm();
|
||||
@@ -731,7 +731,7 @@ LevenbergMarquardt<FunctorType,Scalar>::minimizeOptimumStorageInit(
|
||||
/* and calculate its norm. */
|
||||
|
||||
nfev = 1;
|
||||
if ( functor.f(x, fvec) < 0)
|
||||
if ( functor(x, fvec) < 0)
|
||||
return UserAsked;
|
||||
fnorm = fvec.stableNorm();
|
||||
|
||||
@@ -865,7 +865,7 @@ LevenbergMarquardt<FunctorType,Scalar>::minimizeOptimumStorageOneStep(
|
||||
|
||||
/* evaluate the function at x + p and calculate its norm. */
|
||||
|
||||
if ( functor.f(wa2, wa4) < 0)
|
||||
if ( functor(wa2, wa4) < 0)
|
||||
return UserAsked;
|
||||
++nfev;
|
||||
fnorm1 = wa4.stableNorm();
|
||||
|
||||
@@ -32,7 +32,7 @@ int ei_fdjac1(
|
||||
if (h == 0.)
|
||||
h = eps;
|
||||
x[j] = temp + h;
|
||||
iflag = Functor.f(x, wa1);
|
||||
iflag = Functor(x, wa1);
|
||||
if (iflag < 0)
|
||||
return iflag;
|
||||
x[j] = temp;
|
||||
@@ -48,7 +48,7 @@ int ei_fdjac1(
|
||||
if (h == 0.) h = eps;
|
||||
x[j] = wa2[j] + h;
|
||||
}
|
||||
iflag = Functor.f(x, wa1);
|
||||
iflag = Functor(x, wa1);
|
||||
if (iflag < 0) {
|
||||
return iflag;
|
||||
}
|
||||
|
||||
@@ -24,7 +24,7 @@ int ei_fdjac2(
|
||||
h = eps;
|
||||
}
|
||||
x[j] = temp + h;
|
||||
iflag = Functor.f(x, wa);
|
||||
iflag = Functor(x, wa);
|
||||
if (iflag < 0)
|
||||
return iflag;
|
||||
x[j] = temp;
|
||||
|
||||
Reference in New Issue
Block a user