diff options
author | Thomas Grill <xovo@users.sourceforge.net> | 2003-03-17 04:36:54 +0000 |
---|---|---|
committer | Thomas Grill <xovo@users.sourceforge.net> | 2003-03-17 04:36:54 +0000 |
commit | 3eb7ec9a67e867275b862f9947deafe387012819 (patch) | |
tree | 6fd9d9f37721cdd28197ee5c54a3546060bd58af /externals/grill/vasp/source/ops_carith.h | |
parent | bc6f43fbe1b22b1c2c63a32372126e0eaaaa08b0 (diff) |
""
svn path=/trunk/; revision=476
Diffstat (limited to 'externals/grill/vasp/source/ops_carith.h')
-rw-r--r-- | externals/grill/vasp/source/ops_carith.h | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/externals/grill/vasp/source/ops_carith.h b/externals/grill/vasp/source/ops_carith.h index 0b049fb4..04514a10 100644 --- a/externals/grill/vasp/source/ops_carith.h +++ b/externals/grill/vasp/source/ops_carith.h @@ -15,20 +15,19 @@ WARRANTIES, see the file, "license.txt," in this distribution. // Arithmetic math functions -namespace VecOp { - inline BL d_cadd(OpParam &p) { return D__cbin<S,f_add<S> >(p); } - inline BL d_csub(OpParam &p) { return D__cbin<S,f_sub<S> >(p); } - inline BL d_csubr(OpParam &p) { return D__cbin<S,f_subr<S> >(p); } - inline BL d_cmul(OpParam &p) { return D__cbin<S,f_mul<S> >(p); } - inline BL d_cdiv(OpParam &p) { return d__cbin<S,f_div<S> >(p); } - inline BL d_cdivr(OpParam &p) { return d__cbin<S,f_divr<S> >(p); } +DEFOP(S,d_cadd,add,cbin) +DEFOP(S,d_csub,sub,cbin) +DEFOP(S,d_csubr,subr,cbin) +DEFOP(S,d_cmul,mul,cbin) +DEFOP(S,d_cdiv,div,cbin) +DEFOP(S,d_cdivr,divr,cbin) - inline BL d_csqr(OpParam &p) { return D__cun<S,f_sqr<S> >(p); } +DEFOP(S,d_csqr,sqr,cun) - inline BL d_cpowi(OpParam &p) { return d__cop<S,f_powi<S> >(p); } +DEFOP(S,d_cpowi,powi,cop) + +DEFOP(S,d_cabs,abs,cun) - inline BL d_cabs(OpParam &p) { return D__cun<S,f_abs<S> >(p); } -} namespace VaspOp { inline Vasp *m_cadd(OpParam &p,CVasp &src,const Argument &arg,CVasp *dst = NULL) { return m_cbin(p,src,arg,dst,VecOp::d_cadd); } // complex add (pairs of vecs or complex) |