51 Teuchos::ParameterList& solverParams) :
56 magnitude_type eps = solverParams.get(
"Bound Perturbation Size", 1e-6);
57 magnitude_type tol = solverParams.get(
"Nonlinear Solver Tolerance", 1e-10);
58 int max_it = solverParams.get(
"Maximum Nonlinear Solver Iterations", 100);
60 value_type aa, alpha, omega, lambda;
62 double pi = 4.0*std::atan(1.0);
70 lambda = 2.0*
L/(
L*
L*omega*omega + 1.0);
72 eig_pair[i].eig_func = ExponentialOneDEigenFunction<value_type>(
78 lambda = 2.0*
L/(
L*
L*omega*omega + 1.0);
80 eig_pair[i].eig_func = ExponentialOneDEigenFunction<value_type>(
89 lambda = 2.0*
L/(
L*
L*omega*omega + 1.0);
91 eig_pair[i].eig_func = ExponentialOneDEigenFunction<value_type>(
124bisection(
const Func& func,
const value_type& a,
const value_type& b,
128 value_type fa = func.eval(a);
129 value_type fb = func.eval(b);
130 TEUCHOS_TEST_FOR_EXCEPTION(fa*fb > value_type(0.0), std::logic_error,
131 "Bounds [" << a <<
"," << b <<
"] must bracket the root!" << std::endl <<
132 "f(a) = " << fa <<
", f(b) = " << fb << std::endl)
144 value_type u = low + (hi - low)/2.0;
145 value_type
f = func.eval(u);
146 while ((Teuchos::ScalarTraits<value_type>::magnitude(hi - low) > 2.0*tol ||
147 Teuchos::ScalarTraits<value_type>::magnitude(
f) > tol) &&
154 u = low + (hi - low)/2.0;
158 TEUCHOS_TEST_FOR_EXCEPTION(nit >= max_num_its, std::logic_error,
159 "Nonlinear solver did not converge!" << std::endl);