00001
00003 inline _zcovector t(const zrovector& rovec)
00004 {
00005 #ifdef CPPL_VERBOSE
00006 std::cerr << "# [MARK] t(const zrovector&)"
00007 << std::endl;
00008 #endif//CPPL_VERBOSE
00009
00010 zcovector covec(rovec.L);
00011 zcopy_(rovec.L, rovec.Array, 1, covec.array, 1);
00012
00013 return _(covec);
00014 }
00015
00016
00018 inline _zrovector conj(const zrovector& vec)
00019 {
00020 #ifdef CPPL_VERBOSE
00021 std::cerr << "# [MARK] conj(const zrovector&)"
00022 << std::endl;
00023 #endif//CPPL_VERBOSE
00024
00025 zrovector newvec(vec.L);
00026 for(long i=0; i<vec.L; i++){ newvec(i) =std::conj(vec(i)); }
00027
00028 return _(newvec);
00029 }
00030
00031
00033 inline _zcovector conjt(const zrovector& rovec)
00034 {
00035 #ifdef CPPL_VERBOSE
00036 std::cerr << "# [MARK] conjt(const zrovector&)"
00037 << std::endl;
00038 #endif//CPPL_VERBOSE
00039
00040 zcovector covec(rovec.L);
00041 for(long i=0; i<rovec.L; i++){ covec(i) =std::conj(rovec(i)); }
00042
00043 return _(covec);
00044 }
00045
00049
00050
00052 inline double nrm2(const zrovector& vec)
00053 {
00054 #ifdef CPPL_VERBOSE
00055 std::cerr << "# [MARK] nrm2(const zrovector&)"
00056 << std::endl;
00057 #endif//CPPL_VERBOSE
00058
00059 return dznrm2_(vec.L, vec.Array, 1);
00060 }
00061
00062
00065 inline long idamax(const zrovector& vec)
00066 {
00067 #ifdef CPPL_VERBOSE
00068 std::cerr << "# [MARK] idamax(const zrovector&)"
00069 << std::endl;
00070 #endif//CPPL_VERBOSE
00071
00072 return izamax_(vec.L, vec.Array, 1) -1;
00073 }
00074
00075
00077 inline std::complex<double> damax(const zrovector& vec)
00078 {
00079 #ifdef CPPL_VERBOSE
00080 std::cerr << "# [MARK] damax(const zrovector&)"
00081 << std::endl;
00082 #endif//CPPL_VERBOSE
00083
00084 return vec.Array[izamax_(vec.L, vec.Array, 1) -1];
00085 }