CPPLapack
 All Classes Files Functions Variables Friends
Functions
zcovector_small-functions.hpp File Reference

Go to the source code of this file.

Functions

template<long l>
std::ostream & operator<< (std::ostream &s, const zcovector_small< l > &A)
template<long l>
zrovector_small< l > t (const zcovector_small< l > &A)
template<long l>
comple nrm2 (const zcovector_small< l > &A)
template<long l>
void idamax (long &K, const zcovector_small< l > &A)
template<long l>
comple damax (const zcovector_small< l > &A)
template<long l>
zcovector_small< l > colon (const zcovector_small< l > &A, const zcovector_small< l > &B)
template<long l>
zcovector_small< l > & operator+= (zcovector_small< l > &A, const zcovector_small< l > &B)
template<long l>
zcovector_small< l > & operator-= (zcovector_small< l > &A, const zcovector_small< l > &B)
template<long l>
zcovector_small< l > & operator*= (zcovector_small< l > &A, const comple &d)
template<long l>
zcovector_small< l > & operator/= (zcovector_small< l > &A, const comple &d)
template<long l>
const zcovector_small< l > & operator+ (const zcovector_small< l > &A)
template<long l>
zcovector_small< l > operator- (const zcovector_small< l > &A)
template<long l>
zcovector_small< l > operator+ (const zcovector_small< l > &A, const zcovector_small< l > &B)
template<long l>
zcovector_small< l > operator- (const zcovector_small< l > &A, const zcovector_small< l > &B)
template<long n>
zcovector_small< n > operator* (const zcovector_small< n > &A, const comple &v)
template<long m, long n>
zgematrix_small< m, n > operator* (const zcovector_small< m > &A, const zrovector_small< n > &B)
template<long n>
zcovector_small< n > operator/ (const zcovector_small< n > &A, const comple &v)
template<long l>
comple operator% (const zcovector_small< l > &A, const zcovector_small< l > &B)

Function Documentation

template<long l>
std::ostream& operator<< ( std::ostream &  s,
const zcovector_small< l > &  A 
) [inline]

Definition at line 45 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  s << std::setiosflags(std::ios::showpos);
  for(long i=0; i<l; i++){
    s << A(i) << std::endl;
  }
  return s;
}
template<long l>
zrovector_small<l> t ( const zcovector_small< l > &  A) [inline]

Definition at line 131 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  zrovector_small<l> X;
  for(long i=0; i<l; i++){
    X(i) =A(i);
  }
  return X;
}
template<long l>
comple nrm2 ( const zcovector_small< l > &  A) [inline]

Definition at line 143 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  comple v(0);
  for(long i=0; i<l; i++){
    v+=A(i)*A(i);
  }
  return sqrt(v);
}
template<long l>
void idamax ( long &  K,
const zcovector_small< l > &  A 
) [inline]

Definition at line 155 of file zcovector_small-functions.hpp.

{VERBOSE_REPORT;
  comple max(-1.);
  for(int k=0; k<l; k++){
    if( max<fabs(A(k)) ){
      K=k;
      max =fabs(A(k));
    }
  }
  return;
}
template<long l>
comple damax ( const zcovector_small< l > &  A) [inline]

Definition at line 170 of file zcovector_small-functions.hpp.

References idamax().

{VERBOSE_REPORT;
  long k(0);
  idamax(k,A);
  return A(k);
}
template<long l>
zcovector_small<l> colon ( const zcovector_small< l > &  A,
const zcovector_small< l > &  B 
) [inline]

Definition at line 180 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  zcovector_small<l> C;
  for(long i=0; i<l; i++){
    C(i) =A(i)*B(i);
  }
  return C;
}
template<long l>
zcovector_small<l>& operator+= ( zcovector_small< l > &  A,
const zcovector_small< l > &  B 
) [inline]

Definition at line 211 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  for(long i=0; i<l; i++){
    A(i) +=B(i);
  }
  return A;
}
template<long l>
zcovector_small<l>& operator-= ( zcovector_small< l > &  A,
const zcovector_small< l > &  B 
) [inline]

Definition at line 222 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  for(long i=0; i<l; i++){
    A(i) -=B(i);
  }
  return A;
}
template<long l>
zcovector_small<l>& operator*= ( zcovector_small< l > &  A,
const comple &  d 
) [inline]

Definition at line 233 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  for(long i=0; i<l; i++){
    A(i) *=d;
  }
  return A;
}
template<long l>
zcovector_small<l>& operator/= ( zcovector_small< l > &  A,
const comple &  d 
) [inline]

Definition at line 244 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  for(long i=0; i<l; i++){
    A(i) /=d;
  }
  return A;
}
template<long l>
const zcovector_small<l>& operator+ ( const zcovector_small< l > &  A) [inline]

unary

Definition at line 259 of file zcovector_small-functions.hpp.

{VERBOSE_REPORT;
  return A;
}
template<long l>
zcovector_small<l> operator- ( const zcovector_small< l > &  A) [inline]

unary

Definition at line 267 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  zcovector_small<l> X;
  for(long i=0; i<l; i++){
    X(i) =-A(i);
  }
  return X;
}
template<long l>
zcovector_small<l> operator+ ( const zcovector_small< l > &  A,
const zcovector_small< l > &  B 
) [inline]

Definition at line 283 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  zcovector_small<l> X;
  for(long i=0; i<l; i++){
    X(i) =A(i)+B(i);
  }
  return X;
}
template<long l>
zcovector_small<l> operator- ( const zcovector_small< l > &  A,
const zcovector_small< l > &  B 
) [inline]

Definition at line 295 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  zcovector_small<l> X;
  for(long i=0; i<l; i++){
    X(i) =A(i)-B(i);
  }
  return X;
}
template<long n>
zcovector_small<n> operator* ( const zcovector_small< n > &  A,
const comple &  v 
) [inline]

Definition at line 307 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  zcovector_small<n> C;
  for(long i=0; i<n; i++){
    C(i) =A(i)*v;
  }
  return C;
}
template<long m, long n>
zgematrix_small<m,n> operator* ( const zcovector_small< m > &  A,
const zrovector_small< n > &  B 
) [inline]

Definition at line 319 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  zgematrix_small<m,n> mat;
  for(long i=0; i<m; i++){
    for(long j=0; j<n; j++){
      mat(i,j) =A(i)*B(j);
    }
  }
  return mat;
}
template<long n>
zcovector_small<n> operator/ ( const zcovector_small< n > &  A,
const comple &  v 
) [inline]

Definition at line 333 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  zcovector_small<n> C;
  for(long i=0; i<n; i++){
    C(i) =A(i)/v;
  }
  return C;
}
template<long l>
comple operator% ( const zcovector_small< l > &  A,
const zcovector_small< l > &  B 
) [inline]

Definition at line 345 of file zcovector_small-functions.hpp.

References i().

{VERBOSE_REPORT;
  comple v(0.);
  for(long i=0; i<l; i++){
    v +=A(i)*B(i);
  }
  return v;
}
 All Classes Files Functions Variables Friends