CPPLapack
 All Classes Files Functions Variables Friends Pages
zrovector_small.hpp
Go to the documentation of this file.
1 //=============================================================================
2 //! Samll Complex Double-precision Row Vector Class
3 template<CPPL_INT l> class zrovector_small
4 {
5 public:
6  ///////////////////////////////////////////////
7  /////////////////// objects ///////////////////
8  ///////////////////////////////////////////////
9  comple array[l];
10 
11  ///////////////////////////////////////////////
12  ///////////////// constructors ////////////////
13  ///////////////////////////////////////////////
14  inline zrovector_small();
15  inline explicit zrovector_small(const zrovector&);
16  inline zrovector_small(const comple&, const comple&);
17  inline zrovector_small(const comple&, const comple&, const comple&);
18  inline ~zrovector_small();
19 
20  ///////////////////////////////////////////////
21  ////////////////// functions //////////////////
22  ///////////////////////////////////////////////
23  //////// cast ////////
24  inline _zrovector to_zrovector() const;
25 
26  //////// io ////////
27  inline comple& operator()(const CPPL_INT&);
28  inline comple operator()(const CPPL_INT&) const;
29  inline zrovector_small<l>& set(const CPPL_INT&, const comple&);
30  template<CPPL_INT _l> inline friend std::ostream& operator<<(std::ostream&, const zrovector_small<_l>&);
31  inline void read(const char* filename);
32  inline void write(const char* filename) const;
33 
34  //////// calc ////////
35 #ifndef _MSC_VER
36  template<CPPL_INT _l> inline friend zcovector_small<_l> t(const zrovector_small<_l>&);
37  template<CPPL_INT _l> inline friend comple nrm2(const zrovector_small<_l>&);
38  template<CPPL_INT _l> inline friend CPPL_INT idamax(const zrovector_small<_l>&);
39  template<CPPL_INT _l> inline friend comple damax(const zrovector_small<_l>&);
40 #endif//_MSC_VER
41 
42  //////// misc ////////
43  inline zrovector_small<l>& zero();
44 
45  ///////////////////////////////////////////////
46  ///////////// numerical operators /////////////
47  ///////////////////////////////////////////////
48 #ifndef _MSC_VER
49  //////// = ////////
50  template<CPPL_INT L> inline zrovector_small<L>& operator= (const zrovector_small<L>&);
51  //////// += ////////
52  template<CPPL_INT L> inline friend zrovector_small<L>& operator+=(zrovector_small<L>&, const zrovector_small<L>&);
53  //////// -= ////////
54  template<CPPL_INT L> inline friend zrovector_small<L>& operator-=(zrovector_small<L>&, const zrovector_small<L>&);
55  //////// *= ////////
56  template<CPPL_INT L> inline friend zrovector_small<L>& operator*=(zrovector_small<L>&, const double&);
57  template<CPPL_INT L> inline friend zrovector_small<L>& operator*=(zrovector_small<L>&, const comple&);
58  //////// /= ////////
59  template<CPPL_INT L> inline friend zrovector_small<L>& operator/=(zrovector_small<L>&, const double&);
60  template<CPPL_INT L> inline friend zrovector_small<L>& operator/=(zrovector_small<L>&, const comple&);
61  //////// unary ////////
62  template<CPPL_INT L> inline friend const zrovector_small<L>& operator+(const zrovector_small<L>&);
63  template<CPPL_INT L> inline friend zrovector_small<L> operator-(const zrovector_small<L>&);
64  //////// + ////////
65  template<CPPL_INT L> inline friend zrovector_small<L> operator+(const zrovector_small<L>&, const zrovector_small<L>&);
66  //////// - ////////
67  template<CPPL_INT L> inline friend zrovector_small<L> operator-(const zrovector_small<L>&, const zrovector_small<L>&);
68  //////// * ////////
69  template<CPPL_INT L> inline friend comple operator*(const zrovector_small<L>&, const zcovector_small<L>&);
70  template<CPPL_INT M, CPPL_INT N> inline friend zrovector_small<N> operator*(const zrovector_small<M>&, const zgematrix_small<M,N>&);
71  template<CPPL_INT L> inline friend zrovector_small<L> operator*(const zrovector_small<L>&, const dsymatrix_small<L>&);
72  template<CPPL_INT L> inline friend zrovector_small<L> operator*(const zrovector_small<L>&, const comple&);
73  template<CPPL_INT L> inline friend zrovector_small<L> operator*(const zrovector_small<L>&, const comple&);
74  //////// / ////////
75  template<CPPL_INT L> inline friend zrovector_small<L> operator/(const zrovector_small<L>&, const double&);
76  template<CPPL_INT L> inline friend zrovector_small<L> operator/(const zrovector_small<L>&, const comple&);
77  //////// comple ////////
78  template<CPPL_INT L> inline friend zrovector_small<L> operator*(const double&, const zrovector_small<L>&);
79  template<CPPL_INT L> inline friend zrovector_small<L> operator*(const comple&, const zrovector_small<L>&);
80  //////// hadamerd ////////
81  template<CPPL_INT L> inline friend zrovector_small<L> hadamerd(const zrovector_small<L>&, const zrovector_small<L>&);
82 #endif//_MSC_VER
83 };
84 
85 ///////////////////////////////////////////////////////////////////////////////
86 ///////////////////////////////////////////////////////////////////////////////
87 ///////////////////////////////////////////////////////////////////////////////
88 
89 inline comple operator/(const zrovec2&, const zrovec2&);
90 inline zrovec3 operator/(const zrovec3&, const zrovec3&);
friend CPPL_INT idamax(const zrovector_small< _l > &)
friend comple damax(const zrovector_small< _l > &)
friend comple operator*(const zrovector_small< L > &, const zcovector_small< L > &)
void read(const char *filename)
Samll Real Double-precision Symmetric Matrix Class.
friend zrovector_small< L > hadamerd(const zrovector_small< L > &, const zrovector_small< L > &)
friend zrovector_small< L > & operator-=(zrovector_small< L > &, const zrovector_small< L > &)
zrovector_small< l > & zero()
void write(const char *filename) const
friend zrovector_small< L > & operator+=(zrovector_small< L > &, const zrovector_small< L > &)
Samll Complex Double-precision Column Vector Class.
friend comple nrm2(const zrovector_small< _l > &)
Samll Complex Double-precision Row Vector Class.
_zrovector to_zrovector() const
Complex Double-precision Row Vector Class.
Definition: zrovector.hpp:3
(DO NOT USE) Smart-temporary Complex Double-precision Row Vector Class
Definition: _zrovector.hpp:3
friend const zrovector_small< L > & operator+(const zrovector_small< L > &)
friend zrovector_small< L > operator-(const zrovector_small< L > &)
zrovector_small< L > & operator=(const zrovector_small< L > &)
friend zrovector_small< L > & operator*=(zrovector_small< L > &, const double &)
zrovector_small< l > & set(const CPPL_INT &, const comple &)
friend zrovector_small< L > operator/(const zrovector_small< L > &, const double &)
friend zrovector_small< L > & operator/=(zrovector_small< L > &, const double &)
friend zcovector_small< _l > t(const zrovector_small< _l > &)
Samll Complex Double-precision General Dence Matrix Class.
comple operator/(const zrovec2 &, const zrovec2 &)
comple & operator()(const CPPL_INT &)