00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029 #ifndef SCIMATH_SPARSEDIFFMATH_H
00030 #define SCIMATH_SPARSEDIFFMATH_H
00031
00032
00033
00034 #include <casacore/casa/aips.h>
00035 #include <casacore/casa/BasicMath/Math.h>
00036 #include <casacore/scimath/Mathematics/SparseDiff.h>
00037
00038 namespace casacore {
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063 template<class T>
00064 SparseDiff<T> operator+(const SparseDiff<T> &other);
00065 template<class T>
00066 SparseDiff<T> operator-(const SparseDiff<T> &other);
00067
00068
00069
00070
00071 template<class T>
00072 SparseDiff<T> operator+(const SparseDiff<T> &left, const SparseDiff<T> &right);
00073 template<class T>
00074 SparseDiff<T> operator-(const SparseDiff<T> &left, const SparseDiff<T> &right);
00075 template<class T>
00076 SparseDiff<T> operator*(const SparseDiff<T> &left, const SparseDiff<T> &right);
00077 template<class T>
00078 SparseDiff<T> operator/(const SparseDiff<T> &left, const SparseDiff<T> &right);
00079
00080
00081
00082
00083 template<class T>
00084 SparseDiff<T> operator+(const SparseDiff<T> &left, const T &right);
00085 template<class T>
00086 SparseDiff<T> operator-(const SparseDiff<T> &left, const T &right);
00087 template<class T>
00088 SparseDiff<T> operator*(const SparseDiff<T> &left, const T &right);
00089 template<class T>
00090 SparseDiff<T> operator/(const SparseDiff<T> &left, const T &right);
00091
00092
00093
00094
00095 template<class T>
00096 SparseDiff<T> operator+(const T &left, const SparseDiff<T> &right);
00097 template<class T>
00098 SparseDiff<T> operator-(const T &left, const SparseDiff<T> &right);
00099 template<class T>
00100 SparseDiff<T> operator*(const T &left, const SparseDiff<T> &right);
00101 template<class T>
00102 SparseDiff<T> operator/(const T &left, const SparseDiff<T> &right);
00103
00104
00105
00106
00107 template<class T> SparseDiff<T> acos(const SparseDiff<T> &ad);
00108 template<class T> SparseDiff<T> asin(const SparseDiff<T> &ad);
00109 template<class T> SparseDiff<T> atan(const SparseDiff<T> &ad);
00110 template<class T> SparseDiff<T> atan2(const SparseDiff<T> &y,
00111 const SparseDiff<T> &x);
00112 template<class T> SparseDiff<T> cos(const SparseDiff<T> &ad);
00113 template<class T> SparseDiff<T> cosh(const SparseDiff<T> &ad);
00114 template<class T> SparseDiff<T> exp(const SparseDiff<T> &ad);
00115 template<class T> SparseDiff<T> log(const SparseDiff<T> &ad);
00116 template<class T> SparseDiff<T> log10(const SparseDiff<T> &ad);
00117 template<class T> SparseDiff<T> erf(const SparseDiff<T> &ad);
00118 template<class T> SparseDiff<T> erfc(const SparseDiff<T> &ad);
00119 template<class T> SparseDiff<T> pow(const SparseDiff<T> &a,
00120 const SparseDiff<T> &b);
00121 template<class T> SparseDiff<T> pow(const SparseDiff<T> &a, const T &b);
00122 template<class T> SparseDiff<T> square(const SparseDiff<T> &ad);
00123 template<class T> SparseDiff<T> cube(const SparseDiff<T> &ad);
00124 template<class T> SparseDiff<T> sin(const SparseDiff<T> &ad);
00125 template<class T> SparseDiff<T> sinh(const SparseDiff<T> &ad);
00126 template<class T> SparseDiff<T> sqrt(const SparseDiff<T> &ad);
00127 template<class T> SparseDiff<T> tan(const SparseDiff<T> &ad);
00128 template<class T> SparseDiff<T> tanh(const SparseDiff<T> &ad);
00129 template<class T> SparseDiff<T> abs(const SparseDiff<T> &ad);
00130
00131
00132
00133
00134 template<class T> SparseDiff<T> fmod(const SparseDiff<T> &x, const T &c);
00135 template<class T> SparseDiff<T> fmod(const SparseDiff<T> &x,
00136 const SparseDiff<T> &c);
00137
00138
00139
00140 template<class T> SparseDiff<T> floor(const SparseDiff<T> &ad);
00141 template<class T> SparseDiff<T> ceil(const SparseDiff<T> &ad);
00142
00143
00144
00145
00146
00147
00148
00149
00150
00151
00152
00153 template<class T> Bool operator>(const SparseDiff<T> &left,
00154 const SparseDiff<T> &right);
00155 template<class T> Bool operator<(const SparseDiff<T> &left,
00156 const SparseDiff<T> &right);
00157 template<class T> Bool operator>=(const SparseDiff<T> &left,
00158 const SparseDiff<T> &right);
00159 template<class T> Bool operator<=(const SparseDiff<T> &left,
00160 const SparseDiff<T> &right);
00161 template<class T> Bool operator==(const SparseDiff<T> &left,
00162 const SparseDiff<T> &right);
00163 template<class T> Bool operator!=(const SparseDiff<T> &left,
00164 const SparseDiff<T> &right);
00165 template<class T> Bool near(const SparseDiff<T> &left,
00166 const SparseDiff<T> &right);
00167 template<class T> Bool near(const SparseDiff<T> &left,
00168 const SparseDiff<T> &right, const Double tol);
00169 template<class T> Bool allnear(const SparseDiff<T> &left,
00170 const SparseDiff<T> &right, const Double tol);
00171 template<class T> Bool nearAbs(const SparseDiff<T> &left,
00172 const SparseDiff<T> &right, const Double tol);
00173 template<class T> Bool allnearAbs(const SparseDiff<T> &left,
00174 const SparseDiff<T> &right, const Double tol);
00175
00176
00177
00178 template<class T> Bool operator>(const SparseDiff<T> &left, const T &right);
00179 template<class T> Bool operator<(const SparseDiff<T> &left, const T &right);
00180 template<class T> Bool operator>=(const SparseDiff<T> &left, const T &right);
00181 template<class T> Bool operator<=(const SparseDiff<T> &left, const T &right);
00182 template<class T> Bool operator==(const SparseDiff<T> &left, const T &right);
00183 template<class T> Bool operator!=(const SparseDiff<T> &left, const T &right);
00184 template<class T> Bool near(const SparseDiff<T> &left, const T &right);
00185 template<class T> Bool near(const SparseDiff<T> &left, const T &right,
00186 const Double tol);
00187 template<class T> Bool allnear(const SparseDiff<T> &left, const T &right,
00188 const Double tol);
00189 template<class T> Bool nearAbs(const SparseDiff<T> &left, const T &right,
00190 const Double tol);
00191 template<class T> Bool allnearAbs(const SparseDiff<T> &left, const T &right,
00192 const Double tol);
00193
00194
00195
00196 template<class T> Bool operator>(const T &left, const SparseDiff<T> &right);
00197 template<class T> Bool operator<(const T &left, const SparseDiff<T> &right);
00198 template<class T> Bool operator>=(const T &left, const SparseDiff<T> &right);
00199 template<class T> Bool operator<=(const T &left, const SparseDiff<T> &right);
00200 template<class T> Bool operator==(const T &left, const SparseDiff<T> &right);
00201 template<class T> Bool operator!=(const T &left, const SparseDiff<T> &right);
00202 template<class T> Bool near(const T &left, const SparseDiff<T> &right,
00203 const Double tol);
00204 template<class T> Bool allnear(const T &left, const SparseDiff<T> &right,
00205 const Double tol);
00206 template<class T> Bool nearAbs(const T &left, const SparseDiff<T> &right,
00207 const Double tol);
00208 template<class T> Bool allnearAbs(const T &left, const SparseDiff<T> &right,
00209 const Double tol);
00210
00211
00212
00213 template<class T> Bool isNaN(const SparseDiff<T> &val);
00214 template<class T> Bool isInf(SparseDiff<T> &val);
00215
00216
00217
00218 template<class T> SparseDiff<T> min(const SparseDiff<T> &left,
00219 const SparseDiff<T> &right);
00220 template<class T> SparseDiff<T> max(const SparseDiff<T> &left,
00221 const SparseDiff<T> &right);
00222
00223
00224
00225
00226
00227 }
00228
00229 #ifndef CASACORE_NO_AUTO_TEMPLATES
00230 #include <casacore/scimath/Mathematics/SparseDiffMath.tcc>
00231 #endif //# CASACORE_NO_AUTO_TEMPLATES
00232 #endif