56 const int localDim,
const double &pt,
const double &p0,
const double &scale
58 :epetra_comm_(comm), scale_(scale)
153 using Teuchos::rcp_dynamic_cast;
165 const RCP<Epetra_Vector> g_out = outArgs.
get_g(0);
167 const RCP<Epetra_MultiVector> DgDp_trans_out =
179 p_minus_pt.Update(-1.0, *
pt_, 1.0);
183 p_minus_pt.Dot(p_minus_pt, dot);
184 (*g_out)[0] =
scale_ * 0.5 * dot[0];
188 (*DgDp_trans_out) = p_minus_pt;
189 DgDp_trans_out->Scale(
scale_);
Teuchos::RCP< const Epetra_Map > get_x_map() const
Evaluation< Epetra_Vector > get_g(int j) const
Get g(j) where 0 <= j && j < this->Ng().
void setSupports(EOutArgsMembers arg, bool supports=true)
Teuchos::RCP< Epetra_MultiVector > get_DgDp_mv(const int j, const int l, const ModelEvaluator::OutArgs &outArgs, const ModelEvaluator::EDerivativeMultiVectorOrientation mvOrientation)
Teuchos::RCP< const Epetra_Map > get_f_map() const
InArgs createInArgs() const
Teuchos::RCP< const Epetra_Vector > get_p(int l) const
void set_DgDp_properties(int j, int l, const DerivativeProperties &properties)
OutArgs createOutArgs() const
void setModelEvalDescription(const std::string &modelEvalDescription)
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
void evalModel(const InArgs &inArgs, const OutArgs &outArgs) const
Teuchos::RCP< const Epetra_Vector > get_p_init(int l) const
T_To & dyn_cast(T_From &from)
virtual std::string description() const
Teuchos::RCP< Epetra_Vector > pt_
void setModelEvalDescription(const std::string &modelEvalDescription)
Teuchos::RCP< const Epetra_Map > map_p_
Teuchos::RCP< const Epetra_Map > map_g_
Teuchos::RCP< const Epetra_Map > get_p_map(int l) const
.
bool nonnull(const boost::shared_ptr< T > &p)
Teuchos::RCP< const Epetra_Map > get_g_map(int j) const
.
Teuchos::RCP< Epetra_Vector > p0_
void set_Np_Ng(int Np, int Ng)
#define TEUCHOS_TEST_FOR_EXCEPT(throw_exception_test)
DiagonalQuadraticResponseOnlyModelEvaluator()