00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #if !defined (octave_liboctave_specfun_h)
00024 #define octave_liboctave_specfun_h 1
00025
00026 #include "oct-cmplx.h"
00027 #include "ArrayN.h"
00028
00029 template <class T> class Array2;
00030 class Matrix;
00031 class ComplexMatrix;
00032 class NDArray;
00033 class ComplexNDArray;
00034 class RowVector;
00035 class ComplexColumnVector;
00036 class Range;
00037
00038 #if !defined (HAVE_ACOSH)
00039 extern double acosh (double);
00040 #endif
00041
00042 #if !defined (HAVE_ASINH)
00043 extern double asinh (double);
00044 #endif
00045
00046 #if !defined (HAVE_ATANH)
00047 extern double atanh (double);
00048 #endif
00049
00050 #if !defined (HAVE_ERF)
00051 extern double erf (double);
00052 #endif
00053
00054 #if !defined (HAVE_ERFC)
00055 extern double erfc (double);
00056 #endif
00057
00058 extern double xgamma (double x);
00059 extern double xlgamma (double x);
00060
00061 extern Complex
00062 besselj (double alpha, const Complex& x, bool scaled, int& ierr);
00063
00064 extern Complex
00065 bessely (double alpha, const Complex& x, bool scaled, int& ierr);
00066
00067 extern Complex
00068 besseli (double alpha, const Complex& x, bool scaled, int& ierr);
00069
00070 extern Complex
00071 besselk (double alpha, const Complex& x, bool scaled, int& ierr);
00072
00073 extern Complex
00074 besselh1 (double alpha, const Complex& x, bool scaled, int& ierr);
00075
00076 extern Complex
00077 besselh2 (double alpha, const Complex& x, bool scaled, int& ierr);
00078
00079 extern ComplexMatrix
00080 besselj (double alpha, const ComplexMatrix& x, bool scaled,
00081 Array2<int>& ierr);
00082
00083 extern ComplexMatrix
00084 bessely (double alpha, const ComplexMatrix& x, bool scaled,
00085 Array2<int>& ierr);
00086
00087 extern ComplexMatrix
00088 besseli (double alpha, const ComplexMatrix& x, bool scaled,
00089 Array2<int>& ierr);
00090
00091 extern ComplexMatrix
00092 besselk (double alpha, const ComplexMatrix& x, bool scaled,
00093 Array2<int>& ierr);
00094
00095 extern ComplexMatrix
00096 besselh1 (double alpha, const ComplexMatrix& x, bool scaled,
00097 Array2<int>& ierr);
00098
00099 extern ComplexMatrix
00100 besselh2 (double alpha, const ComplexMatrix& x, bool scaled,
00101 Array2<int>& ierr);
00102
00103 extern ComplexMatrix
00104 besselj (const Matrix& alpha, const Complex& x, bool scaled,
00105 Array2<int>& ierr);
00106
00107 extern ComplexMatrix
00108 bessely (const Matrix& alpha, const Complex& x, bool scaled,
00109 Array2<int>& ierr);
00110
00111 extern ComplexMatrix
00112 besseli (const Matrix& alpha, const Complex& x, bool scaled,
00113 Array2<int>& ierr);
00114
00115 extern ComplexMatrix
00116 besselk (const Matrix& alpha, const Complex& x, bool scaled,
00117 Array2<int>& ierr);
00118
00119 extern ComplexMatrix
00120 besselh1 (const Matrix& alpha, const Complex& x, bool scaled,
00121 Array2<int>& ierr);
00122
00123 extern ComplexMatrix
00124 besselh2 (const Matrix& alpha, const Complex& x, bool scaled,
00125 Array2<int>& ierr);
00126
00127 extern ComplexMatrix
00128 besselj (const Matrix& alpha, const ComplexMatrix& x, bool scaled,
00129 Array2<int>& ierr);
00130
00131 extern ComplexMatrix
00132 bessely (const Matrix& alpha, const ComplexMatrix& x, bool scaled,
00133 Array2<int>& ierr);
00134
00135 extern ComplexMatrix
00136 besseli (const Matrix& alpha, const ComplexMatrix& x, bool scaled,
00137 Array2<int>& ierr);
00138
00139 extern ComplexMatrix
00140 besselk (const Matrix& alpha, const ComplexMatrix& x, bool scaled,
00141 Array2<int>& ierr);
00142
00143 extern ComplexMatrix
00144 besselh1 (const Matrix& alpha, const ComplexMatrix& x, bool scaled,
00145 Array2<int>& ierr);
00146
00147 extern ComplexMatrix
00148 besselh2 (const Matrix& alpha, const ComplexMatrix& x, bool scaled,
00149 Array2<int>& ierr);
00150
00151 extern ComplexNDArray
00152 besselj (double alpha, const ComplexNDArray& x, bool scaled,
00153 ArrayN<int>& ierr);
00154
00155 extern ComplexNDArray
00156 bessely (double alpha, const ComplexNDArray& x, bool scaled,
00157 ArrayN<int>& ierr);
00158
00159 extern ComplexNDArray
00160 besseli (double alpha, const ComplexNDArray& x, bool scaled,
00161 ArrayN<int>& ierr);
00162
00163 extern ComplexNDArray
00164 besselk (double alpha, const ComplexNDArray& x, bool scaled,
00165 ArrayN<int>& ierr);
00166
00167 extern ComplexNDArray
00168 besselh1 (double alpha, const ComplexNDArray& x, bool scaled,
00169 ArrayN<int>& ierr);
00170
00171 extern ComplexNDArray
00172 besselh2 (double alpha, const ComplexNDArray& x, bool scaled,
00173 ArrayN<int>& ierr);
00174
00175 extern ComplexNDArray
00176 besselj (const NDArray& alpha, const Complex& x, bool scaled,
00177 ArrayN<int>& ierr);
00178
00179 extern ComplexNDArray
00180 bessely (const NDArray& alpha, const Complex& x, bool scaled,
00181 ArrayN<int>& ierr);
00182
00183 extern ComplexNDArray
00184 besseli (const NDArray& alpha, const Complex& x, bool scaled,
00185 ArrayN<int>& ierr);
00186
00187 extern ComplexNDArray
00188 besselk (const NDArray& alpha, const Complex& x, bool scaled,
00189 ArrayN<int>& ierr);
00190
00191 extern ComplexNDArray
00192 besselh1 (const NDArray& alpha, const Complex& x, bool scaled,
00193 ArrayN<int>& ierr);
00194
00195 extern ComplexNDArray
00196 besselh2 (const NDArray& alpha, const Complex& x, bool scaled,
00197 ArrayN<int>& ierr);
00198
00199 extern ComplexNDArray
00200 besselj (const NDArray& alpha, const ComplexNDArray& x, bool scaled,
00201 ArrayN<int>& ierr);
00202
00203 extern ComplexNDArray
00204 bessely (const NDArray& alpha, const ComplexNDArray& x, bool scaled,
00205 ArrayN<int>& ierr);
00206
00207 extern ComplexNDArray
00208 besseli (const NDArray& alpha, const ComplexNDArray& x, bool scaled,
00209 ArrayN<int>& ierr);
00210
00211 extern ComplexNDArray
00212 besselk (const NDArray& alpha, const ComplexNDArray& x, bool scaled,
00213 ArrayN<int>& ierr);
00214
00215 extern ComplexNDArray
00216 besselh1 (const NDArray& alpha, const ComplexNDArray& x, bool scaled,
00217 ArrayN<int>& ierr);
00218
00219 extern ComplexNDArray
00220 besselh2 (const NDArray& alpha, const ComplexNDArray& x, bool scaled,
00221 ArrayN<int>& ierr);
00222
00223 extern ComplexMatrix
00224 besselj (const RowVector& alpha, const ComplexColumnVector& x, bool scaled,
00225 Array2<int>& ierr);
00226
00227 extern ComplexMatrix
00228 bessely (const RowVector& alpha, const ComplexColumnVector& x, bool scaled,
00229 Array2<int>& ierr);
00230
00231 extern ComplexMatrix
00232 besseli (const RowVector& alpha, const ComplexColumnVector& x, bool scaled,
00233 Array2<int>& ierr);
00234
00235 extern ComplexMatrix
00236 besselk (const RowVector& alpha, const ComplexColumnVector& x, bool scaled,
00237 Array2<int>& ierr);
00238
00239 extern ComplexMatrix
00240 besselh1 (const RowVector& alpha, const ComplexColumnVector& x, bool scaled,
00241 Array2<int>& ierr);
00242
00243 extern ComplexMatrix
00244 besselh2 (const RowVector& alpha, const ComplexColumnVector& x, bool scaled,
00245 Array2<int>& ierr);
00246
00247 extern Complex airy (const Complex& z, bool deriv, bool scaled, int& ierr);
00248 extern Complex biry (const Complex& z, bool deriv, bool scaled, int& ierr);
00249
00250 extern ComplexMatrix
00251 airy (const ComplexMatrix& z, bool deriv, bool scaled, Array2<int>& ierr);
00252
00253 extern ComplexMatrix
00254 biry (const ComplexMatrix& z, bool deriv, bool scaled, Array2<int>& ierr);
00255
00256 extern ComplexNDArray
00257 airy (const ComplexNDArray& z, bool deriv, bool scaled, ArrayN<int>& ierr);
00258
00259 extern ComplexNDArray
00260 biry (const ComplexNDArray& z, bool deriv, bool scaled, ArrayN<int>& ierr);
00261
00262 extern double betainc (double x, double a, double b);
00263 extern Matrix betainc (double x, double a, const Matrix& b);
00264 extern Matrix betainc (double x, const Matrix& a, double b);
00265 extern Matrix betainc (double x, const Matrix& a, const Matrix& b);
00266
00267 extern NDArray betainc (double x, double a, const NDArray& b);
00268 extern NDArray betainc (double x, const NDArray& a, double b);
00269 extern NDArray betainc (double x, const NDArray& a, const NDArray& b);
00270
00271 extern Matrix betainc (const Matrix& x, double a, double b);
00272 extern Matrix betainc (const Matrix& x, double a, const Matrix& b);
00273 extern Matrix betainc (const Matrix& x, const Matrix& a, double b);
00274 extern Matrix betainc (const Matrix& x, const Matrix& a, const Matrix& b);
00275
00276 extern NDArray betainc (const NDArray& x, double a, double b);
00277 extern NDArray betainc (const NDArray& x, double a, const NDArray& b);
00278 extern NDArray betainc (const NDArray& x, const NDArray& a, double b);
00279 extern NDArray betainc (const NDArray& x, const NDArray& a, const NDArray& b);
00280
00281 extern double gammainc (double x, double a, bool& err);
00282 extern Matrix gammainc (double x, const Matrix& a);
00283 extern Matrix gammainc (const Matrix& x, double a);
00284 extern Matrix gammainc (const Matrix& x, const Matrix& a);
00285
00286 extern NDArray gammainc (double x, const NDArray& a);
00287 extern NDArray gammainc (const NDArray& x, double a);
00288 extern NDArray gammainc (const NDArray& x, const NDArray& a);
00289
00290 inline double gammainc (double x, double a)
00291 {
00292 bool err;
00293 return gammainc (x, a, err);
00294 }
00295
00296 #endif
00297
00298
00299
00300
00301
00302
00303