4 #ifndef ROOT_Math_BinaryOperators 5 #define ROOT_Math_BinaryOperators 30 template <
class T,
unsigned int D>
class SVector;
31 template <
class T,
unsigned int D1,
unsigned int D2,
class R>
class SMatrix;
45 static inline T apply(
const T& lhs,
const T& rhs) {
60 template <
class T,
unsigned int D>
62 operator+(
const SVector<T,D>& lhs,
const SVector<T,D>& rhs) {
72 template <
class A,
class T,
unsigned int D>
73 inline VecExpr<BinaryOp<AddOp<T>,
VecExpr<A,T,D>, SVector<T,D>, T>,
T, D>
74 operator+(
const VecExpr<A,T,D>& lhs,
const SVector<T,D>& rhs) {
84 template <
class A,
class T,
unsigned int D>
85 inline VecExpr<BinaryOp<AddOp<T>, SVector<T,D>, VecExpr<A,T,D>, T>,
T, D>
86 operator+(
const SVector<T,D>& lhs,
const VecExpr<A,T,D>& rhs) {
96 template <
class A,
class B,
class T,
unsigned int D>
97 inline VecExpr<BinaryOp<AddOp<T>, VecExpr<A,T,D>,
VecExpr<B,T,D>, T>,
T, D>
98 operator+(
const VecExpr<A,T,D>& lhs,
const VecExpr<B,T,D>& rhs) {
114 template <
class A,
class T,
unsigned int D>
131 template <
class A,
class T,
unsigned int D>
143 template <
class A,
class B,
class T,
unsigned int D>
144 inline VecExpr<BinaryOpCopyR<AddOp<T>, VecExpr<B,T,D>, Constant<A>, T>,
T, D>
154 template <
class A,
class B,
class T,
unsigned int D>
155 inline VecExpr<BinaryOpCopyL<AddOp<T>, Constant<A>, VecExpr<B,T,D>, T>,
T, D>
172 template <
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
173 inline Expr<BinaryOp<AddOp<T>,
SMatrix<T,D,D2,R1>,
SMatrix<T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType >
174 operator+(
const SMatrix<T,D,D2,R1>& lhs,
const SMatrix<T,D,D2,R2>& rhs) {
175 typedef BinaryOp<AddOp<T>, SMatrix<T,D,D2,R1>, SMatrix<T,D,D2,R2>, T> AddOpBinOp;
177 return Expr<AddOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(AddOpBinOp(
AddOp<T>(),lhs,rhs));
184 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
185 inline Expr<BinaryOp<AddOp<T>,
Expr<A,T,D,D2,R1>, SMatrix<T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
186 operator+(
const Expr<A,T,D,D2,R1>& lhs,
const SMatrix<T,D,D2,R2>& rhs) {
187 typedef BinaryOp<AddOp<T>, Expr<A,T,D,D2,R1>, SMatrix<T,D,D2,R2>, T> AddOpBinOp;
189 return Expr<AddOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(AddOpBinOp(
AddOp<T>(),lhs,rhs));
196 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
197 inline Expr<BinaryOp<AddOp<T>, SMatrix<T,D,D2,R1>,
Expr<A,T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
198 operator+(
const SMatrix<T,D,D2,R1>& lhs,
const Expr<A,T,D,D2,R2>& rhs) {
199 typedef BinaryOp<AddOp<T>, SMatrix<T,D,D2,R1>, Expr<A,T,D,D2,R2>, T> AddOpBinOp;
201 return Expr<AddOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(AddOpBinOp(
AddOp<T>(),lhs,rhs));
208 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
209 inline Expr<BinaryOp<AddOp<T>, Expr<A,T,D,D2,R1>,
Expr<B,T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType >
210 operator+(
const Expr<A,T,D,D2,R1>& lhs,
const Expr<B,T,D,D2,R2>& rhs) {
211 typedef BinaryOp<AddOp<T>, Expr<A,T,D,D2,R1>, Expr<B,T,D,D2,R2>, T> AddOpBinOp;
213 return Expr<AddOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(AddOpBinOp(
AddOp<T>(),lhs,rhs));
226 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R>
227 inline Expr<BinaryOpCopyR<AddOp<T>,
SMatrix<T,D,D2,R>, Constant<A>, T>,
T, D, D2,
R>
243 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R>
244 inline Expr<BinaryOpCopyL<AddOp<T>, Constant<A>, SMatrix<T,D,D2,R>, T>,
T, D, D2,
R>
249 Constant<A>(lhs),rhs));
256 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R>
257 inline Expr<BinaryOpCopyR<AddOp<T>,
Expr<B,T,D,D2,R>, Constant<A>, T>,
T, D, D2,
R>
262 lhs,Constant<A>(rhs)));
268 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R>
269 inline Expr<BinaryOpCopyL<AddOp<T>, Constant<A>, Expr<B,T,D,D2,R>, T>,
T, D, D2,
R>
274 Constant<A>(lhs),rhs));
289 static inline T
apply(
const T& lhs,
const T& rhs) {
304 template <
class T,
unsigned int D>
306 operator-(
const SVector<T,D>& lhs,
const SVector<T,D>& rhs) {
316 template <
class A,
class T,
unsigned int D>
317 inline VecExpr<BinaryOp<MinOp<T>, VecExpr<A,T,D>, SVector<T,D>, T>,
T, D>
318 operator-(
const VecExpr<A,T,D>& lhs,
const SVector<T,D>& rhs) {
328 template <
class A,
class T,
unsigned int D>
329 inline VecExpr<BinaryOp<MinOp<T>, SVector<T,D>, VecExpr<A,T,D>, T>,
T, D>
330 operator-(
const SVector<T,D>& lhs,
const VecExpr<A,T,D>& rhs) {
340 template <
class A,
class B,
class T,
unsigned int D>
341 inline VecExpr<BinaryOp<MinOp<T>, VecExpr<A,T,D>, VecExpr<B,T,D>, T>,
T, D>
342 operator-(
const VecExpr<A,T,D>& lhs,
const VecExpr<B,T,D>& rhs) {
358 template <
class A,
class T,
unsigned int D>
375 template <
class A,
class T,
unsigned int D>
387 template <
class A,
class B,
class T,
unsigned int D>
388 inline VecExpr<BinaryOpCopyR<MinOp<T>, VecExpr<B,T,D>, Constant<A>, T>,
T, D>
398 template <
class A,
class B,
class T,
unsigned int D>
399 inline VecExpr<BinaryOpCopyL<MinOp<T>, Constant<A>, VecExpr<B,T,D>, T>,
T, D>
416 template <
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
417 inline Expr<BinaryOp<MinOp<T>, SMatrix<T,D,D2,R1>, SMatrix<T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
418 operator-(
const SMatrix<T,D,D2,R1>& lhs,
const SMatrix<T,D,D2,R2>& rhs) {
419 typedef BinaryOp<MinOp<T>, SMatrix<T,D,D2,R1>, SMatrix<T,D,D2,R2>, T> MinOpBinOp;
421 return Expr<MinOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(MinOpBinOp(
MinOp<T>(),lhs,rhs));
428 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
429 inline Expr<BinaryOp<MinOp<T>, Expr<A,T,D,D2,R1>, SMatrix<T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
430 operator-(
const Expr<A,T,D,D2,R1>& lhs,
const SMatrix<T,D,D2,R2>& rhs) {
431 typedef BinaryOp<MinOp<T>, Expr<A,T,D,D2,R1>, SMatrix<T,D,D2,R2>, T> MinOpBinOp;
433 return Expr<MinOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(MinOpBinOp(
MinOp<T>(),lhs,rhs));
440 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
441 inline Expr<BinaryOp<MinOp<T>, SMatrix<T,D,D2,R1>, Expr<A,T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
442 operator-(
const SMatrix<T,D,D2,R1>& lhs,
const Expr<A,T,D,D2,R2>& rhs) {
443 typedef BinaryOp<MinOp<T>, SMatrix<T,D,D2,R1>, Expr<A,T,D,D2,R2>, T> MinOpBinOp;
445 return Expr<MinOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(MinOpBinOp(
MinOp<T>(),lhs,rhs));
452 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
453 inline Expr<BinaryOp<MinOp<T>, Expr<A,T,D,D2,R1>, Expr<B,T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
454 operator-(
const Expr<A,T,D,D2,R1>& lhs,
const Expr<B,T,D,D2,R2>& rhs) {
455 typedef BinaryOp<MinOp<T>, Expr<A,T,D,D2,R1>, Expr<B,T,D,D2,R2>, T> MinOpBinOp;
457 return Expr<MinOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(MinOpBinOp(
MinOp<T>(),lhs,rhs));
470 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R>
471 inline Expr<BinaryOpCopyR<MinOp<T>, SMatrix<T,D,D2,R>, Constant<A>, T>,
T, D, D2,
R>
476 lhs,Constant<A>(rhs)));
488 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R>
489 inline Expr<BinaryOpCopyL<MinOp<T>, Constant<A>, SMatrix<T,D,D2,R>, T>,
T, D, D2,
R>
499 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R>
500 inline Expr<BinaryOpCopyR<MinOp<T>, Expr<B,T,D,D2,R>, Constant<A>, T>,
T, D, D2,
R>
510 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R>
511 inline Expr<BinaryOpCopyL<MinOp<T>, Constant<A>, Expr<B,T,D,D2,R>, T>,
T, D, D2,
R>
516 Constant<A>(lhs),rhs));
531 static inline T
apply(
const T& lhs,
const T& rhs) {
546 template <
class T,
unsigned int D>
548 operator*(
const SVector<T,D>& lhs,
const SVector<T,D>& rhs) {
564 template <
class A,
class T,
unsigned int D>
565 inline VecExpr<BinaryOp<MulOp<T>,
Expr<A,T,D>, SVector<T,D>, T>,
T, D>
566 operator*(
const VecExpr<A,T,D>& lhs,
const SVector<T,D>& rhs) {
575 template <
class A,
class T,
unsigned int D>
576 inline VecExpr<BinaryOp<MulOp<T>, SVector<T,D>, VecExpr<A,T,D>, T>,
T, D>
577 operator*(
const SVector<T,D>& lhs,
const VecExpr<A,T,D>& rhs) {
586 template <
class A,
class B,
class T,
unsigned int D>
587 inline VecExpr<BinaryOp<MulOp<T>, VecExpr<A,T,D>, VecExpr<B,T,D>, T>,
T, D>
588 operator*(
const VecExpr<A,T,D>& lhs,
const VecExpr<B,T,D>& rhs) {
597 template <
class A,
class T,
unsigned int D>
608 template <
class A,
class T,
unsigned int D>
620 template <
class A,
class B,
class T,
unsigned int D>
621 inline VecExpr<BinaryOpCopyR<MulOp<T>, VecExpr<B,T,D>, Constant<A>, T>,
T, D>
631 template <
class A,
class B,
class T,
unsigned int D>
632 inline VecExpr<BinaryOpCopyL<MulOp<T>, Constant<A>, VecExpr<B,T,D>, T>,
T, D>
650 template <
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
651 inline Expr<BinaryOp<MulOp<T>, SMatrix<T,D,D2,R1>, SMatrix<T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
652 Times(
const SMatrix<T,D,D2,R1>& lhs,
const SMatrix<T,D,D2,R2>& rhs) {
653 typedef BinaryOp<MulOp<T>, SMatrix<T,D,D2,R1>, SMatrix<T,D,D2,R2>, T> MulOpBinOp;
655 return Expr<MulOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(MulOpBinOp(
MulOp<T>(),lhs,rhs));
662 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
663 inline Expr<BinaryOp<MulOp<T>, Expr<A,T,D,D2,R1>, SMatrix<T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
664 Times(
const Expr<A,T,D,D2,R1>& lhs,
const SMatrix<T,D,D2,R2>& rhs) {
665 typedef BinaryOp<MulOp<T>, Expr<A,T,D,D2,R1>, SMatrix<T,D,D2,R2>, T> MulOpBinOp;
667 return Expr<MulOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(MulOpBinOp(
MulOp<T>(),lhs,rhs));
674 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
675 inline Expr<BinaryOp<MulOp<T>, SMatrix<T,D,D2,R1>, Expr<A,T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
676 Times(
const SMatrix<T,D,D2,R1>& lhs,
const Expr<A,T,D,D2,R2>& rhs) {
677 typedef BinaryOp<MulOp<T>, SMatrix<T,D,D2,R1>, Expr<A,T,D,D2,R2>, T> MulOpBinOp;
679 return Expr<MulOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(MulOpBinOp(
MulOp<T>(),lhs,rhs));
686 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
687 inline Expr<BinaryOp<MulOp<T>, Expr<A,T,D,D2,R1>, Expr<B,T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
688 Times(
const Expr<A,T,D,D2,R1>& lhs,
const Expr<B,T,D,D2,R2>& rhs) {
689 typedef BinaryOp<MulOp<T>, Expr<A,T,D,D2,R1>, Expr<B,T,D,D2,R2>, T> MulOpBinOp;
691 return Expr<MulOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(MulOpBinOp(
MulOp<T>(),lhs,rhs));
704 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R>
705 inline Expr<BinaryOpCopyR<MulOp<T>, SMatrix<T,D,D2,R>, Constant<A>, T>,
T, D, D2,
R>
710 lhs,Constant<A>(rhs)));
722 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R>
723 inline Expr<BinaryOpCopyL<MulOp<T>, Constant<A>, SMatrix<T,D,D2,R>, T>,
T, D, D2,
R>
728 Constant<A>(lhs),rhs));
735 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R>
736 inline Expr<BinaryOpCopyR<MulOp<T>, Expr<B,T,D,D2,R>, Constant<A>, T>,
T, D, D2,
R>
741 lhs,Constant<A>(rhs)));
747 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R>
748 inline Expr<BinaryOpCopyL<MulOp<T>, Constant<A>, Expr<B,T,D,D2,R>, T>,
T, D, D2,
R>
753 Constant<A>(lhs),rhs));
768 static inline T
apply(
const T& lhs,
const T& rhs) {
782 template <
class T,
unsigned int D>
784 operator/(
const SVector<T,D>& lhs,
const SVector<T,D>& rhs) {
794 template <
class A,
class T,
unsigned int D>
795 inline VecExpr<BinaryOp<DivOp<T>, VecExpr<A,T,D>, SVector<T,D>, T>,
T, D>
796 operator/(
const VecExpr<A,T,D>& lhs,
const SVector<T,D>& rhs) {
805 template <
class A,
class T,
unsigned int D>
806 inline VecExpr<BinaryOp<DivOp<T>, SVector<T,D>, VecExpr<A,T,D>, T>,
T, D>
807 operator/(
const SVector<T,D>& lhs,
const VecExpr<A,T,D>& rhs) {
817 template <
class A,
class B,
class T,
unsigned int D>
818 inline VecExpr<BinaryOp<DivOp<T>, VecExpr<A,T,D>, VecExpr<B,T,D>, T>,
T, D>
819 operator/(
const VecExpr<A,T,D>& lhs,
const VecExpr<B,T,D>& rhs) {
835 template <
class A,
class T,
unsigned int D>
852 template <
class A,
class T,
unsigned int D>
864 template <
class A,
class B,
class T,
unsigned int D>
865 inline VecExpr<BinaryOpCopyR<DivOp<T>, VecExpr<B,T,D>, Constant<A>, T>,
T, D>
875 template <
class A,
class B,
class T,
unsigned int D>
876 inline VecExpr<BinaryOpCopyL<DivOp<T>, Constant<A>, VecExpr<B,T,D>, T>,
T, D>
893 template <
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
894 inline Expr<BinaryOp<DivOp<T>, SMatrix<T,D,D2,R1>, SMatrix<T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
895 Div(
const SMatrix<T,D,D2,R1>& lhs,
const SMatrix<T,D,D2,R2>& rhs) {
896 typedef BinaryOp<DivOp<T>, SMatrix<T,D,D2,R1>, SMatrix<T,D,D2,R2>, T> DivOpBinOp;
898 return Expr<DivOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(DivOpBinOp(
DivOp<T>(),lhs,rhs));
905 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
906 inline Expr<BinaryOp<DivOp<T>, Expr<A,T,D,D2,R1>, SMatrix<T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
907 Div(
const Expr<A,T,D,D2,R1>& lhs,
const SMatrix<T,D,D2,R2>& rhs) {
908 typedef BinaryOp<DivOp<T>, Expr<A,T,D,D2,R1>, SMatrix<T,D,D2,R2>, T> DivOpBinOp;
910 return Expr<DivOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(DivOpBinOp(
DivOp<T>(),lhs,rhs));
917 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
918 inline Expr<BinaryOp<DivOp<T>, SMatrix<T,D,D2,R1>, Expr<A,T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
919 Div(
const SMatrix<T,D,D2,R1>& lhs,
const Expr<A,T,D,D2,R2>& rhs) {
920 typedef BinaryOp<DivOp<T>, SMatrix<T,D,D2,R1>, Expr<A,T,D,D2,R2>, T> DivOpBinOp;
922 return Expr<DivOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(DivOpBinOp(
DivOp<T>(),lhs,rhs));
929 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R1,
class R2>
930 inline Expr<BinaryOp<DivOp<T>, Expr<A,T,D,D2,R1>, Expr<B,T,D,D2,R2>, T>,
T, D, D2,
typename AddPolicy<T,D,D2,R1,R2>::RepType>
931 Div(
const Expr<A,T,D,D2,R1>& lhs,
const Expr<B,T,D,D2,R2>& rhs) {
932 typedef BinaryOp<DivOp<T>, Expr<A,T,D,D2,R1>, Expr<B,T,D,D2,R2>, T> DivOpBinOp;
934 return Expr<DivOpBinOp,T,D,D2,typename AddPolicy<T,D,D2,R1,R2>::RepType>(DivOpBinOp(
DivOp<T>(),lhs,rhs));
947 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R>
948 inline Expr<BinaryOpCopyR<DivOp<T>, SMatrix<T,D,D2,R>, Constant<A>, T>,
T, D, D2,
R>
953 lhs,Constant<A>(rhs)));
965 template <
class A,
class T,
unsigned int D,
unsigned int D2,
class R>
966 inline Expr<BinaryOpCopyL<DivOp<T>, Constant<A>, SMatrix<T,D,D2,R>, T>,
T, D, D2,
R>
971 Constant<A>(lhs),rhs));
978 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R>
979 inline Expr<BinaryOpCopyR<DivOp<T>, Expr<B,T,D,D2,R>, Constant<A>, T>,
T, D, D2,
R>
984 lhs,Constant<A>(rhs)));
990 template <
class A,
class B,
class T,
unsigned int D,
unsigned int D2,
class R>
991 inline Expr<BinaryOpCopyL<DivOp<T>, Constant<A>, Expr<B,T,D,D2,R>, T>,
T, D, D2,
R>
Constant expression class A class representing constant expressions (literals) in the parse tree...
Multiplication (element-wise) Operation Class.
Namespace for new ROOT classes and functions.
Division (element-wise) Operation Class.
Binary Operation class with value storage for the left argument.
Expr< BinaryOp< MulOp< T >, SMatrix< T, D, D2, R1 >, SMatrix< T, D, D2, R2 >, T >, T, D, D2, typename AddPolicy< T, D, D2, R1, R2 >::RepType > Times(const SMatrix< T, D, D2, R1 > &lhs, const SMatrix< T, D, D2, R2 > &rhs)
Element by element matrix multiplication C(i,j) = A(i,j)*B(i,j) returning a matrix expression...
Subtraction Operation Class.
DisplacementVector2D< CoordSystem1, U > operator+(DisplacementVector2D< CoordSystem1, U > v1, const DisplacementVector2D< CoordSystem2, U > &v2)
Addition of DisplacementVector2D vectors.
static T apply(const T &lhs, const T &rhs)
DisplacementVector2D< CoordSystem1, U > operator-(DisplacementVector2D< CoordSystem1, U > v1, DisplacementVector2D< CoordSystem2, U > const &v2)
Difference between two DisplacementVector2D vectors.
SMatrix: a generic fixed size D1 x D2 Matrix class.
Expression wrapper class for Matrix objects.
Binary Operation class with value storage for the right argument.
static T apply(const T &lhs, const T &rhs)
BinaryOperation class A class representing binary operators in the parse tree.
Addition Operation Class.
static T apply(const T &lhs, const T &rhs)
VecExpr< BinaryOp< DivOp< T >, SVector< T, D >, SVector< T, D >, T >, T, D > operator/(const SVector< T, D > &lhs, const SVector< T, D > &rhs)
Element by element division of vectors of the same dimension: v3(i) = v1(i)/v2(i) returning a vector ...
Expr< BinaryOp< DivOp< T >, SMatrix< T, D, D2, R1 >, SMatrix< T, D, D2, R2 >, T >, T, D, D2, typename AddPolicy< T, D, D2, R1, R2 >::RepType > Div(const SMatrix< T, D, D2, R1 > &lhs, const SMatrix< T, D, D2, R2 > &rhs)
Division (element wise) of two matrices of the same dimensions: C(i,j) = A(i,j) / B(i...
static T apply(const T &lhs, const T &rhs)
Namespace for new Math classes and functions.
Expression wrapper class for Vector objects.
constexpr Double_t R()
Universal gas constant ( ) in
AxisAngle operator*(RotationX const &r1, AxisAngle const &r2)
Multiplication of an axial rotation by an AxisAngle.
SVector: a generic fixed size Vector class.