36 #ifndef EXPRESSION_SCALAR_HPP 37 #define EXPRESSION_SCALAR_HPP 39 #include <lifev/core/LifeV.hpp> 41 #include <lifev/eta/expression/ExpressionBase.hpp> 48 namespace ExpressionAssembly
55 class ExpressionScalar :
public ExpressionBase<ExpressionScalar>
71 ExpressionScalar (
const Real& myValue);
74 ExpressionScalar (
const ExpressionScalar& expr);
86 static void display (std::ostream& out = std::cout);
95 const Real& value()
const;
116 inline ExpressionScalar
119 return ExpressionScalar (myValue);
128 template<
typename VectorType>
129 class ExpressionExtractScalar :
public ExpressionBase<ExpressionExtractScalar<VectorType> >
137 typedef std::shared_ptr<VectorType> containerPtr_Type;
146 ExpressionExtractScalar (
const VectorType& myVector)
147 : base_Type(), M_vector (
new VectorType (myVector) ) {}
150 ExpressionExtractScalar (
const ExpressionExtractScalar<VectorType>& expr)
151 : base_Type(), M_vector ( expr.vector() ) {}
154 ~ExpressionExtractScalar() {}
163 static void display (std::ostream& out = std::cout);
172 const containerPtr_Type vector()
const 185 ExpressionExtractScalar();
189 containerPtr_Type M_vector;
196 template<
typename VectorType>
197 inline ExpressionExtractScalar<VectorType>
198 parameter (
const VectorType& myVector)
200 return ExpressionExtractScalar<VectorType> ( myVector );
void updateInverseJacobian(const UInt &iQuadPt)
double Real
Generic real data.
class ExpressionBase Base class (static polymorphism, CRTP sense) for all the expressions used in ass...