|
liblapackwrap 0.1
|
00001 /* 00002 *Wrapper for a variety of LAPACK routines. 00003 00004 Copyright (C) 2010 Joseph Pingenot 00005 00006 This program is free software: you can redistribute it and/or modify 00007 it under the terms of the GNU Lesser General Public License as published by 00008 the Free Software Foundation, either version 3 of the License, or 00009 (at your option) any later version. 00010 00011 This program 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 00017 along with this program. If not, see <http://www.gnu.org/licenses/>. 00018 00019 */ 00020 00021 00022 #ifndef _____LIBLAPACKWRAP_BLASWRAP_<llw_typeset>_H______ 00023 #define _____LIBLAPACKWRAP_BLASWRAP_<llw_typeset>_H______ 00024 00025 #ifdef __cplusplus 00026 extern "C" { 00027 #endif 00028 00029 /**\note Generic LLW data types are placed in this header file. 00030 *defining LLW_<llw_typeset>_FOO helps translate the generic 00031 * core lapackwrap and blaswrap patterns to the final version. 00032 * An alternative method would be translating each genericized 00033 * core datatype into the specific data type. However, that would 00034 * require a more complicated, multi-substitution method (e.g. with 00035 * a perl script. This may come later, when I've gotten more experience 00036 * using this lib. 00037 */ 00038 #include <liblapackwrap/lapackwrap_types_<llw_typeset>.h> 00039 00040 /**This is to ensure safety. 00041 *If you don't care, you can save some cycles at the expense of 00042 * "guaranteeing" safety for the data you're passing in read-only 00043 * by commenting out this define. This will make all const arrays 00044 * non-const and therefore not "guaranteed" to not be modified by the 00045 * routines. This is effected, in addition to the const keyword, by 00046 * copying each array into a secondary one via memcopy(). Turning 00047 * this off saves that copy, which is the largst cost of this safety. 00048 */ 00049 #define LLW_CONST const 00050 00051 /**frontend for llw_double_gemm but if you don't have a matrix C yet (clearly, if you're calling this routine, you want one. 00052 */ 00053 int llw_<llw_typeset>_gemm_a(char transa, char transb, int M, int N, int K, LLW_<llw_typeset>_COMPLEX *alpha, LLW_CONST LLW_<llw_typeset>_COMPLEX *A, int LDA, LLW_CONST LLW_<llw_typeset>_COMPLEX *B, int LDB, LLW_<llw_typeset>_COMPLEX **C); 00054 00055 /**Performs matrix-matrix multiplication. 00056 */ 00057 int llw_<llw_typeset>_gemm(char transa, char transb, int M, int N, int K, LLW_<llw_typeset>_COMPLEX *alpha, LLW_CONST LLW_<llw_typeset>_COMPLEX *A, int LDA, LLW_CONST LLW_<llw_typeset>_COMPLEX *B, int LDB, LLW_<llw_typeset>_COMPLEX *beta, LLW_<llw_typeset>_COMPLEX *C, int LDC); 00058 00059 00060 #ifdef __cplusplus 00061 } 00062 #endif 00063 00064 #endif