Lapack++
|
00001 // -*-C++-*- 00002 00003 // Copyright (C) 2004 00004 // Christian Stimming <stimming@tuhh.de> 00005 00006 // This library is free software; you can redistribute it and/or 00007 // modify it under the terms of the GNU Lesser General Public License as 00008 // published by the Free Software Foundation; either version 2, or (at 00009 // your option) any later version. 00010 00011 // This library is distributed in the hope that it will be useful, 00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 // GNU Lesser General Public License for more details. 00015 00016 // You should have received a copy of the GNU Lesser General Public License along 00017 // with this library; see the file COPYING. If not, write to the Free 00018 // Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, 00019 // USA. 00020 00021 // LAPACK++ (V. 1.1) 00022 // (C) 1992-1996 All Rights Reserved. 00023 00029 #ifndef _BLAS3_PP_H_ 00030 #define _BLAS3_PP_H_ 00031 00032 #include <cmath> 00033 #include "lafnames.h" 00034 #include "arch.h" // needed for DLLIMPORT 00035 00036 #ifdef LA_COMPLEX_SUPPORT 00037 # include "lacomplex.h" 00038 #endif 00039 00040 #ifndef DOXYGEN_IGNORE 00041 // Forward declaration of classes 00042 class LaGenMatDouble; 00043 class LaVectorDouble; 00044 class LaGenMatComplex; 00045 class LaSymmMatDouble; 00046 00047 class LaBandMatDouble; 00048 class LaSpdMatDouble; 00049 class LaSymmTridiagMatDouble; 00050 class LaTridiagMatDouble; 00051 #endif // DOXYGEN_IGNORE 00052 00068 DLLIMPORT 00069 void Blas_Mat_Mat_Mult(const LaGenMatDouble &A, 00070 const LaGenMatDouble &B, LaGenMatDouble &C, 00071 bool transpose_A, bool transpose_B = false, 00072 double alpha = 1.0, double beta = 0.0); 00073 00075 DLLIMPORT 00076 void Blas_Mat_Mat_Mult(const LaGenMatDouble &A, 00077 const LaGenMatDouble &B, LaGenMatDouble &C, 00078 double alpha = 1.0, double beta = 0.0); 00079 00081 DLLIMPORT 00082 void Blas_Mat_Trans_Mat_Mult(const LaGenMatDouble &A, 00083 const LaGenMatDouble &B, LaGenMatDouble &C, 00084 double alpha = 1.0, double beta = 0.0); 00085 00087 DLLIMPORT 00088 void Blas_Mat_Mat_Trans_Mult(const LaGenMatDouble &A, 00089 const LaGenMatDouble &B, LaGenMatDouble &C, 00090 double alpha = 1.0, double beta = 0.0); 00091 00094 DLLIMPORT 00095 void Blas_Mat_Mat_Mult(const LaGenMatDouble &A, 00096 const LaGenMatDouble &B, LaVectorDouble &C); 00097 00100 DLLIMPORT 00101 void Blas_Mat_Trans_Mat_Mult(const LaGenMatDouble &A, 00102 const LaGenMatDouble &B, LaVectorDouble &C); 00103 00106 DLLIMPORT 00107 void Blas_Mat_Mat_Trans_Mult(const LaGenMatDouble &A, 00108 const LaGenMatDouble &B, LaVectorDouble &C); 00109 00113 DLLIMPORT 00114 void Blas_Scale(double s, LaGenMatDouble &A); 00115 00117 00118 00119 #ifdef LA_COMPLEX_SUPPORT 00120 00138 DLLIMPORT 00139 void Blas_Mat_Mat_Mult(const LaGenMatComplex &A, 00140 const LaGenMatComplex &B, LaGenMatComplex &C, 00141 bool hermit_A, bool hermit_B = false, 00142 LaComplex alpha = 1.0, LaComplex beta = 0.0); 00143 00145 DLLIMPORT 00146 void Blas_Mat_Mat_Mult(const LaGenMatComplex &A, 00147 const LaGenMatComplex &B, LaGenMatComplex &C, 00148 LaComplex alpha = 1.0, LaComplex beta = 0.0); 00149 00151 DLLIMPORT 00152 void Blas_Mat_Trans_Mat_Mult(const LaGenMatComplex &A, 00153 const LaGenMatComplex &B, LaGenMatComplex &C, 00154 LaComplex alpha = 1.0, LaComplex beta = 0.0); 00155 00157 DLLIMPORT 00158 void Blas_Mat_Mat_Trans_Mult(const LaGenMatComplex &A, 00159 const LaGenMatComplex &B, LaGenMatComplex &C, 00160 LaComplex alpha = 1.0, LaComplex beta = 0.0); 00161 00165 DLLIMPORT 00166 void Blas_Scale(COMPLEX s, LaGenMatComplex &A); 00168 #endif // LA_COMPLEX_SUPPORT 00169 00170 #ifdef _LA_UNIT_LOWER_TRIANG_MAT_DOUBLE_H_ 00171 00172 DLLIMPORT 00173 void Blas_Mat_Mat_Solve(LaUnitLowerTriangMatDouble &A, 00174 LaGenMatDouble &B, double alpha = 1.0); 00175 00176 #endif 00177 00178 #ifdef _LA_UNIT_UPPER_TRIANG_MAT_DOUBLE_H_ 00179 DLLIMPORT 00180 void Blas_Mat_Mat_Mult(LaUnitUpperTriangMatDouble &A, 00181 LaGenMatDouble &B, double alpha = 1.0); 00182 00183 DLLIMPORT 00184 void Blas_Mat_Mat_Solve(LaUnitUpperTriangMatDouble &A, 00185 LaGenMatDouble &B, double alpha = 1.0); 00186 00187 #endif 00188 00189 #ifdef _LA_LOWER_TRIANG_MAT_DOUBLE_H_ 00190 DLLIMPORT 00191 void Blas_Mat_Mat_Mult(LaLowerTriangMatDouble &A, 00192 LaGenMatDouble &B, double alpha = 1.0); 00193 00194 DLLIMPORT 00195 void Blas_Mat_Mat_Solve(LaLowerTriangMatDouble &A, 00196 LaGenMatDouble &B, double alpha = 1.0); 00197 #endif 00198 00199 00200 #ifdef _LA_UPPER_TRIANG_MAT_DOUBLE_H_ 00201 DLLIMPORT 00202 void Blas_Mat_Mat_Mult(LaUpperTriangMatDouble &A, 00203 LaGenMatDouble &B, double alpha = 1.0); 00204 00205 DLLIMPORT 00206 void Blas_Mat_Mat_Solve(LaUpperTriangMatDouble &A, 00207 LaGenMatDouble &B, double alpha = 1.0); 00208 #endif 00209 00210 00211 #ifdef _LA_UNIT_LOWER_TRIANG_MAT_DOUBLE_H_ 00212 DLLIMPORT 00213 void Blas_Mat_Trans_Mat_Solve(LaUnitLowerTriangMatDouble &A, 00214 LaGenMatDouble &B, double alpha = 1.0); 00215 #endif 00216 00217 #ifdef _LA_UNIT_UPPER_TRIANG_MAT_DOUBLE_H_ 00218 DLLIMPORT 00219 void Blas_Mat_Trans_Mat_Solve(LaUnitUpperTriangMatDouble &A, 00220 LaGenMatDouble &B, double alpha = 1.0); 00221 #endif 00222 00223 #ifdef _LA_UNIT_LOWER_TRIANG_MAT_DOUBLE_H_ 00224 DLLIMPORT 00225 void Blas_Mat_Mat_Mult(LaUnitLowerTriangMatDouble &A, 00226 LaGenMatDouble &B, double alpha = 1.0); 00227 00228 #endif 00229 00230 #ifdef _LA_LOWER_TRIANG_MAT_DOUBLE_H_ 00231 DLLIMPORT 00232 void Blas_Mat_Trans_Mat_Solve(LaLowerTriangMatDouble &A, 00233 LaGenMatDouble &B, double alpha = 1.0); 00234 #endif 00235 00236 00237 #ifdef _LA_UPPER_TRIANG_MAT_DOUBLE_H_ 00238 DLLIMPORT 00239 void Blas_Mat_Trans_Mat_Solve(LaUpperTriangMatDouble &A, 00240 LaGenMatDouble &B, double alpha = 1.0); 00241 00242 #endif 00243 00246 00253 DLLIMPORT 00254 void Blas_Mat_Mat_Mult(LaSymmMatDouble &A, LaGenMatDouble &B, 00255 LaGenMatDouble &C, 00256 double alpha = 1.0, double beta = 1.0, 00257 bool b_left_side = true); 00258 00267 DLLIMPORT 00268 void Blas_R1_Update(LaSymmMatDouble &C, LaGenMatDouble &A, 00269 double alpha = 1.0, double beta = 1.0, 00270 bool right_transposed = true); 00271 00280 DLLIMPORT 00281 void Blas_R2_Update(LaSymmMatDouble &C, LaGenMatDouble &A, 00282 LaGenMatDouble &B, 00283 double alpha = 1.0, double beta = 1.0, 00284 bool right_transposed = true); 00285 00287 00288 00289 00290 //------------------------------------- 00292 //------------------------------------- 00294 00301 DLLIMPORT 00302 double Blas_Norm1(const LaGenMatDouble &A); 00303 00311 DLLIMPORT 00312 double Blas_Norm_Inf(const LaGenMatDouble &A); 00313 00323 DLLIMPORT 00324 double Blas_NormF(const LaGenMatDouble &A); 00325 00333 DLLIMPORT 00334 double Blas_Norm1(const LaGenMatComplex &A); 00335 00343 DLLIMPORT 00344 double Blas_Norm_Inf(const LaGenMatComplex &A); 00345 00355 DLLIMPORT 00356 double Blas_NormF(const LaGenMatComplex &A); 00357 00358 #ifndef DOXYGEN_IGNORE 00359 00360 DLLIMPORT 00361 double Norm_Inf(const LaGenMatDouble &A); 00363 DLLIMPORT 00364 double Norm_Inf(const LaGenMatComplex &A); 00365 #endif // DOXYGEN_IGNORE 00366 00367 00368 DLLIMPORT 00369 double Norm_Inf(const LaBandMatDouble &A); 00370 DLLIMPORT 00371 double Norm_Inf(const LaSymmMatDouble &S); 00372 DLLIMPORT 00373 double Norm_Inf(const LaSpdMatDouble &S); 00374 DLLIMPORT 00375 double Norm_Inf(const LaSymmTridiagMatDouble &S); 00376 DLLIMPORT 00377 double Norm_Inf(const LaTridiagMatDouble &T); 00379 00380 00381 #endif 00382 // _BLAS3_PP_H_ 00383