Changeset 2589 in Sophya
- Timestamp:
- Jul 30, 2004, 5:09:17 PM (21 years ago)
- Location:
- trunk/SophyaLib/TArray
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaLib/TArray/tarray.cc
r2587 r2589 664 664 const T * pe; 665 665 T * per; 666 sa_size_t j,k ,kr;666 sa_size_t j,k; 667 667 if (smo && (IsPacked() > 0) && (res.IsPacked() > 0)) { // regularly spaced elements 668 668 sa_size_t maxx = totsize_; -
trunk/SophyaLib/TArray/tarray.h
r2588 r2589 178 178 inline TArray<T>& Mul(const TArray<T>& a) { return MulElt(a, *this); } 179 179 //! Element by element division in place TArray *= TArray (element by element) 180 inline TArray<T>& Div(const TArray<T>& a) { return DivlElt(a, *this); } 180 inline TArray<T>& Div(const TArray<T>& a, bool divzero=false) 181 { return DivElt(a, *this, false, divzero); } 181 182 182 183 // Recopie des valeurs, element par element … … 322 323 \brief Element by element division of two arrays TArray = TArray * TArray */ 323 324 template <class T> 324 inline TArray<T> DivideElt(const TArray<T>& a,const TArray<T>& b )325 inline TArray<T> DivideElt(const TArray<T>& a,const TArray<T>& b, bool divzero=false) 325 326 { TArray<T> result; result.SetTemp(true); 326 a.DivElt(b, result ); return result; }327 a.DivElt(b, result, false, divzero); return result; } 327 328 328 329 // --------------------------------------------------
Note:
See TracChangeset
for help on using the changeset viewer.