Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op > Class Template Reference

Binary expression template. More...

#include <Sacado_ELRFad_Expression.hpp>

List of all members.

Public Types

typedef ExprT1::value_type value_type_1
 Typename of the first argument value.
typedef ExprT2::value_type value_type_2
 Typename of the second argument value.
typedef Sacado::Promote< value_type_1,
value_type_2 >::type 
value_type
 Typename of the expression values.
typedef ExprT1::base_expr_type base_expr_type_1
 Typename of base-expression of first argument.
typedef ExprT2::base_expr_type base_expr_type_2
 Typename of base-expression of second argument.
typedef ExprPromote< base_expr_type_1,
base_expr_type_2 >::type 
base_expr_type
 Typename of base-expression.
typedef Op< ExprT1, ExprT2 > OpT

Public Member Functions

 BinaryExpr (const ExprT1 &expr1, const ExprT2 &expr2)
 Constructor.
int size () const
 Return size of the derivative array of the operation.
void computePartials (const value_type &bar, value_type partials[]) const
 Return partials w.r.t. arguments.
void getTangents (int i, value_type dots[]) const
 Rturn tangent component i of arguments.
value_type val () const
 Return value of operation.
template<int Arg>
value_type getTangent (int i) const
 Return tangent component i of argument Arg.
template<int Arg>
bool isActive () const
 Return whether argument is active.

Static Public Attributes

static const int num_args1 = ExprT1::num_args
 Number of arguments of left arg.
static const int num_args2 = ExprT2::num_args
 Number of arguments of right arg.
static const int num_args = num_args1 + num_args2
 Number of arguments.

Protected Attributes

ExprConstRef< ExprT1 >::type expr1_
 Left argument.
ExprConstRef< ExprT2 >::type expr2_
 Right argument.


Detailed Description

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
class Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >

Binary expression template.

This template class represents a binary operation of the form op(a1,a2) where a1 is the left argument of type ExprT1, r is the right argument of type ExprT2, and op is the operation represented by type Op. The operation is evaluated by the static methods Op::computeValue() and Op::computeDx().

Definition at line 265 of file Sacado_ELRFad_Expression.hpp.


Member Typedef Documentation

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
typedef ExprT1::value_type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::value_type_1

Typename of the first argument value.

Definition at line 270 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
typedef ExprT2::value_type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::value_type_2

Typename of the second argument value.

Definition at line 273 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
typedef Sacado::Promote<value_type_1, value_type_2>::type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::value_type

Typename of the expression values.

Definition at line 277 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
typedef ExprT1::base_expr_type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::base_expr_type_1

Typename of base-expression of first argument.

Definition at line 280 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
typedef ExprT2::base_expr_type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::base_expr_type_2

Typename of base-expression of second argument.

Definition at line 283 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
typedef ExprPromote<base_expr_type_1, base_expr_type_2>::type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::base_expr_type

Typename of base-expression.

Definition at line 287 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
typedef Op<ExprT1,ExprT2> Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::OpT

Definition at line 298 of file Sacado_ELRFad_Expression.hpp.


Constructor & Destructor Documentation

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::BinaryExpr ( const ExprT1 &  expr1,
const ExprT2 &  expr2 
) [inline]

Constructor.

Definition at line 301 of file Sacado_ELRFad_Expression.hpp.


Member Function Documentation

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
int Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::size (  )  const [inline]

Return size of the derivative array of the operation.

Definition at line 305 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
void Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::computePartials ( const value_type bar,
value_type  partials[] 
) const [inline]

Return partials w.r.t. arguments.

Definition at line 311 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
void Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::getTangents ( int  i,
value_type  dots[] 
) const [inline]

Rturn tangent component i of arguments.

Definition at line 322 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
value_type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::val (  )  const [inline]

Return value of operation.

Definition at line 327 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
template<int Arg>
value_type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::getTangent ( int  i  )  const [inline]

Return tangent component i of argument Arg.

Definition at line 332 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
template<int Arg>
bool Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::isActive (  )  const [inline]

Return whether argument is active.

Definition at line 341 of file Sacado_ELRFad_Expression.hpp.


Member Data Documentation

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
const int Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::num_args1 = ExprT1::num_args [static]

Number of arguments of left arg.

Definition at line 290 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
const int Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::num_args2 = ExprT2::num_args [static]

Number of arguments of right arg.

Definition at line 293 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
const int Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::num_args = num_args1 + num_args2 [static]

Number of arguments.

Definition at line 296 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
ExprConstRef<ExprT1>::type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::expr1_ [protected]

Left argument.

Definition at line 351 of file Sacado_ELRFad_Expression.hpp.

template<typename ExprT1, typename ExprT2, template< typename, typename > class Op>
ExprConstRef<ExprT2>::type Sacado::ELRFad::BinaryExpr< ExprT1, ExprT2, Op >::expr2_ [protected]

Right argument.

Definition at line 354 of file Sacado_ELRFad_Expression.hpp.


The documentation for this class was generated from the following file:
Generated on Tue Oct 20 12:55:13 2009 for Sacado Package Browser (Single Doxygen Collection) by doxygen 1.4.7