20 template<
typename F,
typename G>
37 template<
class F =
Real,
class G = F,
class H = F,
38 class J =
typename Realtype<F>::type>
43 H a = 1.0, H b = 1.0) :
44 frm1_(
frm1.clone()), frm2_(
frm2.clone()), a_(a), b_(b) {}
46 frm1_(frm.frm1_->clone()), frm2_(frm.frm2_->clone()),
47 a_(frm.a_), b_(frm.b_) {}
49 frm1_.reset(0); frm2_.reset(0);
52 const Real t = 0.0)
const {
53 return combine_(elm,p,t);
56 const Real t = 0.0)
const {
57 return combine_(elm,p,t);
60 const Real t = 0.0)
const {
61 return combine_(elm,p,t);
67 virtual std::ostream&
info(std::ostream&
os)
const;
70 std::unique_ptr<const ElementFormula<F,J> > frm1_;
72 std::unique_ptr<const ElementFormula<G,J> > frm2_;
78 const Real t = 0.0)
const;
81 template<
typename F,
typename G,
typename H,
typename J>
84 const P& p,
const Real t)
const {
85 F
val1 = (*frm1_)(elm, p, t);
86 G
val2 = (*frm2_)(elm, p, t);
90 template<
typename F,
typename G,
typename H,
typename J>
93 << b_ <<
" * " << *frm2_ <<
")";
125 template<
typename F,
typename G,
typename H>
130 frm1_(
frm1.clone()), frm2_(
frm2.clone()) {}
132 frm1_(frm.frm1_->clone()), frm2_(frm.frm2_->clone()) {}
134 frm1_.reset(0); frm2_.reset(0);
137 const Real t = 0.0)
const {
138 return compose_(elm,p,t);
141 const Real t = 0.0)
const {
142 return compose_(elm,p,t);
145 const Real t = 0.0)
const {
146 return compose_(elm,p,t);
152 virtual std::ostream&
info(std::ostream&
os)
const;
154 std::unique_ptr<const ElementFormula<H,G> > frm1_, frm2_;
160 template<
typename F,
typename G,
typename H>
163 const P& p,
const Real t)
const {
164 return F((*frm1_)(elm,p,t),(*frm2_)(elm,p,t));
167 template<
typename F,
typename G,
typename H>
187 const Real t = 0.0)
const;
189 const Real t = 0.0)
const;
191 const Real t = 0.0)
const;
195 virtual std::ostream&
info(std::ostream&
os)
const;
216 const Real p,
const Real t = 0.0)
const;
226 virtual std::ostream&
info(std::ostream&
os)
const;
243 template<
class F = Real>
269 const Real p,
const Real t = 0.0)
const;
274 return (*
this)(elm, p[0], t);
277 virtual F operator() (
const ElementWithCell<Real>& elm,
278 const Real3d& p,
const Real t = 0.0)
const {
281 return (*
this)(elm, p[0], t);
284 virtual std::ostream&
info(std::ostream&
os)
const;
boundaryTypes
The different boundary condition types.
RCP< const ElementFormula< Point< F, 2 > > > frm() const
Returns the vectorial formula.
RCP< const ElementFormula< Point< F, 2 > > > & frm()
Access to the vectorial formula.
virtual FrmE_ScalarProductNormalEdge2d * clone() const
Virtual copy constructor.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
std::string typeOf(const T &t)
Set< F > makeSet(uint n, const F &first,...)