00001 /*!@file Image/f77lapack.H forward declarations of fortran-77 functions from lapack */ 00002 00003 // //////////////////////////////////////////////////////////////////// // 00004 // The iLab Neuromorphic Vision C++ Toolkit - Copyright (C) 2000-2005 // 00005 // by the University of Southern California (USC) and the iLab at USC. // 00006 // See http://iLab.usc.edu for information about this project. // 00007 // //////////////////////////////////////////////////////////////////// // 00008 // Major portions of the iLab Neuromorphic Vision Toolkit are protected // 00009 // under the U.S. patent ``Computation of Intrinsic Perceptual Saliency // 00010 // in Visual Environments, and Applications'' by Christof Koch and // 00011 // Laurent Itti, California Institute of Technology, 2001 (patent // 00012 // pending; application number 09/912,225 filed July 23, 2001; see // 00013 // http://pair.uspto.gov/cgi-bin/final/home.pl for current status). // 00014 // //////////////////////////////////////////////////////////////////// // 00015 // This file is part of the iLab Neuromorphic Vision C++ Toolkit. // 00016 // // 00017 // The iLab Neuromorphic Vision C++ Toolkit is free software; you can // 00018 // redistribute it and/or modify it under the terms of the GNU General // 00019 // Public License as published by the Free Software Foundation; either // 00020 // version 2 of the License, or (at your option) any later version. // 00021 // // 00022 // The iLab Neuromorphic Vision C++ Toolkit is distributed in the hope // 00023 // that it will be useful, but WITHOUT ANY WARRANTY; without even the // 00024 // implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR // 00025 // PURPOSE. See the GNU General Public License for more details. // 00026 // // 00027 // You should have received a copy of the GNU General Public License // 00028 // along with the iLab Neuromorphic Vision C++ Toolkit; if not, write // 00029 // to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, // 00030 // Boston, MA 02111-1307 USA. // 00031 // //////////////////////////////////////////////////////////////////// // 00032 // 00033 // Primary maintainer for this file: Rob Peters <rjpeters at usc dot edu> 00034 // $HeadURL: svn://isvn.usc.edu/software/invt/trunk/saliency/src/Image/f77lapack.H $ 00035 // $Id: f77lapack.H 14618 2011-03-18 22:49:35Z lior $ 00036 // 00037 00038 #ifndef IMAGE_F77LAPACK_H_DEFINED 00039 #define IMAGE_F77LAPACK_H_DEFINED 00040 00041 #if 0 00042 // This is a fake include that is here so that depoptions.in can 00043 // trigger liblapack to be linked in -- we need a "fake" include 00044 // because it seems that std distros of lapack don't actually include 00045 // a C header file 00046 #include <link-lapack> 00047 #endif 00048 00049 // Forward declarations of functions that we expect should be defined 00050 // in liblapack 00051 00052 #ifdef HAVE_LAPACK 00053 00054 typedef long int f77_integer; 00055 00056 // ################################################################### 00057 // ################################################################### 00058 /*! @name BLAS level 2 functions (matrix-vector operations) */ 00059 //@{ 00060 00061 //! Double-precision GEneral Matrix Vector multiply (DGEMV) 00062 /*! See http://www.netlib.org/blas/dgemv.f */ 00063 extern "C" void dgemv_(char* trans, f77_integer* M, f77_integer* N, 00064 double* alpha, const double* A, f77_integer* lda, 00065 const double* dx, f77_integer* incx, 00066 double* beta, double* dy, f77_integer* incy); 00067 00068 //! Single-precision GEneral Matrix Vector multiply (SGEMV) 00069 /*! See http://www.netlib.org/blas/sgemv.f */ 00070 extern "C" void sgemv_(char* trans, f77_integer* M, f77_integer* N, 00071 float* alpha, const float* A, f77_integer* lda, 00072 const float* dx, f77_integer* incx, 00073 float* beta, float* dy, f77_integer* incy); 00074 00075 //@} 00076 00077 // ################################################################### 00078 // ################################################################### 00079 /*! @name BLAS level 3 functions (matrix-matrix operations) */ 00080 //@{ 00081 00082 //! Double-precision GEneral Matrix Matrix multiply (DGEMM) 00083 /*! See http://www.netlib.org/blas/dgemm.f */ 00084 extern "C" void dgemm_(char *transa, char *transb, 00085 f77_integer *m, f77_integer *n, f77_integer *k, 00086 double *alpha, const double *a, f77_integer *lda, 00087 const double *b, f77_integer *ldb, 00088 double *beta, double *c, f77_integer *ldc); 00089 00090 //! Single-precision GEneral Matrix Matrix multiply (SGEMM) 00091 /*! See http://www.netlib.org/blas/sgemm.f */ 00092 extern "C" void sgemm_(char *transa, char *transb, 00093 f77_integer *m, f77_integer *n, f77_integer *k, 00094 float *alpha, const float *a, f77_integer *lda, 00095 const float *b, f77_integer *ldb, 00096 float *beta, float *c, f77_integer *ldc); 00097 00098 //@} 00099 00100 // ################################################################### 00101 // ################################################################### 00102 /*! @name LAPACK functions (linear algebra operations) */ 00103 //@{ 00104 00105 //! Double-precision GEneral matrix Singular value Decomposition using Divide-and-conquer (DGESDD) 00106 /*! See http://www.netlib.org/lapack/double/dgesdd.f 00107 00108 Note that this algorithm, based on divide-and-conquer, is expected 00109 to be substantially faster than the older DGESVD, which is based 00110 on QR-decomposition (see 00111 http://www.cs.berkeley.edu/~demmel/DOE2000/Report0100.html). 00112 */ 00113 extern "C" void dgesdd_(char *jobz, f77_integer *m, f77_integer *n, 00114 double *a, f77_integer *lda, 00115 double *s, double *u, f77_integer *ldu, 00116 double *vt, f77_integer *ldvt, 00117 double *work, f77_integer *lwork, 00118 f77_integer *iwork, f77_integer *info); 00119 00120 //! Single-precision GEneral matrix Singular value Decomposition using Divide-and-conquer (SGESDD) 00121 /*! See http://www.netlib.org/lapack/double/sgesdd.f */ 00122 extern "C" void sgesdd_(char *jobz, f77_integer *m, f77_integer *n, 00123 float *a, f77_integer *lda, 00124 float *s, float *u, f77_integer *ldu, 00125 float *vt, f77_integer *ldvt, 00126 float *work, f77_integer *lwork, 00127 f77_integer *iwork, f77_integer *info); 00128 00129 //@} 00130 00131 //! double-precision Computes the Cholesky factorization of a symmetric 00132 /*! See http://www.netlib.org/lapack/double/sgesdd.f */ 00133 extern "C" void dpotrf_(char *UPLO, f77_integer *n, 00134 double *a, f77_integer *lda, 00135 f77_integer *info); 00136 00137 00138 //! computes an LU factorization of a general M-by-N matrix A using partial pivoting with row interchanges. 00139 /*! See http://www.netlib.org/lapack/double/dgetrf.f */ 00140 extern "C" void dgetrf_(f77_integer *m, f77_integer *n, 00141 double *a, f77_integer *lda, 00142 f77_integer *ipiv, 00143 f77_integer *info); 00144 00145 //@} 00146 00147 00148 00149 #endif // HAVE_LAPACK 00150 00151 // ###################################################################### 00152 /* So things look consistent in everyone's emacs... */ 00153 /* Local Variables: */ 00154 /* indent-tabs-mode: nil */ 00155 /* End: */ 00156 00157 #endif // IMAGE_F77LAPACK_H_DEFINED