65 template<
class ScalarT>
83 template<
class ScalarT>
86 Teuchos::RCP<const std::vector<ScalarT> > xp =
96 for(
int i=0; i<n; ++i) {
97 xdotx += pow((*xp)[i],2);
98 kdotx += double(i+1)*(*xp)[i];
102 J = xdotx + pow(kdotx,2)/4.0 + pow(kdotx,4)/16.0;
Defines the linear algebra or vector space interface.
Provides the std::vector implementation of the ROL::Vector interface.
ScalarT value(const Vector< ScalarT > &x, Real &tol)
A Sacado-accessible version of the Zakharov function to differentiate Where .