Chemical Data Processing Library C++ API - Version 1.4.0
GridExpression.hpp
Go to the documentation of this file.
1 /*
2  * GridExpression.hpp
3  *
4  * Copyright (C) 2003 Thomas Seidel <thomas.seidel@univie.ac.at>
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public License
17  * along with this library; see the file COPYING. If not, write to
18  * the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19  * Boston, MA 02111-1307, USA.
20  */
21 
27 #ifndef CDPL_MATH_GRIDEXPRESSION_HPP
28 #define CDPL_MATH_GRIDEXPRESSION_HPP
29 
30 #include <type_traits>
31 
32 #include "CDPL/Math/Check.hpp"
33 #include "CDPL/Math/Expression.hpp"
34 #include "CDPL/Math/CommonType.hpp"
35 #include "CDPL/Math/Functional.hpp"
36 #include "CDPL/Math/TypeTraits.hpp"
37 #include "CDPL/Base/Exceptions.hpp"
38 
39 
40 namespace CDPL
41 {
42 
43  namespace Math
44  {
45 
46  template <typename C>
47  class GridContainer;
48 
54  template <typename E, typename F>
55  class GridUnary : public GridExpression<GridUnary<E, F> >
56  {
57 
58  typedef GridUnary<E, F> SelfType;
59  typedef F FunctorType;
60  typedef E ExpressionType;
61  typedef typename E::ConstClosureType ExpressionClosureType;
62 
63  public:
65  typedef typename F::ResultType ValueType;
67  typedef const ValueType ConstReference;
69  typedef const ValueType Reference;
71  typedef const SelfType ConstClosureType;
75  typedef typename E::SizeType SizeType;
77  typedef typename E::DifferenceType DifferenceType;
78 
84  expr(e) {}
85 
91  {
92  return expr.getSize1();
93  }
94 
100  {
101  return expr.getSize2();
102  }
103 
109  {
110  return expr.getSize3();
111  }
112 
121  {
122  return FunctorType::apply(expr(i, j, k));
123  }
124 
125  private:
126  ExpressionClosureType expr;
127  };
128 
134  template <typename E, typename F>
136  {
137 
142  };
143 
150  template <typename E1, typename E2, typename F>
151  class GridBinary1 : public GridExpression<GridBinary1<E1, E2, F> >
152  {
153 
155  typedef F FunctorType;
156  typedef E1 Expression1Type;
157  typedef E2 Expression2Type;
158  typedef typename E1::ConstClosureType Expression1ClosureType;
159  typedef typename E2::ConstClosureType Expression2ClosureType;
160 
161  public:
163  typedef typename F::ResultType ValueType;
165  typedef const ValueType ConstReference;
167  typedef const ValueType Reference;
169  typedef const SelfType ConstClosureType;
176 
182  GridBinary1(const Expression1Type& e1, const Expression2Type& e2):
183  expr1(e1), expr2(e2) {}
184 
191  {
192  return CDPL_MATH_CHECK_SIZE_EQUALITY(SizeType(expr1.getSize1()), SizeType(expr2.getSize1()), Base::SizeError);
193  }
194 
201  {
202  return CDPL_MATH_CHECK_SIZE_EQUALITY(SizeType(expr1.getSize2()), SizeType(expr2.getSize2()), Base::SizeError);
203  }
204 
211  {
212  return CDPL_MATH_CHECK_SIZE_EQUALITY(SizeType(expr1.getSize3()), SizeType(expr2.getSize3()), Base::SizeError);
213  }
214 
223  {
224  return FunctorType::apply(expr1(i, j, k), expr2(i, j, k));
225  }
226 
227  private:
228  Expression1ClosureType expr1;
229  Expression2ClosureType expr2;
230  };
231 
238  template <typename E1, typename E2, typename F>
240  {
241 
246  };
247 
254  template <typename E1, typename E2, typename F>
255  class Scalar1GridBinary : public GridExpression<Scalar1GridBinary<E1, E2, F> >
256  {
257 
259  typedef F FunctorType;
260  typedef E1 Expression1Type;
261  typedef E2 Expression2Type;
262  typedef const E1 Expression1ClosureType;
263  typedef typename E2::ConstClosureType Expression2ClosureType;
264 
265  public:
267  typedef typename F::ResultType ValueType;
269  typedef const ValueType ConstReference;
271  typedef const ValueType Reference;
273  typedef const SelfType ConstClosureType;
277  typedef typename E2::SizeType SizeType;
279  typedef typename E2::DifferenceType DifferenceType;
280 
286  Scalar1GridBinary(const Expression1Type& e1, const Expression2Type& e2):
287  expr1(e1), expr2(e2) {}
288 
294  {
295  return expr2.getSize1();
296  }
297 
303  {
304  return expr2.getSize2();
305  }
306 
312  {
313  return expr2.getSize3();
314  }
315 
324  {
325  return FunctorType::apply(expr1, expr2(i, j, k));
326  }
327 
328  private:
329  Expression1ClosureType expr1;
330  Expression2ClosureType expr2;
331  };
332 
339  template <typename E1, typename E2, typename F>
341  {
342 
347  };
348 
355  template <typename E1, typename E2, typename F>
356  class Scalar2GridBinary : public GridExpression<Scalar2GridBinary<E1, E2, F> >
357  {
358 
360  typedef F FunctorType;
361  typedef E1 Expression1Type;
362  typedef E2 Expression2Type;
363  typedef typename E1::ConstClosureType Expression1ClosureType;
364  typedef const E2 Expression2ClosureType;
365 
366  public:
368  typedef typename F::ResultType ValueType;
370  typedef const ValueType ConstReference;
372  typedef const ValueType Reference;
374  typedef const SelfType ConstClosureType;
378  typedef typename E1::SizeType SizeType;
380  typedef typename E1::DifferenceType DifferenceType;
381 
387  Scalar2GridBinary(const Expression1Type& e1, const Expression2Type& e2):
388  expr1(e1), expr2(e2) {}
389 
395  {
396  return expr1.getSize1();
397  }
398 
404  {
405  return expr1.getSize2();
406  }
407 
413  {
414  return expr1.getSize3();
415  }
416 
425  {
426  return FunctorType::apply(expr1(i, j, k), expr2);
427  }
428 
429  private:
430  Expression1ClosureType expr1;
431  Expression2ClosureType expr2;
432  };
433 
440  template <typename E1, typename E2, typename F>
442  {
443 
448  };
449 
456  template <typename E>
459  {
460  typedef typename GridUnaryTraits<E, ScalarNegation<typename E::ValueType> >::ExpressionType ExpressionType;
461 
462  return ExpressionType(e());
463  }
464 
471  template <typename E>
472 
473  const E&
475  {
476  return e();
477  }
478 
487  template <typename E1, typename E2>
488  typename GridBinary1Traits<E1, E2, ScalarAddition<typename E1::ValueType, typename E2::ValueType> >::ResultType
490  {
491  typedef typename GridBinary1Traits<E1, E2,
493 
494  return ExpressionType(e1(), e2());
495  }
496 
505  template <typename E1, typename E2>
506  typename GridBinary1Traits<E1, E2, ScalarSubtraction<typename E1::ValueType, typename E2::ValueType> >::ResultType
508  {
509  typedef typename GridBinary1Traits<E1, E2,
511 
512  return ExpressionType(e1(), e2());
513  }
514 
523  template <typename E, typename T>
524  typename std::enable_if<IsScalar<T>::value, typename Scalar2GridBinaryTraits<E, T, ScalarMultiplication<typename E::ValueType, T> >::ResultType>::type
525  operator*(const GridExpression<E>& e, const T& t)
526  {
527  typedef typename Scalar2GridBinaryTraits<E, T,
528  ScalarMultiplication<typename E::ValueType, T> >::ExpressionType ExpressionType;
529 
530  return ExpressionType(e(), t);
531  }
532 
541  template <typename T, typename E>
542  typename std::enable_if<IsScalar<T>::value, typename Scalar1GridBinaryTraits<T, E, ScalarMultiplication<T, typename E::ValueType> >::ResultType>::type
543  operator*(const T& t, const GridExpression<E>& e)
544  {
545  typedef typename Scalar1GridBinaryTraits<T, E,
546  ScalarMultiplication<T, typename E::ValueType> >::ExpressionType ExpressionType;
547 
548  return ExpressionType(t, e());
549  }
550 
559  template <typename E, typename T>
560  typename std::enable_if<IsScalar<T>::value, typename Scalar2GridBinaryTraits<E, T, ScalarDivision<typename E::ValueType, T> >::ResultType>::type
561  operator/(const GridExpression<E>& e, const T& t)
562  {
563  typedef typename Scalar2GridBinaryTraits<E, T,
564  ScalarDivision<typename E::ValueType, T> >::ExpressionType ExpressionType;
565 
566  return ExpressionType(e(), t);
567  }
568 
577  template <typename E1, typename E2>
580  {
581  return GridEquality<E1, E2>::apply(e1, e2);
582  }
583 
592  template <typename E1, typename E2>
595  {
596  return !GridEquality<E1, E2>::apply(e1, e2);
597  }
598 
609  template <typename E1, typename E2, typename T>
610  typename std::enable_if<std::is_arithmetic<T>::value, typename GridToleranceEquality<E1, E2, T>::ResultType>::type
611  equals(const GridExpression<E1>& e1, const GridExpression<E2>& e2, const T& eps)
612  {
613  return GridToleranceEquality<E1, E2, T>::apply(e1, e2, eps);
614  }
615 
622  template <typename E>
623  typename GridUnaryTraits<E, ScalarConjugation<typename E::ValueType> >::ResultType
625  {
626  typedef typename GridUnaryTraits<E, ScalarConjugation<typename E::ValueType> >::ExpressionType ExpressionType;
627 
628  return ExpressionType(e());
629  }
630 
637  template <typename E>
638  typename GridUnaryTraits<E, ScalarConjugation<typename E::ValueType> >::ResultType
640  {
641  typedef typename GridUnaryTraits<E, ScalarConjugation<typename E::ValueType> >::ExpressionType ExpressionType;
642 
643  return ExpressionType(e());
644  }
645 
652  template <typename E>
653  typename GridUnaryTraits<E, ScalarReal<typename E::ValueType> >::ResultType
655  {
656  typedef typename GridUnaryTraits<E, ScalarReal<typename E::ValueType> >::ExpressionType ExpressionType;
657 
658  return ExpressionType(e());
659  }
660 
667  template <typename E>
668  typename GridUnaryTraits<E, ScalarImaginary<typename E::ValueType> >::ResultType
670  {
671  typedef typename GridUnaryTraits<E, ScalarImaginary<typename E::ValueType> >::ExpressionType ExpressionType;
672 
673  return ExpressionType(e());
674  }
675 
684  template <typename E1, typename E2>
685  typename GridBinary1Traits<E1, E2, ScalarDivision<typename E1::ValueType, typename E2::ValueType> >::ResultType
687  {
688  typedef typename GridBinary1Traits<E1, E2,
690 
691  return ExpressionType(e1(), e2());
692  }
693 
702  template <typename E1, typename E2>
703  typename GridBinary1Traits<E1, E2, ScalarMultiplication<typename E1::ValueType, typename E2::ValueType> >::ResultType
705  {
706  typedef typename GridBinary1Traits<E1, E2,
708 
709  return ExpressionType(e1(), e2());
710  }
711 
718  template <typename E>
721  {
722  return GridElementSum<E>::apply(e);
723  }
724  } // namespace Math
725 } // namespace CDPL
726 
727 #endif // CDPL_MATH_GRIDEXPRESSION_HPP
Definition of exception classes.
Definition of various preprocessor macros for error checking.
#define CDPL_MATH_CHECK_SIZE_EQUALITY(size1, size2, e)
Throws the exception e if size1 differs from size2, otherwise returns std::min(size1,...
Definition: Check.hpp:84
Common type deduction.
Definition of basic expression types.
Definition of various functors.
Definition of type traits.
Thrown to indicate that the size of a (multidimensional) array is not correct.
Definition: Base/Exceptions.hpp:133
E ExpressionType
The derived expression type (made available to expression-template machinery).
Definition: Expression.hpp:47
Expression-template node combining two grid expressions E1 and E2 element-wise via the binary functor...
Definition: GridExpression.hpp:152
F::ResultType ValueType
The element value type of the expression (the functor's result type).
Definition: GridExpression.hpp:163
CommonType< typename E1::SizeType, typename E2::SizeType >::Type SizeType
The common size type of the two wrapped expressions.
Definition: GridExpression.hpp:173
ConstReference operator()(SizeType i, SizeType j, SizeType k) const
Applies the binary functor to the elements at (i, j, k) of the two wrapped expressions and returns th...
Definition: GridExpression.hpp:222
GridBinary1(const Expression1Type &e1, const Expression2Type &e2)
Constructs the expression-template node wrapping e1 and e2.
Definition: GridExpression.hpp:182
SizeType getSize1() const
Returns the size along the first dimension after verifying that both wrapped expressions agree on it.
Definition: GridExpression.hpp:190
const ValueType ConstReference
Constant reference type to an element value.
Definition: GridExpression.hpp:165
SelfType ClosureType
Closure type used when this expression appears inside another expression.
Definition: GridExpression.hpp:171
CommonType< typename E1::DifferenceType, typename E2::DifferenceType >::Type DifferenceType
The common signed difference type of the two wrapped expressions.
Definition: GridExpression.hpp:175
const SelfType ConstClosureType
Constant closure type used when this expression appears inside another expression.
Definition: GridExpression.hpp:169
SizeType getSize3() const
Returns the size along the third dimension after verifying that both wrapped expressions agree on it.
Definition: GridExpression.hpp:210
const ValueType Reference
Mutable reference type (degrades to const for expression-template results).
Definition: GridExpression.hpp:167
SizeType getSize2() const
Returns the size along the second dimension after verifying that both wrapped expressions agree on it...
Definition: GridExpression.hpp:200
CRTP base class for all grid expression types.
Definition: Expression.hpp:180
Expression-template node applying a unary functor F element-wise to a grid expression E.
Definition: GridExpression.hpp:56
E::SizeType SizeType
The size type inherited from the wrapped expression.
Definition: GridExpression.hpp:75
SizeType getSize2() const
Returns the size of the wrapped grid expression along the second dimension.
Definition: GridExpression.hpp:99
const SelfType ConstClosureType
Constant closure type used when this expression appears inside another expression.
Definition: GridExpression.hpp:71
SizeType getSize1() const
Returns the size of the wrapped grid expression along the first dimension.
Definition: GridExpression.hpp:90
SizeType getSize3() const
Returns the size of the wrapped grid expression along the third dimension.
Definition: GridExpression.hpp:108
SelfType ClosureType
Closure type used when this expression appears inside another expression.
Definition: GridExpression.hpp:73
E::DifferenceType DifferenceType
The signed difference type inherited from the wrapped expression.
Definition: GridExpression.hpp:77
GridUnary(const ExpressionType &e)
Constructs the expression-template node wrapping e.
Definition: GridExpression.hpp:83
ConstReference operator()(SizeType i, SizeType j, SizeType k) const
Applies the unary functor to the element at (i, j, k) of the wrapped expression and returns the resul...
Definition: GridExpression.hpp:120
const ValueType ConstReference
Constant reference type to an element value.
Definition: GridExpression.hpp:67
const ValueType Reference
Mutable reference type (degrades to const for expression-template results).
Definition: GridExpression.hpp:69
F::ResultType ValueType
The element value type of the expression (the functor's result type).
Definition: GridExpression.hpp:65
Expression-template node combining a scalar E1 (lhs) and a grid expression E2 (rhs) element-wise via ...
Definition: GridExpression.hpp:256
SizeType getSize2() const
Returns the size of the wrapped grid expression along the second dimension.
Definition: GridExpression.hpp:302
const SelfType ConstClosureType
Constant closure type used when this expression appears inside another expression.
Definition: GridExpression.hpp:273
F::ResultType ValueType
The element value type of the expression (the functor's result type).
Definition: GridExpression.hpp:267
SizeType getSize3() const
Returns the size of the wrapped grid expression along the third dimension.
Definition: GridExpression.hpp:311
Scalar1GridBinary(const Expression1Type &e1, const Expression2Type &e2)
Constructs the expression-template node combining the scalar e1 and the grid expression e2.
Definition: GridExpression.hpp:286
E2::DifferenceType DifferenceType
The signed difference type inherited from the wrapped grid expression.
Definition: GridExpression.hpp:279
const ValueType ConstReference
Constant reference type to an element value.
Definition: GridExpression.hpp:269
ConstReference operator()(SizeType i, SizeType j, SizeType k) const
Applies the binary functor to the scalar and the element at (i, j, k) of the wrapped grid expression ...
Definition: GridExpression.hpp:323
E2::SizeType SizeType
The size type inherited from the wrapped grid expression.
Definition: GridExpression.hpp:277
SizeType getSize1() const
Returns the size of the wrapped grid expression along the first dimension.
Definition: GridExpression.hpp:293
SelfType ClosureType
Closure type used when this expression appears inside another expression.
Definition: GridExpression.hpp:275
const ValueType Reference
Mutable reference type (degrades to const for expression-template results).
Definition: GridExpression.hpp:271
Expression-template node combining a grid expression E1 (lhs) and a scalar E2 (rhs) element-wise via ...
Definition: GridExpression.hpp:357
E1::SizeType SizeType
The size type inherited from the wrapped grid expression.
Definition: GridExpression.hpp:378
const ValueType Reference
Mutable reference type (degrades to const for expression-template results).
Definition: GridExpression.hpp:372
ConstReference operator()(SizeType i, SizeType j, SizeType k) const
Applies the binary functor to the element at (i, j, k) of the wrapped grid expression and the scalar ...
Definition: GridExpression.hpp:424
SizeType getSize2() const
Returns the size of the wrapped grid expression along the second dimension.
Definition: GridExpression.hpp:403
const SelfType ConstClosureType
Constant closure type used when this expression appears inside another expression.
Definition: GridExpression.hpp:374
SizeType getSize3() const
Returns the size of the wrapped grid expression along the third dimension.
Definition: GridExpression.hpp:412
SizeType getSize1() const
Returns the size of the wrapped grid expression along the first dimension.
Definition: GridExpression.hpp:394
Scalar2GridBinary(const Expression1Type &e1, const Expression2Type &e2)
Constructs the expression-template node combining the grid expression e1 and the scalar e2.
Definition: GridExpression.hpp:387
SelfType ClosureType
Closure type used when this expression appears inside another expression.
Definition: GridExpression.hpp:376
F::ResultType ValueType
The element value type of the expression (the functor's result type).
Definition: GridExpression.hpp:368
const ValueType ConstReference
Constant reference type to an element value.
Definition: GridExpression.hpp:370
E1::DifferenceType DifferenceType
The signed difference type inherited from the wrapped grid expression.
Definition: GridExpression.hpp:380
constexpr unsigned int T
Specifies Hydrogen (Tritium).
Definition: AtomType.hpp:67
constexpr unsigned int F
Specifies Fluorine.
Definition: AtomType.hpp:107
constexpr unsigned int E
Specifies that the stereocenter has E configuration.
Definition: CIPDescriptor.hpp:96
GridBinary1Traits< E1, E2, ScalarMultiplication< typename E1::ValueType, typename E2::ValueType > >::ResultType elemProd(const GridExpression< E1 > &e1, const GridExpression< E2 > &e2)
Returns the element-wise product of the grid expressions e1 and e2 (Hadamard product).
Definition: GridExpression.hpp:704
GridUnaryTraits< E, ScalarConjugation< typename E::ValueType > >::ResultType herm(const GridExpression< E > &e)
Returns the Hermitian conjugate of the grid expression e (alias of conj() for grids).
Definition: GridExpression.hpp:639
GridUnaryTraits< E, ScalarConjugation< typename E::ValueType > >::ResultType conj(const GridExpression< E > &e)
Returns the element-wise complex conjugate of the grid expression e (identity for real-valued grids).
Definition: GridExpression.hpp:624
std::enable_if< std::is_arithmetic< T >::value, typename GridToleranceEquality< E1, E2, T >::ResultType >::type equals(const GridExpression< E1 > &e1, const GridExpression< E2 > &e2, const T &eps)
Tells whether the grid expressions e1 and e2 agree element-wise within the absolute tolerance eps.
Definition: GridExpression.hpp:611
std::enable_if< IsScalar< T >::value, typename Scalar2GridBinaryTraits< E, T, ScalarDivision< typename E::ValueType, T > >::ResultType >::type operator/(const GridExpression< E > &e, const T &t)
Returns the element-wise quotient of the grid expression e by the scalar t.
Definition: GridExpression.hpp:561
GridUnaryTraits< E, ScalarReal< typename E::ValueType > >::ResultType real(const GridExpression< E > &e)
Returns the element-wise real part of the grid expression e.
Definition: GridExpression.hpp:654
GridEquality< E1, E2 >::ResultType operator!=(const GridExpression< E1 > &e1, const GridExpression< E2 > &e2)
Tells whether the grid expressions e1 and e2 differ in at least one element.
Definition: GridExpression.hpp:594
GridEquality< E1, E2 >::ResultType operator==(const GridExpression< E1 > &e1, const GridExpression< E2 > &e2)
Tells whether the grid expressions e1 and e2 are element-wise equal.
Definition: GridExpression.hpp:579
std::enable_if< IsScalar< T >::value, typename Scalar2GridBinaryTraits< E, T, ScalarMultiplication< typename E::ValueType, T > >::ResultType >::type operator*(const GridExpression< E > &e, const T &t)
Returns the element-wise product of the grid expression e and the scalar t.
Definition: GridExpression.hpp:525
GridBinary1Traits< E1, E2, ScalarDivision< typename E1::ValueType, typename E2::ValueType > >::ResultType elemDiv(const GridExpression< E1 > &e1, const GridExpression< E2 > &e2)
Returns the element-wise quotient of the grid expressions e1 and e2.
Definition: GridExpression.hpp:686
GridUnaryTraits< E, ScalarImaginary< typename E::ValueType > >::ResultType imag(const GridExpression< E > &e)
Returns the element-wise imaginary part of the grid expression e.
Definition: GridExpression.hpp:669
GridUnaryTraits< E, ScalarNegation< typename E::ValueType > >::ResultType operator-(const GridExpression< E > &e)
Returns the element-wise negation of the grid expression e.
Definition: GridExpression.hpp:458
GridElementSum< E >::ResultType sum(const GridExpression< E > &e)
Returns the sum of all elements of the grid expression e.
Definition: GridExpression.hpp:720
const E & operator+(const GridExpression< E > &e)
Returns the grid expression e unchanged (unary +).
Definition: GridExpression.hpp:474
The namespace of the Chemical Data Processing Library.
std::common_type< T1, T2 >::type Type
The common type.
Definition: CommonType.hpp:49
Traits selecting the expression-template node and its result type for the Math::GridBinary1 instantia...
Definition: GridExpression.hpp:240
GridBinary1< E1, E2, F > ExpressionType
The expression-template node type.
Definition: GridExpression.hpp:243
ExpressionType ResultType
The expression-template result type returned by free-function operators.
Definition: GridExpression.hpp:245
GridScalarUnaryFunctor< G >::ResultType ResultType
Definition: Functional.hpp:2627
static ResultType apply(const GridExpression< G > &e)
Returns the cell sum of e.
Definition: Functional.hpp:2634
static ResultType apply(const GridExpression< G1 > &e1, const GridExpression< G2 > &e2)
Tells whether e1 and e2 have the same dimensions and equal cell values.
Definition: Functional.hpp:2519
GridBooleanBinaryFunctor< G1, G2 >::ResultType ResultType
Definition: Functional.hpp:2511
Scalar3GridBooleanTernaryFunctor< G1, G2, T >::ResultType ResultType
Definition: Functional.hpp:2572
static ResultType apply(const GridExpression< G1 > &e1, const GridExpression< G2 > &e2, Argument3Type epsilon)
Tells whether e1 and e2 agree cell-wise within the absolute tolerance epsilon.
Definition: Functional.hpp:2582
Traits selecting the expression-template node and its result type for the Math::GridUnary instantiati...
Definition: GridExpression.hpp:136
ExpressionType ResultType
The expression-template result type returned by free-function operators.
Definition: GridExpression.hpp:141
GridUnary< E, F > ExpressionType
The expression-template node type.
Definition: GridExpression.hpp:139
Traits selecting the expression-template node and its result type for the Math::Scalar1GridBinary ins...
Definition: GridExpression.hpp:341
ExpressionType ResultType
The expression-template result type returned by free-function operators.
Definition: GridExpression.hpp:346
Scalar1GridBinary< E1, E2, F > ExpressionType
The expression-template node type.
Definition: GridExpression.hpp:344
Traits selecting the expression-template node and its result type for the Math::Scalar2GridBinary ins...
Definition: GridExpression.hpp:442
ExpressionType ResultType
The expression-template result type returned by free-function operators.
Definition: GridExpression.hpp:447
Scalar2GridBinary< E1, E2, F > ExpressionType
The expression-template node type.
Definition: GridExpression.hpp:445
Scalar binary addition functor: apply(t1, t2) returns t1 + t2.
Definition: Functional.hpp:344
Scalar binary division functor: apply(t1, t2) returns t1 / t2.
Definition: Functional.hpp:419
Scalar binary multiplication functor: apply(t1, t2) returns t1 * t2.
Definition: Functional.hpp:394
Scalar binary subtraction functor: apply(t1, t2) returns t1 - t2.
Definition: Functional.hpp:369