Changeset 2958 in Sophya for trunk/SophyaLib/Samba/alm.h
- Timestamp:
- Jun 1, 2006, 1:34:50 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaLib/Samba/alm.h
r2885 r2958 21 21 Alm() : TriangularMatrix<complex<T> >() {;}; 22 22 /* instanciate the class from the maximum value of the index \f$l\f$ in the sequence of the \f$a_{lm}\f$'s */ 23 Alm( int nlmax) : TriangularMatrix<complex<T> >(nlmax+1) {;}23 Alm(sa_size_t nlmax) : TriangularMatrix<complex<T> >(nlmax+1) {;} 24 24 Alm(const Alm<T>& a, bool share=false) : TriangularMatrix<complex<T> >(a, share) {;} 25 25 26 26 Alm(const TVector<T>& clin, const r_8 fwhm) ; 27 27 /*! resize with a new lmax */ 28 inline void ReSizeToLmax( int_4nlmax) {this->ReSizeRow(nlmax+1);}29 inline int_4Lmax() const {return this->rowNumber()-1;}28 inline void ReSizeToLmax(sa_size_t nlmax) {this->ReSizeRow(nlmax+1);} 29 inline sa_size_t Lmax() const {return this->rowNumber()-1;} 30 30 TVector<T> powerSpectrum() const; 31 31 … … 48 48 Bm(): nmmax_(0) {;}; 49 49 /* instanciate from the maximum absolute value of the index */ 50 Bm( int mmax) : nmmax_((uint_4)mmax) { bm_.ReSize( (uint_4)(2*mmax+1) );}50 Bm(sa_size_t mmax) : nmmax_(mmax) { bm_.ReSize( (2*mmax+1) );} 51 51 Bm(const Bm<T>& b, bool share=false) : nmmax_(b.nmmax_), bm_(b.bm_, share) {;} 52 52 /*! resize with a new value of mmax */ 53 inline void ReSizeToMmax( int_4mmax)53 inline void ReSizeToMmax(sa_size_t mmax) 54 54 { 55 nmmax_= (uint_4)mmax;55 nmmax_= mmax; 56 56 bm_.ReSize(2* nmmax_+1); 57 57 } 58 //inline int_4Size() const {return 2*nmmax_+1;};59 inline T& operator()( int m) {return bm_( adr_i(m));};60 inline T const& operator()( int m) const {return *(bm_.Begin()+ adr_i(m));};58 //inline sa_size_t Size() const {return 2*nmmax_+1;}; 59 inline T& operator()(sa_size_t m) {return bm_( adr_i(m));}; 60 inline T const& operator()(sa_size_t m) const {return *(bm_.Begin()+ adr_i(m));}; 61 61 /*! return the current value of the maximum absolute value of the index */ 62 inline int_4Mmax() const62 inline sa_size_t Mmax() const 63 63 { 64 return (int_4)nmmax_;64 return nmmax_; 65 65 } 66 66 inline Bm<T>& operator = (const Bm<T>& b) … … 76 76 private: 77 77 /*! return the address in the array representing the vector */ 78 inline uint_4 adr_i(int i) const78 inline sa_size_t adr_i(sa_size_t i) const 79 79 { 80 return (uint_4)(i+nmmax_);80 return (i+nmmax_); 81 81 } 82 82 83 83 84 84 85 uint_4nmmax_;85 sa_size_t nmmax_; 86 86 NDataBlock<T> bm_; 87 87
Note:
See TracChangeset
for help on using the changeset viewer.