Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

NR Namespace Reference


Functions

void addint (Mat_O_DP &uf, Mat_I_DP &uc, Mat_O_DP &res)
void airy (const DP x, DP &ai, DP &bi, DP &aip, DP &bip)
void amebsa (Mat_IO_DP &p, Vec_IO_DP &y, Vec_O_DP &pb, DP &yb, const DP ftol, DP funk(Vec_I_DP &), int &iter, const DP temptr)
void amoeba (Mat_IO_DP &p, Vec_IO_DP &y, const DP ftol, DP funk(Vec_I_DP &), int &nfunk)
DP amotry (Mat_IO_DP &p, Vec_O_DP &y, Vec_IO_DP &psum, DP funk(Vec_I_DP &), const int ihi, const DP fac)
DP amotsa (Mat_IO_DP &p, Vec_O_DP &y, Vec_IO_DP &psum, Vec_O_DP &pb, DP &yb, DP funk(Vec_I_DP &), const int ihi, DP &yhi, const DP fac)
void anneal (Vec_I_DP &x, Vec_I_DP &y, Vec_IO_INT &iorder)
DP anorm2 (Mat_I_DP &a)
void arcmak (Vec_I_ULNG &nfreq, unsigned long nchh, unsigned long nradd, arithcode &acode)
void arcode (unsigned long &ich, string &code, unsigned long &lcd, const int isign, arithcode &acode)
void arcsum (Vec_I_ULNG &iin, Vec_O_ULNG &iout, unsigned long ja, const int nwk, const unsigned long nrad, const unsigned long nc)
void asolve (Vec_I_DP &b, Vec_O_DP &x, const int itrnsp)
void atimes (Vec_I_DP &x, Vec_O_DP &r, const int itrnsp)
void avevar (Vec_I_DP &data, DP &ave, DP &var)
void balanc (Mat_IO_DP &a)
void banbks (Mat_I_DP &a, const int m1, const int m2, Mat_I_DP &al, Vec_I_INT &indx, Vec_IO_DP &b)
void bandec (Mat_IO_DP &a, const int m1, const int m2, Mat_O_DP &al, Vec_O_INT &indx, DP &d)
void banmul (Mat_I_DP &a, const int m1, const int m2, Vec_I_DP &x, Vec_O_DP &b)
void bcucof (Vec_I_DP &y, Vec_I_DP &y1, Vec_I_DP &y2, Vec_I_DP &y12, const DP d1, const DP d2, Mat_O_DP &c)
void bcuint (Vec_I_DP &y, Vec_I_DP &y1, Vec_I_DP &y2, Vec_I_DP &y12, const DP x1l, const DP x1u, const DP x2l, const DP x2u, const DP x1, const DP x2, DP &ansy, DP &ansy1, DP &ansy2)
void beschb (const DP x, DP &gam1, DP &gam2, DP &gampl, DP &gammi)
DP bessi (const int n, const DP x)
DP bessi0 (const DP x)
DP bessi1 (const DP x)
void bessik (const DP x, const DP xnu, DP &ri, DP &rk, DP &rip, DP &rkp)
DP bessj (const int n, const DP x)
DP bessj0 (const DP x)
DP bessj1 (const DP x)
void bessjy (const DP x, const DP xnu, DP &rj, DP &ry, DP &rjp, DP &ryp)
DP bessk (const int n, const DP x)
DP bessk0 (const DP x)
DP bessk1 (const DP x)
DP bessy (const int n, const DP x)
DP bessy0 (const DP x)
DP bessy1 (const DP x)
DP beta (const DP z, const DP w)
DP betacf (const DP a, const DP b, const DP x)
DP betai (const DP a, const DP b, const DP x)
DP bico (const int n, const int k)
void bksub (const int ne, const int nb, const int jf, const int k1, const int k2, Mat3D_IO_DP &c)
DP bnldev (const DP pp, const int n, int &idum)
DP brent (const DP ax, const DP bx, const DP cx, DP f(const DP), const DP tol, DP &xmin)
void broydn (Vec_IO_DP &x, bool &check, void vecfunc(Vec_I_DP &, Vec_O_DP &))
void bsstep (Vec_IO_DP &y, Vec_IO_DP &dydx, DP &xx, const DP htry, const DP eps, Vec_I_DP &yscal, DP &hdid, DP &hnext, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void caldat (const int julian, int &mm, int &id, int &iyyy)
void chder (const DP a, const DP b, Vec_I_DP &c, Vec_O_DP &cder, const int n)
DP chebev (const DP a, const DP b, Vec_I_DP &c, const int m, const DP x)
void chebft (const DP a, const DP b, Vec_O_DP &c, DP func(const DP))
void chebpc (Vec_I_DP &c, Vec_O_DP &d)
void chint (const DP a, const DP b, Vec_I_DP &c, Vec_O_DP &cint, const int n)
DP chixy (const DP bang)
void choldc (Mat_IO_DP &a, Vec_O_DP &p)
void cholsl (Mat_I_DP &a, Vec_I_DP &p, Vec_I_DP &b, Vec_O_DP &x)
void chsone (Vec_I_DP &bins, Vec_I_DP &ebins, const int knstrn, DP &df, DP &chsq, DP &prob)
void chstwo (Vec_I_DP &bins1, Vec_I_DP &bins2, const int knstrn, DP &df, DP &chsq, DP &prob)
void cisi (const DP x, complex< DP > &cs)
void cntab1 (Mat_I_INT &nn, DP &chisq, DP &df, DP &prob, DP &cramrv, DP &ccc)
void cntab2 (Mat_I_INT &nn, DP &h, DP &hx, DP &hy, DP &hygx, DP &hxgy, DP &uygx, DP &uxgy, DP &uxy)
void convlv (Vec_I_DP &data, Vec_I_DP &respns, const int isign, Vec_O_DP &ans)
void copy (Mat_O_DP &aout, Mat_I_DP &ain)
void correl (Vec_I_DP &data1, Vec_I_DP &data2, Vec_O_DP &ans)
void cosft1 (Vec_IO_DP &y)
void cosft2 (Vec_IO_DP &y, const int isign)
void covsrt (Mat_IO_DP &covar, Vec_I_BOOL &ia, const int mfit)
void crank (Vec_IO_DP &w, DP &s)
void cyclic (Vec_I_DP &a, Vec_I_DP &b, Vec_I_DP &c, const DP alpha, const DP beta, Vec_I_DP &r, Vec_O_DP &x)
void daub4 (Vec_IO_DP &a, const int n, const int isign)
DP dawson (const DP x)
DP dbrent (const DP ax, const DP bx, const DP cx, DP f(const DP), DP df(const DP), const DP tol, DP &xmin)
void ddpoly (Vec_I_DP &c, const DP x, Vec_O_DP &pd)
bool decchk (string str, char &ch)
void derivs_s (const DP x, Vec_I_DP &y, Vec_O_DP &dydx)
DP df1dim (const DP x)
void dfpmin (Vec_IO_DP &p, const DP gtol, int &iter, DP &fret, DP func(Vec_I_DP &), void dfunc(Vec_I_DP &, Vec_O_DP &))
DP dfridr (DP func(const DP), const DP x, const DP h, DP &err)
void dftcor (const DP w, const DP delta, const DP a, const DP b, Vec_I_DP &endpts, DP &corre, DP &corim, DP &corfac)
void dftint (DP func(const DP), const DP a, const DP b, const DP w, DP &cosint, DP &sinint)
void difeq (const int k, const int k1, const int k2, const int jsf, const int is1, const int isf, Vec_I_INT &indexv, Mat_O_DP &s, Mat_I_DP &y)
void dlinmin (Vec_IO_DP &p, Vec_IO_DP &xi, DP &fret, DP func(Vec_I_DP &), void dfunc(Vec_I_DP &, Vec_O_DP &))
void eclass (Vec_O_INT &nf, Vec_I_INT &lista, Vec_I_INT &listb)
void eclazz (Vec_O_INT &nf, bool equiv(const int, const int))
DP ei (const DP x)
void eigsrt (Vec_IO_DP &d, Mat_IO_DP &v)
DP elle (const DP phi, const DP ak)
DP ellf (const DP phi, const DP ak)
DP ellpi (const DP phi, const DP en, const DP ak)
void elmhes (Mat_IO_DP &a)
DP erfcc (const DP x)
DP erff (const DP x)
DP erffc (const DP x)
void eulsum (DP &sum, const DP term, const int jterm, Vec_IO_DP &wksp)
DP evlmem (const DP fdt, Vec_I_DP &d, const DP xms)
DP expdev (int &idum)
DP expint (const int n, const DP x)
DP f1dim (const DP x)
DP factln (const int n)
DP factrl (const int n)
void fasper (Vec_I_DP &x, Vec_I_DP &y, const DP ofac, const DP hifac, Vec_O_DP &wk1, Vec_O_DP &wk2, int &nout, int &jmax, DP &prob)
void fdjac (Vec_IO_DP &x, Vec_I_DP &fvec, Mat_O_DP &df, void vecfunc(Vec_I_DP &, Vec_O_DP &))
void fgauss (const DP x, Vec_I_DP &a, DP &y, Vec_O_DP &dyda)
void fit (Vec_I_DP &x, Vec_I_DP &y, Vec_I_DP &sig, const bool mwt, DP &a, DP &b, DP &siga, DP &sigb, DP &chi2, DP &q)
void fitexy (Vec_I_DP &x, Vec_I_DP &y, Vec_I_DP &sigx, Vec_I_DP &sigy, DP &a, DP &b, DP &siga, DP &sigb, DP &chi2, DP &q)
void fixrts (Vec_IO_DP &d)
void fleg (const DP x, Vec_O_DP &pl)
void flmoon (const int n, const int nph, int &jd, DP &frac)
DP fmin (Vec_I_DP &x)
void four1 (Vec_IO_DP &data, const int isign)
void fourew (Vec_FSTREAM_p &file, int &na, int &nb, int &nc, int &nd)
void fourfs (Vec_FSTREAM_p &file, Vec_I_INT &nn, const int isign)
void fourn (Vec_IO_DP &data, Vec_I_INT &nn, const int isign)
void fpoly (const DP x, Vec_O_DP &p)
void fred2 (const DP a, const DP b, Vec_O_DP &t, Vec_O_DP &f, Vec_O_DP &w, DP g(const DP), DP ak(const DP, const DP))
DP fredin (const DP x, const DP a, const DP b, Vec_I_DP &t, Vec_I_DP &f, Vec_I_DP &w, DP g(const DP), DP ak(const DP, const DP))
void frenel (const DP x, complex< DP > &cs)
void frprmn (Vec_IO_DP &p, const DP ftol, int &iter, DP &fret, DP func(Vec_I_DP &), void dfunc(Vec_I_DP &, Vec_O_DP &))
void ftest (Vec_I_DP &data1, Vec_I_DP &data2, DP &f, DP &prob)
DP gamdev (const int ia, int &idum)
DP gammln (const DP xx)
DP gammp (const DP a, const DP x)
DP gammq (const DP a, const DP x)
DP gasdev (int &idum)
void gaucof (Vec_IO_DP &a, Vec_IO_DP &b, const DP amu0, Vec_O_DP &x, Vec_O_DP &w)
void gauher (Vec_O_DP &x, Vec_O_DP &w)
void gaujac (Vec_O_DP &x, Vec_O_DP &w, const DP alf, const DP bet)
void gaulag (Vec_O_DP &x, Vec_O_DP &w, const DP alf)
void gauleg (const DP x1, const DP x2, Vec_O_DP &x, Vec_O_DP &w)
void gaussj (Mat_IO_DP &a, Mat_IO_DP &b)
void gcf (DP &gammcf, const DP a, const DP x, DP &gln)
DP golden (const DP ax, const DP bx, const DP cx, DP f(const DP), const DP tol, DP &xmin)
void gser (DP &gamser, const DP a, const DP x, DP &gln)
void hpsel (Vec_I_DP &arr, Vec_O_DP &heap)
void hpsort (Vec_IO_DP &ra)
void hqr (Mat_IO_DP &a, Vec_O_CPLX_DP &wri)
void hufapp (Vec_IO_ULNG &index, Vec_I_ULNG &nprob, const unsigned long n, const unsigned long m)
void hufdec (unsigned long &ich, string &code, const unsigned long lcode, unsigned long &nb, huffcode &hcode)
void hufenc (const unsigned long ich, string &code, unsigned long &nb, huffcode &hcode)
void hufmak (Vec_I_ULNG &nfreq, const unsigned long nchin, unsigned long &ilong, unsigned long &nlong, huffcode &hcode)
void hunt (Vec_I_DP &xx, const DP x, int &jlo)
void hypdrv (const DP s, Vec_I_DP &yy, Vec_O_DP &dyyds)
complex< DPhypgeo (const complex< DP > &a, const complex< DP > &b, const complex< DP > &c, const complex< DP > &z)
void hypser (const complex< DP > &a, const complex< DP > &b, const complex< DP > &c, const complex< DP > &z, complex< DP > &series, complex< DP > &deriv)
unsigned short icrc (const unsigned short crc, const string &bufptr, const short jinit, const int jrev)
unsigned short icrc1 (const unsigned short crc, const unsigned char onech)
unsigned long igray (const unsigned long n, const int is)
void indexx (Vec_I_DP &arr, Vec_O_INT &indx)
void indexx (Vec_I_INT &arr, Vec_O_INT &indx)
void interp (Mat_O_DP &uf, Mat_I_DP &uc)
int irbit1 (unsigned long &iseed)
int irbit2 (unsigned long &iseed)
void jacobi (Mat_IO_DP &a, Vec_O_DP &d, Mat_O_DP &v, int &nrot)
void jacobn_s (const DP x, Vec_I_DP &y, Vec_O_DP &dfdx, Mat_O_DP &dfdy)
int julday (const int mm, const int id, const int iyyy)
void kendl1 (Vec_I_DP &data1, Vec_I_DP &data2, DP &tau, DP &z, DP &prob)
void kendl2 (Mat_I_DP &tab, DP &tau, DP &z, DP &prob)
void kermom (Vec_O_DP &w, const DP y)
void ks2d1s (Vec_I_DP &x1, Vec_I_DP &y1, void quadvl(const DP, const DP, DP &, DP &, DP &, DP &), DP &d1, DP &prob)
void ks2d2s (Vec_I_DP &x1, Vec_I_DP &y1, Vec_I_DP &x2, Vec_I_DP &y2, DP &d, DP &prob)
void ksone (Vec_IO_DP &data, DP func(const DP), DP &d, DP &prob)
void kstwo (Vec_IO_DP &data1, Vec_IO_DP &data2, DP &d, DP &prob)
void laguer (Vec_I_CPLX_DP &a, complex< DP > &x, int &its)
void lfit (Vec_I_DP &x, Vec_I_DP &y, Vec_I_DP &sig, Vec_IO_DP &a, Vec_I_BOOL &ia, Mat_O_DP &covar, DP &chisq, void funcs(const DP, Vec_O_DP &))
void linbcg (Vec_I_DP &b, Vec_IO_DP &x, const int itol, const DP tol, const int itmax, int &iter, DP &err)
void linmin (Vec_IO_DP &p, Vec_IO_DP &xi, DP &fret, DP func(Vec_I_DP &))
void lnsrch (Vec_I_DP &xold, const DP fold, Vec_I_DP &g, Vec_IO_DP &p, Vec_O_DP &x, DP &f, const DP stpmax, bool &check, DP func(Vec_I_DP &))
void locate (Vec_I_DP &xx, const DP x, int &j)
void lop (Mat_O_DP &out, Mat_I_DP &u)
void lubksb (Mat_I_DP &a, Vec_I_INT &indx, Vec_IO_DP &b)
void ludcmp (Mat_IO_DP &a, Vec_O_INT &indx, DP &d)
void machar (int &ibeta, int &it, int &irnd, int &ngrd, int &machep, int &negep, int &iexp, int &minexp, int &maxexp, DP &eps, DP &epsneg, DP &xmin, DP &xmax)
void matadd (Mat_I_DP &a, Mat_I_DP &b, Mat_O_DP &c)
void matsub (Mat_I_DP &a, Mat_I_DP &b, Mat_O_DP &c)
void medfit (Vec_I_DP &x, Vec_I_DP &y, DP &a, DP &b, DP &abdev)
void memcof (Vec_I_DP &data, DP &xms, Vec_O_DP &d)
bool metrop (const DP de, const DP t)
void mgfas (Mat_IO_DP &u, const int maxcyc)
void mglin (Mat_IO_DP &u, const int ncycle)
DP midexp (DP funk(const DP), const DP aa, const DP bb, const int n)
DP midinf (DP funk(const DP), const DP aa, const DP bb, const int n)
DP midpnt (DP func(const DP), const DP a, const DP b, const int n)
DP midsql (DP funk(const DP), const DP aa, const DP bb, const int n)
DP midsqu (DP funk(const DP), const DP aa, const DP bb, const int n)
void miser (DP func(Vec_I_DP &), Vec_I_DP &regn, const int npts, const DP dith, DP &ave, DP &var)
void mmid (Vec_I_DP &y, Vec_I_DP &dydx, const DP xs, const DP htot, const int nstep, Vec_O_DP &yout, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void mnbrak (DP &ax, DP &bx, DP &cx, DP &fa, DP &fb, DP &fc, DP func(const DP))
void mnewt (const int ntrial, Vec_IO_DP &x, const DP tolx, const DP tolf)
void moment (Vec_I_DP &data, DP &ave, DP &adev, DP &sdev, DP &var, DP &skew, DP &curt)
void mp2dfr (Vec_IO_UCHR &a, string &s)
void mpadd (Vec_O_UCHR &w, Vec_I_UCHR &u, Vec_I_UCHR &v)
void mpdiv (Vec_O_UCHR &q, Vec_O_UCHR &r, Vec_I_UCHR &u, Vec_I_UCHR &v)
void mpinv (Vec_O_UCHR &u, Vec_I_UCHR &v)
void mplsh (Vec_IO_UCHR &u)
void mpmov (Vec_O_UCHR &u, Vec_I_UCHR &v)
void mpmul (Vec_O_UCHR &w, Vec_I_UCHR &u, Vec_I_UCHR &v)
void mpneg (Vec_IO_UCHR &u)
void mppi (const int np)
void mprove (Mat_I_DP &a, Mat_I_DP &alud, Vec_I_INT &indx, Vec_I_DP &b, Vec_IO_DP &x)
void mpsad (Vec_O_UCHR &w, Vec_I_UCHR &u, const int iv)
void mpsdv (Vec_O_UCHR &w, Vec_I_UCHR &u, const int iv, int &ir)
void mpsmu (Vec_O_UCHR &w, Vec_I_UCHR &u, const int iv)
void mpsqrt (Vec_O_UCHR &w, Vec_O_UCHR &u, Vec_I_UCHR &v)
void mpsub (int &is, Vec_O_UCHR &w, Vec_I_UCHR &u, Vec_I_UCHR &v)
void mrqcof (Vec_I_DP &x, Vec_I_DP &y, Vec_I_DP &sig, Vec_I_DP &a, Vec_I_BOOL &ia, Mat_O_DP &alpha, Vec_O_DP &beta, DP &chisq, void funcs(const DP, Vec_I_DP &, DP &, Vec_O_DP &))
void mrqmin (Vec_I_DP &x, Vec_I_DP &y, Vec_I_DP &sig, Vec_IO_DP &a, Vec_I_BOOL &ia, Mat_O_DP &covar, Mat_O_DP &alpha, DP &chisq, void funcs(const DP, Vec_I_DP &, DP &, Vec_O_DP &), DP &alamda)
void newt (Vec_IO_DP &x, bool &check, void vecfunc(Vec_I_DP &, Vec_O_DP &))
void odeint (Vec_IO_DP &ystart, const DP x1, const DP x2, const DP eps, const DP h1, const DP hmin, int &nok, int &nbad, void derivs(const DP, Vec_I_DP &, Vec_O_DP &), void rkqs(Vec_IO_DP &, Vec_IO_DP &, DP &, const DP, const DP, Vec_I_DP &, DP &, DP &, void(*)(const DP, Vec_I_DP &, Vec_O_DP &)))
void orthog (Vec_I_DP &anu, Vec_I_DP &alpha, Vec_I_DP &beta, Vec_O_DP &a, Vec_O_DP &b)
void pade (Vec_IO_DP &cof, DP &resid)
void pccheb (Vec_I_DP &d, Vec_O_DP &c)
void pcshft (const DP a, const DP b, Vec_IO_DP &d)
void pearsn (Vec_I_DP &x, Vec_I_DP &y, DP &r, DP &prob, DP &z)
void period (Vec_I_DP &x, Vec_I_DP &y, const DP ofac, const DP hifac, Vec_O_DP &px, Vec_O_DP &py, int &nout, int &jmax, DP &prob)
void piksr2 (Vec_IO_DP &arr, Vec_IO_DP &brr)
void piksrt (Vec_IO_DP &arr)
void pinvs (const int ie1, const int ie2, const int je1, const int jsf, const int jc1, const int k, Mat3D_O_DP &c, Mat_IO_DP &s)
DP plgndr (const int l, const int m, const DP x)
DP poidev (const DP xm, int &idum)
void polcoe (Vec_I_DP &x, Vec_I_DP &y, Vec_O_DP &cof)
void polcof (Vec_I_DP &xa, Vec_I_DP &ya, Vec_O_DP &cof)
void poldiv (Vec_I_DP &u, Vec_I_DP &v, Vec_O_DP &q, Vec_O_DP &r)
void polin2 (Vec_I_DP &x1a, Vec_I_DP &x2a, Mat_I_DP &ya, const DP x1, const DP x2, DP &y, DP &dy)
void polint (Vec_I_DP &xa, Vec_I_DP &ya, const DP x, DP &y, DP &dy)
void powell (Vec_IO_DP &p, Mat_IO_DP &xi, const DP ftol, int &iter, DP &fret, DP func(Vec_I_DP &))
void predic (Vec_I_DP &data, Vec_I_DP &d, Vec_O_DP &future)
DP probks (const DP alam)
void psdes (unsigned long &lword, unsigned long &irword)
void pwt (Vec_IO_DP &a, const int n, const int isign)
void pwtset (const int n)
DP pythag (const DP a, const DP b)
void pzextr (const int iest, const DP xest, Vec_I_DP &yest, Vec_O_DP &yz, Vec_O_DP &dy)
DP qgaus (DP func(const DP), const DP a, const DP b)
void qrdcmp (Mat_IO_DP &a, Vec_O_DP &c, Vec_O_DP &d, bool &sing)
DP qromb (DP func(const DP), DP a, DP b)
DP qromo (DP func(const DP), const DP a, const DP b, DP choose(DP(*)(const DP), const DP, const DP, const int))
void qroot (Vec_I_DP &p, DP &b, DP &c, const DP eps)
void qrsolv (Mat_I_DP &a, Vec_I_DP &c, Vec_I_DP &d, Vec_IO_DP &b)
void qrupdt (Mat_IO_DP &r, Mat_IO_DP &qt, Vec_IO_DP &u, Vec_I_DP &v)
DP qsimp (DP func(const DP), const DP a, const DP b)
DP qtrap (DP func(const DP), const DP a, const DP b)
DP quad3d (DP func(const DP, const DP, const DP), const DP x1, const DP x2)
void quadct (const DP x, const DP y, Vec_I_DP &xx, Vec_I_DP &yy, DP &fa, DP &fb, DP &fc, DP &fd)
void quadmx (Mat_O_DP &a)
void quadvl (const DP x, const DP y, DP &fa, DP &fb, DP &fc, DP &fd)
DP ran0 (int &idum)
DP ran1 (int &idum)
DP ran2 (int &idum)
DP ran3 (int &idum)
DP ran4 (int &idum)
void rank (Vec_I_INT &indx, Vec_O_INT &irank)
void ranpt (Vec_O_DP &pt, Vec_I_DP &regn)
void ratint (Vec_I_DP &xa, Vec_I_DP &ya, const DP x, DP &y, DP &dy)
void ratlsq (DP fn(const DP), const DP a, const DP b, const int mm, const int kk, Vec_O_DP &cof, DP &dev)
DP ratval (const DP x, Vec_I_DP &cof, const int mm, const int kk)
DP rc (const DP x, const DP y)
DP rd (const DP x, const DP y, const DP z)
void realft (Vec_IO_DP &data, const int isign)
void rebin (const DP rc, const int nd, Vec_I_DP &r, Vec_O_DP &xin, Mat_IO_DP &xi, const int j)
void red (const int iz1, const int iz2, const int jz1, const int jz2, const int jm1, const int jm2, const int jmf, const int ic1, const int jc1, const int jcf, const int kc, Mat3D_I_DP &c, Mat_IO_DP &s)
void relax (Mat_IO_DP &u, Mat_I_DP &rhs)
void relax2 (Mat_IO_DP &u, Mat_I_DP &rhs)
void resid (Mat_O_DP &res, Mat_I_DP &u, Mat_I_DP &rhs)
DP revcst (Vec_I_DP &x, Vec_I_DP &y, Vec_I_INT &iorder, Vec_IO_INT &n)
void reverse (Vec_IO_INT &iorder, Vec_I_INT &n)
DP rf (const DP x, const DP y, const DP z)
DP rj (const DP x, const DP y, const DP z, const DP p)
void rk4 (Vec_I_DP &y, Vec_I_DP &dydx, const DP x, const DP h, Vec_O_DP &yout, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void rkck (Vec_I_DP &y, Vec_I_DP &dydx, const DP x, const DP h, Vec_O_DP &yout, Vec_O_DP &yerr, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void rkdumb (Vec_I_DP &vstart, const DP x1, const DP x2, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void rkqs (Vec_IO_DP &y, Vec_IO_DP &dydx, DP &x, const DP htry, const DP eps, Vec_I_DP &yscal, DP &hdid, DP &hnext, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void rlft3 (Mat3D_IO_DP &data, Mat_IO_DP &speq, const int isign)
DP rofunc (const DP b)
void rotate (Mat_IO_DP &r, Mat_IO_DP &qt, const int i, const DP a, const DP b)
void rsolv (Mat_I_DP &a, Vec_I_DP &d, Vec_IO_DP &b)
void rstrct (Mat_O_DP &uc, Mat_I_DP &uf)
DP rtbis (DP func(const DP), const DP x1, const DP x2, const DP xacc)
DP rtflsp (DP func(const DP), const DP x1, const DP x2, const DP xacc)
DP rtsec (DP func(const DP), const DP x1, const DP x2, const DP xacc)
void rzextr (const int iest, const DP xest, Vec_I_DP &yest, Vec_O_DP &yz, Vec_O_DP &dy)
void savgol (Vec_O_DP &c, const int np, const int nl, const int nr, const int ld, const int m)
void scrsho (DP fx(const DP))
DP select (const int k, Vec_IO_DP &arr)
DP selip (const int k, Vec_I_DP &arr)
void shell (const int n, Vec_IO_DP &a)
void shoot (Vec_I_DP &v, Vec_O_DP &f)
void shootf (Vec_I_DP &v, Vec_O_DP &f)
void simp1 (Mat_I_DP &a, const int mm, Vec_I_INT &ll, const int nll, const int iabf, int &kp, DP &bmax)
void simp2 (Mat_I_DP &a, const int m, const int n, int &ip, const int kp)
void simp3 (Mat_IO_DP &a, const int i1, const int k1, const int ip, const int kp)
void simplx (Mat_IO_DP &a, const int m1, const int m2, const int m3, int &icase, Vec_O_INT &izrov, Vec_O_INT &iposv)
void simpr (Vec_I_DP &y, Vec_I_DP &dydx, Vec_I_DP &dfdx, Mat_I_DP &dfdy, const DP xs, const DP htot, const int nstep, Vec_O_DP &yout, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void sinft (Vec_IO_DP &y)
void slvsm2 (Mat_O_DP &u, Mat_I_DP &rhs)
void slvsml (Mat_O_DP &u, Mat_I_DP &rhs)
void sncndn (const DP uu, const DP emmc, DP &sn, DP &cn, DP &dn)
DP snrm (Vec_I_DP &sx, const int itol)
void sobseq (const int n, Vec_O_DP &x)
void solvde (const int itmax, const DP conv, const DP slowc, Vec_I_DP &scalv, Vec_I_INT &indexv, const int nb, Mat_IO_DP &y)
void sor (Mat_I_DP &a, Mat_I_DP &b, Mat_I_DP &c, Mat_I_DP &d, Mat_I_DP &e, Mat_I_DP &f, Mat_IO_DP &u, const DP rjac)
void sort (Vec_IO_DP &arr)
void sort2 (Vec_IO_DP &arr, Vec_IO_DP &brr)
void sort3 (Vec_IO_DP &ra, Vec_IO_DP &rb, Vec_IO_DP &rc)
void spctrm (ifstream &fp, Vec_O_DP &p, const int k, const bool ovrlap)
void spear (Vec_I_DP &data1, Vec_I_DP &data2, DP &d, DP &zd, DP &probd, DP &rs, DP &probrs)
void sphbes (const int n, const DP x, DP &sj, DP &sy, DP &sjp, DP &syp)
void splie2 (Vec_I_DP &x1a, Vec_I_DP &x2a, Mat_I_DP &ya, Mat_O_DP &y2a)
void splin2 (Vec_I_DP &x1a, Vec_I_DP &x2a, Mat_I_DP &ya, Mat_I_DP &y2a, const DP x1, const DP x2, DP &y)
void spline (Vec_I_DP &x, Vec_I_DP &y, const DP yp1, const DP ypn, Vec_O_DP &y2)
void splint (Vec_I_DP &xa, Vec_I_DP &ya, Vec_I_DP &y2a, const DP x, DP &y)
void spread (const DP y, Vec_IO_DP &yy, const DP x, const int m)
void sprsax (Vec_I_DP &sa, Vec_I_INT &ija, Vec_I_DP &x, Vec_O_DP &b)
void sprsin (Mat_I_DP &a, const DP thresh, Vec_O_DP &sa, Vec_O_INT &ija)
void sprspm (Vec_I_DP &sa, Vec_I_INT &ija, Vec_I_DP &sb, Vec_I_INT &ijb, Vec_O_DP &sc, Vec_I_INT &ijc)
void sprstm (Vec_I_DP &sa, Vec_I_INT &ija, Vec_I_DP &sb, Vec_I_INT &ijb, const DP thresh, Vec_O_DP &sc, Vec_O_INT &ijc)
void sprstp (Vec_I_DP &sa, Vec_I_INT &ija, Vec_O_DP &sb, Vec_O_INT &ijb)
void sprstx (Vec_I_DP &sa, Vec_I_INT &ija, Vec_I_DP &x, Vec_O_DP &b)
void stifbs (Vec_IO_DP &y, Vec_IO_DP &dydx, DP &xx, const DP htry, const DP eps, Vec_I_DP &yscal, DP &hdid, DP &hnext, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void stiff (Vec_IO_DP &y, Vec_IO_DP &dydx, DP &x, const DP htry, const DP eps, Vec_I_DP &yscal, DP &hdid, DP &hnext, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void stoerm (Vec_I_DP &y, Vec_I_DP &d2y, const DP xs, const DP htot, const int nstep, Vec_O_DP &yout, void derivs(const DP, Vec_I_DP &, Vec_O_DP &))
void svbksb (Mat_I_DP &u, Vec_I_DP &w, Mat_I_DP &v, Vec_I_DP &b, Vec_O_DP &x)
void svdcmp (Mat_IO_DP &a, Vec_O_DP &w, Mat_O_DP &v)
void svdfit (Vec_I_DP &x, Vec_I_DP &y, Vec_I_DP &sig, Vec_O_DP &a, Mat_O_DP &u, Mat_O_DP &v, Vec_O_DP &w, DP &chisq, void funcs(const DP, Vec_O_DP &))
void svdvar (Mat_I_DP &v, Vec_I_DP &w, Mat_O_DP &cvm)
void toeplz (Vec_I_DP &r, Vec_O_DP &x, Vec_I_DP &y)
void tptest (Vec_I_DP &data1, Vec_I_DP &data2, DP &t, DP &prob)
void tqli (Vec_IO_DP &d, Vec_IO_DP &e, Mat_IO_DP &z)
DP trapzd (DP func(const DP), const DP a, const DP b, const int n)
void tred2 (Mat_IO_DP &a, Vec_O_DP &d, Vec_O_DP &e)
void tridag (Vec_I_DP &a, Vec_I_DP &b, Vec_I_DP &c, Vec_I_DP &r, Vec_O_DP &u)
DP trncst (Vec_I_DP &x, Vec_I_DP &y, Vec_I_INT &iorder, Vec_IO_INT &n)
void trnspt (Vec_IO_INT &iorder, Vec_I_INT &n)
void ttest (Vec_I_DP &data1, Vec_I_DP &data2, DP &t, DP &prob)
void tutest (Vec_I_DP &data1, Vec_I_DP &data2, DP &t, DP &prob)
void twofft (Vec_I_DP &data1, Vec_I_DP &data2, Vec_O_DP &fft1, Vec_O_DP &fft2)
void vander (Vec_I_DP &x, Vec_O_DP &w, Vec_I_DP &q)
void vegas (Vec_I_DP &regn, DP fxn(Vec_I_DP &, const DP), const int init, const int ncall, const int itmx, const int nprn, DP &tgral, DP &sd, DP &chi2a)
void voltra (const DP t0, const DP h, Vec_O_DP &t, Mat_O_DP &f, DP g(const int, const DP), DP ak(const int, const int, const DP, const DP))
void wt1 (Vec_IO_DP &a, const int isign, void wtstep(Vec_IO_DP &, const int, const int))
void wtn (Vec_IO_DP &a, Vec_I_INT &nn, const int isign, void wtstep(Vec_IO_DP &, const int, const int))
void wwghts (Vec_O_DP &wghts, const DP h, void kermom(Vec_O_DP &w, const DP y))
bool zbrac (DP func(const DP), DP &x1, DP &x2)
void zbrak (DP fx(const DP), const DP x1, const DP x2, const int n, Vec_O_DP &xb1, Vec_O_DP &xb2, int &nroot)
DP zbrent (DP func(const DP), const DP x1, const DP x2, const DP tol)
void zrhqr (Vec_I_DP &a, Vec_O_CPLX_DP &rt)
DP zriddr (DP func(const DP), const DP x1, const DP x2, const DP xacc)
void zroots (Vec_I_CPLX_DP &a, Vec_O_CPLX_DP &roots, const bool &polish)
void nrerror (const string error_text)


Function Documentation

void addint Mat_O_DP uf,
Mat_I_DP uc,
Mat_O_DP res
 

void airy const DP  x,
DP ai,
DP bi,
DP aip,
DP bip
 

void amebsa Mat_IO_DP p,
Vec_IO_DP y,
Vec_O_DP pb,
DP yb,
const DP  ftol,
DP   funk(Vec_I_DP &),
int &  iter,
const DP  temptr
 

void amoeba Mat_IO_DP p,
Vec_IO_DP y,
const DP  ftol,
DP   funk(Vec_I_DP &),
int &  nfunk
 

DP amotry Mat_IO_DP p,
Vec_O_DP y,
Vec_IO_DP psum,
DP   funk(Vec_I_DP &),
const int  ihi,
const DP  fac
 

DP amotsa Mat_IO_DP p,
Vec_O_DP y,
Vec_IO_DP psum,
Vec_O_DP pb,
DP yb,
DP   funk(Vec_I_DP &),
const int  ihi,
DP yhi,
const DP  fac
 

void anneal Vec_I_DP x,
Vec_I_DP y,
Vec_IO_INT iorder
 

DP anorm2 Mat_I_DP a  ) 
 

void arcmak Vec_I_ULNG nfreq,
unsigned long  nchh,
unsigned long  nradd,
arithcode acode
 

void arcode unsigned long &  ich,
string &  code,
unsigned long &  lcd,
const int  isign,
arithcode acode
 

void arcsum Vec_I_ULNG iin,
Vec_O_ULNG iout,
unsigned long  ja,
const int  nwk,
const unsigned long  nrad,
const unsigned long  nc
 

void asolve Vec_I_DP b,
Vec_O_DP x,
const int  itrnsp
 

void atimes Vec_I_DP x,
Vec_O_DP r,
const int  itrnsp
 

void avevar Vec_I_DP data,
DP ave,
DP var
 

void balanc Mat_IO_DP a  ) 
 

void banbks Mat_I_DP a,
const int  m1,
const int  m2,
Mat_I_DP al,
Vec_I_INT indx,
Vec_IO_DP b
 

void bandec Mat_IO_DP a,
const int  m1,
const int  m2,
Mat_O_DP al,
Vec_O_INT indx,
DP d
 

void banmul Mat_I_DP a,
const int  m1,
const int  m2,
Vec_I_DP x,
Vec_O_DP b
 

void bcucof Vec_I_DP y,
Vec_I_DP y1,
Vec_I_DP y2,
Vec_I_DP y12,
const DP  d1,
const DP  d2,
Mat_O_DP c
 

void bcuint Vec_I_DP y,
Vec_I_DP y1,
Vec_I_DP y2,
Vec_I_DP y12,
const DP  x1l,
const DP  x1u,
const DP  x2l,
const DP  x2u,
const DP  x1,
const DP  x2,
DP ansy,
DP ansy1,
DP ansy2
 

void beschb const DP  x,
DP gam1,
DP gam2,
DP gampl,
DP gammi
 

DP bessi const int  n,
const DP  x
 

DP bessi0 const DP  x  ) 
 

DP bessi1 const DP  x  ) 
 

void bessik const DP  x,
const DP  xnu,
DP ri,
DP rk,
DP rip,
DP rkp
 

DP bessj const int  n,
const DP  x
 

DP bessj0 const DP  x  ) 
 

DP bessj1 const DP  x  ) 
 

void bessjy const DP  x,
const DP  xnu,
DP rj,
DP ry,
DP rjp,
DP ryp
 

DP bessk const int  n,
const DP  x
 

DP bessk0 const DP  x  ) 
 

DP bessk1 const DP  x  ) 
 

DP bessy const int  n,
const DP  x
 

DP bessy0 const DP  x  ) 
 

DP bessy1 const DP  x  ) 
 

DP beta const DP  z,
const DP  w
 

Referenced by mrqcof(), MinosMinimization::MrqCof(), mrqmin(), and MinosMinimization::MrqMin().

DP betacf const DP  a,
const DP  b,
const DP  x
 

DP betai const DP  a,
const DP  b,
const DP  x
 

DP bico const int  n,
const int  k
 

void bksub const int  ne,
const int  nb,
const int  jf,
const int  k1,
const int  k2,
Mat3D_IO_DP c
 

DP bnldev const DP  pp,
const int  n,
int &  idum
 

DP NR::brent const DP  ax,
const DP  bx,
const DP  cx,
DP   f(const DP),
const DP  tol,
DP xmin
 

Definition at line 27 of file nr.cxx.

References DP, nrerror(), shft3(), and SIGN().

Referenced by linmin().

00029 {
00030   const int ITMAX=100;
00031   const DP CGOLD=0.3819660;
00032   const DP ZEPS=numeric_limits<DP>::epsilon()*1.0e-3;
00033   int iter;
00034   DP a,b,d=0.0,etemp,fu,fv,fw,fx;
00035   DP p,q,r,tol1,tol2,u,v,w,x,xm;
00036   DP e=0.0;
00037   
00038   a=(ax < cx ? ax : cx);
00039   b=(ax > cx ? ax : cx);
00040   x=w=v=bx;
00041   fw=fv=fx=f(x);
00042   for (iter=0;iter<ITMAX;iter++) {
00043     xm=0.5*(a+b);
00044     tol2=2.0*(tol1=tol*fabs(x)+ZEPS);
00045     if (fabs(x-xm) <= (tol2-0.5*(b-a))) {
00046       xmin=x;
00047       return fx;
00048     }
00049     if (fabs(e) > tol1) {
00050       r=(x-w)*(fx-fv);
00051       q=(x-v)*(fx-fw);
00052       p=(x-v)*q-(x-w)*r;
00053       q=2.0*(q-r);
00054       if (q > 0.0) p = -p;
00055       q=fabs(q);
00056       etemp=e;
00057       e=d;
00058       if (fabs(p) >= fabs(0.5*q*etemp) || p <= q*(a-x) || p >= q*(b-x))
00059         d=CGOLD*(e=(x >= xm ? a-x : b-x));
00060       else {
00061         d=p/q;
00062         u=x+d;
00063         if (u-a < tol2 || b-u < tol2)
00064           d=SIGN(tol1,xm-x);
00065       }
00066     } else {
00067       d=CGOLD*(e=(x >= xm ? a-x : b-x));
00068     }
00069     u=(fabs(d) >= tol1 ? x+d : x+SIGN(tol1,d));
00070     fu=f(u);
00071     if (fu <= fx) {
00072       if (u >= x) a=x; else b=x;
00073       shft3(v,w,x,u);
00074       shft3(fv,fw,fx,fu);
00075     } else {
00076       if (u < x) a=u; else b=u;
00077       if (fu <= fw || w == x) {
00078         v=w;
00079         w=u;
00080         fv=fw;
00081         fw=fu;
00082       } else if (fu <= fv || v == x || v == w) {
00083         v=u;
00084         fv=fu;
00085       }
00086     }
00087   }
00088   nrerror("Too many iterations in brent");
00089   xmin=x;
00090   return fx;
00091 }

void broydn Vec_IO_DP x,
bool &  check,
void   vecfunc(Vec_I_DP &, Vec_O_DP &)
 

void bsstep Vec_IO_DP y,
Vec_IO_DP dydx,
DP xx,
const DP  htry,
const DP  eps,
Vec_I_DP yscal,
DP hdid,
DP hnext,
void   derivs(const DP, Vec_I_DP &, Vec_O_DP &)
 

void caldat const int  julian,
int &  mm,
int &  id,
int &  iyyy
 

void chder const DP  a,
const DP  b,
Vec_I_DP c,
Vec_O_DP cder,
const int  n
 

DP chebev const DP  a,
const DP  b,
Vec_I_DP c,
const int  m,
const DP  x
 

void chebft const DP  a,
const DP  b,
Vec_O_DP c,
DP   func(const DP)
 

void chebpc Vec_I_DP c,
Vec_O_DP d
 

void chint const DP  a,
const DP  b,
Vec_I_DP c,
Vec_O_DP cint,
const int  n
 

DP chixy const DP  bang  ) 
 

void choldc Mat_IO_DP a,
Vec_O_DP p
 

void cholsl Mat_I_DP a,
Vec_I_DP p,
Vec_I_DP b,
Vec_O_DP x
 

void chsone Vec_I_DP bins,
Vec_I_DP ebins,
const int  knstrn,
DP df,
DP chsq,
DP prob
 

void chstwo Vec_I_DP bins1,
Vec_I_DP bins2,
const int  knstrn,
DP df,
DP chsq,
DP prob
 

void cisi const DP  x,
complex< DP > &  cs
 

void cntab1 Mat_I_INT nn,
DP chisq,
DP df,
DP prob,
DP cramrv,
DP ccc
 

void cntab2 Mat_I_INT nn,
DP h,
DP hx,
DP hy,
DP hygx,
DP hxgy,
DP uygx,
DP uxgy,
DP uxy
 

void convlv Vec_I_DP data,
Vec_I_DP respns,
const int  isign,
Vec_O_DP ans
 

void copy Mat_O_DP aout,
Mat_I_DP ain
 

Referenced by AltAlgSliceList::checkPeakUVDifference(), AltAlgSliceList::computeSliceCentroid(), LIPatternFinderSimple::GetEWAsymmetry(), idep_BinRel::idep_BinRel(), NRMat< int >::NRMat(), NRVec< DP >::NRVec(), NRMat< int >::operator=(), NRVec< DP >::operator=(), idep_BinRel::operator=(), OltNewModule::ProcessTimeframe(), OltNewModule::Reco(), Anp::RunkNN::Run(), AltAlgSliceList::Split(), and AltAlgSliceList::ZeroChargeInAView().

void correl Vec_I_DP data1,
Vec_I_DP data2,
Vec_O_DP ans
 

void cosft1 Vec_IO_DP y  ) 
 

void cosft2 Vec_IO_DP y,
const int  isign
 

void NR::covsrt Mat_IO_DP covar,
Vec_I_BOOL ia,
const int  mfit
 

Definition at line 94 of file nr.cxx.

References Mat_IO_DP, NRVec< T >::size(), SWAP(), and Vec_I_BOOL.

Referenced by mrqmin(), and MinosMinimization::MrqMin().

00095 {
00096   int i,j,k;
00097   
00098   int ma=ia.size();
00099   for (i=mfit;i<ma;i++)
00100     for (j=0;j<i+1;j++) covar[i][j]=covar[j][i]=0.0;
00101   k=mfit-1;
00102   for (j=ma-1;j>=0;j--) {
00103     if (ia[j]) {
00104       for (i=0;i<ma;i++) SWAP(covar[i][k],covar[i][j]);
00105       for (i=0;i<ma;i++) SWAP(covar[k][i],covar[j][i]);
00106       k--;
00107     }
00108   }
00109 }

void crank Vec_IO_DP w,
DP s
 

void cyclic Vec_I_DP a,
Vec_I_DP b,
Vec_I_DP c,
const DP  alpha,
const DP  beta,
Vec_I_DP r,
Vec_O_DP x
 

void daub4 Vec_IO_DP a,
const int  n,
const int  isign
 

DP dawson const DP  x  ) 
 

DP dbrent const DP  ax,
const DP  bx,
const DP  cx,
DP   f(const DP),
DP   df(const DP),
const DP  tol,
DP xmin
 

void ddpoly Vec_I_DP c,
const DP  x,
Vec_O_DP pd
 

bool decchk string  str,
char &  ch
 

void derivs_s const DP  x,
Vec_I_DP y,
Vec_O_DP dydx
 

DP df1dim const DP  x  ) 
 

void dfpmin Vec_IO_DP p,
const DP  gtol,
int &  iter,
DP fret,
DP   func(Vec_I_DP &),
void   dfunc(Vec_I_DP &, Vec_O_DP &)
 

DP dfridr DP   func(const DP),
const DP  x,
const DP  h,
DP err
 

void dftcor const DP  w,
const DP  delta,
const DP  a,
const DP  b,
Vec_I_DP endpts,
DP corre,
DP corim,
DP corfac
 

void dftint DP   func(const DP),
const DP  a,
const DP  b,
const DP  w,
DP cosint,
DP sinint
 

void difeq const int  k,
const int  k1,
const int  k2,
const int  jsf,
const int  is1,
const int  isf,
Vec_I_INT indexv,
Mat_O_DP s,
Mat_I_DP y
 

void dlinmin Vec_IO_DP p,
Vec_IO_DP xi,
DP fret,
DP   func(Vec_I_DP &),
void   dfunc(Vec_I_DP &, Vec_O_DP &)
 

void eclass Vec_O_INT nf,
Vec_I_INT lista,
Vec_I_INT listb
 

void eclazz Vec_O_INT nf,
bool   equiv(const int, const int)
 

DP ei const DP  x  ) 
 

void eigsrt Vec_IO_DP d,
Mat_IO_DP v
 

DP elle const DP  phi,
const DP  ak
 

DP ellf const DP  phi,
const DP  ak
 

DP ellpi const DP  phi,
const DP  en,
const DP  ak
 

void elmhes Mat_IO_DP a  ) 
 

DP erfcc const DP  x  ) 
 

DP erff const DP  x  ) 
 

DP erffc const DP  x  ) 
 

void eulsum DP sum,
const DP  term,
const int  jterm,
Vec_IO_DP wksp
 

DP evlmem const DP  fdt,
Vec_I_DP d,
const DP  xms
 

DP expdev int &  idum  ) 
 

DP expint const int  n,
const DP  x
 

DP NR::f1dim const DP  x  ) 
 

Definition at line 112 of file nr.cxx.

References DP, ncom, nrfunc, and Vec_DP.

Referenced by linmin().

00113 {
00114   int j;
00115   
00116   Vec_DP xt(ncom);
00117   Vec_DP &pcom=*pcom_p,&xicom=*xicom_p;
00118   for (j=0;j<ncom;j++)
00119     xt[j]=pcom[j]+x*xicom[j];
00120   return nrfunc(xt);
00121 }

DP factln const int  n  ) 
 

DP factrl const int  n  ) 
 

void fasper Vec_I_DP x,
Vec_I_DP y,
const DP  ofac,
const DP  hifac,
Vec_O_DP wk1,
Vec_O_DP wk2,
int &  nout,
int &  jmax,
DP prob
 

void fdjac Vec_IO_DP x,
Vec_I_DP fvec,
Mat_O_DP df,
void   vecfunc(Vec_I_DP &, Vec_O_DP &)
 

void NR::fgauss const DP  x,
Vec_I_DP a,
DP y,
Vec_O_DP dyda
 

Definition at line 124 of file nr.cxx.

References DP, NRVec< T >::size(), Vec_I_DP, and Vec_O_DP.

00125 {
00126   int i;
00127   DP fac,ex,arg;
00128   
00129   int na=a.size();
00130   y=0.0;
00131   for (i=0;i<na-1;i+=3) {
00132     arg=(x-a[i+1])/a[i+2];
00133     ex=exp(-arg*arg);
00134     fac=a[i]*ex*2.0*arg;
00135     y += a[i]*ex;
00136     dyda[i]=ex;
00137     dyda[i+1]=fac/a[i+2];
00138     dyda[i+2]=fac*arg/a[i+2];
00139   }
00140 }

void fit Vec_I_DP x,
Vec_I_DP y,
Vec_I_DP sig,
const bool  mwt,
DP a,
DP b,
DP siga,
DP sigb,
DP chi2,
DP q
 

Referenced by AlgFitTrackSA::DoFit().

void fitexy Vec_I_DP x,
Vec_I_DP y,
Vec_I_DP sigx,
Vec_I_DP sigy,
DP a,
DP b,
DP siga,
DP sigb,
DP chi2,
DP q
 

void fixrts Vec_IO_DP d  ) 
 

void fleg const DP  x,
Vec_O_DP pl
 

void flmoon const int  n,
const int  nph,
int &  jd,
DP frac
 

DP fmin Vec_I_DP x  ) 
 

Referenced by EnergyCorrections::MasakiFarDec15th(), EnergyCorrections::MasakiFarDec15thScaled(), EnergyCorrections::MasakiNearDec15th(), and EnergyCorrections::MasakiNearDec15thScaled().

void four1 Vec_IO_DP data,
const int  isign
 

void fourew Vec_FSTREAM_p file,
int &  na,
int &  nb,
int &  nc,
int &  nd
 

void fourfs Vec_FSTREAM_p file,
Vec_I_INT nn,
const int  isign
 

void fourn Vec_IO_DP data,
Vec_I_INT nn,
const int  isign
 

void fpoly const DP  x,
Vec_O_DP p
 

void fred2 const DP  a,
const DP  b,
Vec_O_DP t,
Vec_O_DP f,
Vec_O_DP w,
DP   g(const DP),
DP   ak(const DP, const DP)
 

DP fredin const DP  x,
const DP  a,
const DP  b,
Vec_I_DP t,
Vec_I_DP f,
Vec_I_DP w,
DP   g(const DP),
DP   ak(const DP, const DP)
 

void frenel const DP  x,
complex< DP > &  cs
 

void frprmn Vec_IO_DP p,
const DP  ftol,
int &  iter,
DP fret,
DP   func(Vec_I_DP &),
void   dfunc(Vec_I_DP &, Vec_O_DP &)
 

void ftest Vec_I_DP data1,
Vec_I_DP data2,
DP f,
DP prob
 

DP gamdev const int  ia,
int &  idum
 

DP gammln const DP  xx  ) 
 

DP gammp const DP  a,
const DP  x
 

DP gammq const DP  a,
const DP  x
 

DP NR::gasdev int &  idum  ) 
 

Definition at line 143 of file nr.cxx.

References DP, and ran1().

00144 {
00145   static int iset=0;
00146   static DP gset;
00147   DP fac,rsq,v1,v2;
00148   
00149   if (idum < 0) iset=0;
00150   if (iset == 0) {
00151     do {
00152       v1=2.0*ran1(idum)-1.0;
00153       v2=2.0*ran1(idum)-1.0;
00154       rsq=v1*v1+v2*v2;
00155     } while (rsq >= 1.0 || rsq == 0.0);
00156     fac=sqrt(-2.0*log(rsq)/rsq);
00157     gset=v1*fac;
00158     iset=1;
00159     return v2*fac;
00160   } else {
00161     iset=0;
00162     return gset;
00163   }
00164 }

void gaucof Vec_IO_DP a,
Vec_IO_DP b,
const DP  amu0,
Vec_O_DP x,
Vec_O_DP w
 

void gauher Vec_O_DP x,
Vec_O_DP w
 

void gaujac Vec_O_DP x,
Vec_O_DP w,
const DP  alf,
const DP  bet
 

void gaulag Vec_O_DP x,
Vec_O_DP w,
const DP  alf
 

void gauleg const DP  x1,
const DP  x2,
Vec_O_DP x,
Vec_O_DP w
 

void NR::gaussj Mat_IO_DP a,
Mat_IO_DP b
 

Definition at line 167 of file nr.cxx.

References DP, Mat_IO_DP, NRMat< T >::ncols(), nrerror(), NRMat< T >::nrows(), SWAP(), and Vec_INT.

Referenced by mrqmin(), and MinosMinimization::MrqMin().

00168 {
00169   int icol=0, irow=0;
00170   int i,j,k,l,ll;
00171   DP big,dum,pivinv;
00172   
00173   int n=a.nrows();
00174   int m=b.ncols();
00175   Vec_INT indxc(n),indxr(n),ipiv(n);
00176   for (j=0;j<n;j++) ipiv[j]=0;
00177   for (i=0;i<n;i++) {
00178     big=0.0;
00179     for (j=0;j<n;j++)
00180       if (ipiv[j] != 1)
00181         for (k=0;k<n;k++) {
00182           if (ipiv[k] == 0) {
00183             if (fabs(a[j][k]) >= big) {
00184               big=fabs(a[j][k]);
00185               irow=j;
00186               icol=k;
00187             }
00188           }
00189         }
00190     ++(ipiv[icol]);
00191     if (irow != icol) {
00192       for (l=0;l<n;l++) SWAP(a[irow][l],a[icol][l]);
00193       for (l=0;l<m;l++) SWAP(b[irow][l],b[icol][l]);
00194     }
00195     indxr[i]=irow;
00196     indxc[i]=icol;
00197     if (a[icol][icol] == 0.0) nrerror("gaussj: Singular Matrix");
00198     pivinv=1.0/a[icol][icol];
00199     a[icol][icol]=1.0;
00200     for (l=0;l<n;l++) a[icol][l] *= pivinv;
00201     for (l=0;l<m;l++) b[icol][l] *= pivinv;
00202     for (ll=0;ll<n;ll++)
00203       if (ll != icol) {
00204         dum=a[ll][icol];
00205         a[ll][icol]=0.0;
00206         for (l=0;l<n;l++) a[ll][l] -= a[icol][l]*dum;
00207         for (l=0;l<m;l++) b[ll][l] -= b[icol][l]*dum;
00208       }
00209   }
00210   for (l=n-1;l>=0;l--) {
00211     if (indxr[l] != indxc[l])
00212       for (k=0;k<n;k++)
00213         SWAP(a[k][indxr[l]],a[k][indxc[l]]);
00214   }
00215 }

void gcf DP gammcf,
const DP  a,
const DP  x,
DP gln
 

DP golden const DP  ax,
const DP  bx,
const DP  cx,
DP   f(const DP),
const DP  tol,
DP xmin
 

void gser DP gamser,
const DP  a,
const DP  x,
DP gln
 

void hpsel Vec_I_DP arr,
Vec_O_DP heap
 

void hpsort Vec_IO_DP ra  ) 
 

void hqr Mat_IO_DP a,
Vec_O_CPLX_DP wri
 

void hufapp Vec_IO_ULNG index,
Vec_I_ULNG nprob,
const unsigned long  n,
const unsigned long  m
 

void hufdec unsigned long &  ich,
string &  code,
const unsigned long  lcode,
unsigned long &  nb,
huffcode hcode
 

void hufenc const unsigned long  ich,
string &  code,
unsigned long &  nb,
huffcode hcode
 

void hufmak Vec_I_ULNG nfreq,
const unsigned long  nchin,
unsigned long &  ilong,
unsigned long &  nlong,
huffcode hcode
 

void hunt Vec_I_DP xx,
const DP  x,
int &  jlo
 

void hypdrv const DP  s,
Vec_I_DP yy,
Vec_O_DP dyyds
 

complex<DP> hypgeo const complex< DP > &  a,
const complex< DP > &  b,
const complex< DP > &  c,
const complex< DP > &  z
 

void hypser const complex< DP > &  a,
const complex< DP > &  b,
const complex< DP > &  c,
const complex< DP > &  z,
complex< DP > &  series,
complex< DP > &  deriv
 

unsigned short icrc const unsigned short  crc,
const string &  bufptr,
const short  jinit,
const int  jrev
 

unsigned short icrc1 const unsigned short  crc,
const unsigned char  onech
 

unsigned long igray const unsigned long  n,
const int  is
 

void indexx Vec_I_INT arr,
Vec_O_INT indx
 

void indexx Vec_I_DP arr,
Vec_O_INT indx
 

void interp Mat_O_DP uf,
Mat_I_DP uc
 

int irbit1 unsigned long &  iseed  ) 
 

int irbit2 unsigned long &  iseed  ) 
 

void jacobi Mat_IO_DP a,
Vec_O_DP d,
Mat_O_DP v,
int &  nrot
 

void jacobn_s const DP  x,
Vec_I_DP y,
Vec_O_DP dfdx,
Mat_O_DP dfdy
 

int julday const int  mm,
const int  id,
const int  iyyy
 

void kendl1 Vec_I_DP data1,
Vec_I_DP data2,
DP tau,
DP z,
DP prob
 

void kendl2 Mat_I_DP tab,
DP tau,
DP z,
DP prob
 

void kermom Vec_O_DP w,
const DP  y
 

void ks2d1s Vec_I_DP x1,
Vec_I_DP y1,
void   quadvl(const DP, const DP, DP &, DP &, DP &, DP &),
DP d1,
DP prob
 

void ks2d2s Vec_I_DP x1,
Vec_I_DP y1,
Vec_I_DP x2,
Vec_I_DP y2,
DP d,
DP prob
 

void ksone Vec_IO_DP data,
DP   func(const DP),
DP d,
DP prob
 

void kstwo Vec_IO_DP data1,
Vec_IO_DP data2,
DP d,
DP prob
 

void laguer Vec_I_CPLX_DP a,
complex< DP > &  x,
int &  its
 

void lfit Vec_I_DP x,
Vec_I_DP y,
Vec_I_DP sig,
Vec_IO_DP a,
Vec_I_BOOL ia,
Mat_O_DP covar,
DP chisq,
void   funcs(const DP, Vec_O_DP &)
 

void linbcg Vec_I_DP b,
Vec_IO_DP x,
const int  itol,
const DP  tol,
const int  itmax,
int &  iter,
DP err
 

void NR::linmin Vec_IO_DP p,
Vec_IO_DP xi,
DP fret,
DP   func(Vec_I_DP &)
 

Definition at line 218 of file nr.cxx.

References brent(), DP, f1dim(), mnbrak(), ncom, nrfunc, pcom_p, NRVec< T >::size(), Vec_DP, Vec_I_DP, Vec_IO_DP, and xicom_p.

Referenced by powell().

00219 {
00220   int j;
00221   const DP TOL=1.0e-8;
00222   DP xx,xmin,fx,fb,fa,bx,ax;
00223   
00224   int n=p.size();
00225   ncom=n;
00226   pcom_p=new Vec_DP(n);
00227   xicom_p=new Vec_DP(n);
00228   nrfunc=func;
00229   Vec_DP &pcom=*pcom_p,&xicom=*xicom_p;
00230   for (j=0;j<n;j++) {
00231     pcom[j]=p[j];
00232     xicom[j]=xi[j];
00233   }
00234   ax=0.0;
00235   xx=1.0;
00236   mnbrak(ax,xx,bx,fa,fx,fb,f1dim);
00237   fret=brent(ax,xx,bx,f1dim,TOL,xmin);
00238   for (j=0;j<n;j++) {
00239     xi[j] *= xmin;
00240     p[j] += xi[j];
00241   }
00242   delete xicom_p;
00243   delete pcom_p;
00244 }

void lnsrch Vec_I_DP xold,
const DP  fold,
Vec_I_DP g,
Vec_IO_DP p,
Vec_O_DP x,
DP f,
const DP  stpmax,
bool &  check,
DP   func(Vec_I_DP &)
 

void locate Vec_I_DP xx,
const DP  x,
int &  j
 

Referenced by IoInputModule::AddFile().

void lop Mat_O_DP out,
Mat_I_DP u
 

void lubksb Mat_I_DP a,
Vec_I_INT indx,
Vec_IO_DP b
 

void ludcmp Mat_IO_DP a,
Vec_O_INT indx,
DP d
 

void machar int &  ibeta,
int &  it,
int &  irnd,
int &  ngrd,
int &  machep,
int &  negep,
int &  iexp,
int &  minexp,
int &  maxexp,
DP eps,
DP epsneg,
DP xmin,
DP xmax
 

void matadd Mat_I_DP a,
Mat_I_DP b,
Mat_O_DP c
 

void matsub Mat_I_DP a,
Mat_I_DP b,
Mat_O_DP c
 

void medfit Vec_I_DP x,
Vec_I_DP y,
DP a,
DP b,
DP abdev
 

void memcof Vec_I_DP data,
DP xms,
Vec_O_DP d
 

bool metrop const DP  de,
const DP  t
 

void mgfas Mat_IO_DP u,
const int  maxcyc
 

void mglin Mat_IO_DP u,
const int  ncycle
 

DP midexp DP   funk(const DP),
const DP  aa,
const DP  bb,
const int  n
 

DP midinf DP   funk(const DP),
const DP  aa,
const DP  bb,
const int  n
 

DP midpnt DP   func(const DP),
const DP  a,
const DP  b,
const int  n
 

DP midsql DP   funk(const DP),
const DP  aa,
const DP  bb,
const int  n
 

DP midsqu DP   funk(const DP),
const DP  aa,
const DP  bb,
const int  n
 

void miser DP   func(Vec_I_DP &),
Vec_I_DP regn,
const int  npts,
const DP  dith,
DP ave,
DP var
 

void mmid Vec_I_DP y,
Vec_I_DP dydx,
const DP  xs,
const DP  htot,
const int  nstep,
Vec_O_DP yout,
void   derivs(const DP, Vec_I_DP &, Vec_O_DP &)
 

void NR::mnbrak DP ax,
DP bx,
DP cx,
DP fa,
DP fb,
DP fc,
DP   func(const DP)
 

Definition at line 247 of file nr.cxx.

References DP, MAX(), shft3(), SIGN(), and SWAP().

Referenced by linmin().

00249 {
00250   const DP GOLD=1.618034,GLIMIT=100.0,TINY=1.0e-20;
00251   DP ulim,u,r,q,fu;
00252   
00253   fa=func(ax);
00254   fb=func(bx);
00255   if (fb > fa) {
00256     SWAP(ax,bx);
00257     SWAP(fb,fa);
00258   }
00259   cx=bx+GOLD*(bx-ax);
00260   fc=func(cx);
00261   while (fb > fc) {
00262     r=(bx-ax)*(fb-fc);
00263     q=(bx-cx)*(fb-fa);
00264     u=bx-((bx-cx)*q-(bx-ax)*r)/
00265       (2.0*SIGN(MAX(fabs(q-r),TINY),q-r));
00266     ulim=bx+GLIMIT*(cx-bx);
00267     if ((bx-u)*(u-cx) > 0.0) {
00268       fu=func(u);
00269       if (fu < fc) {
00270         ax=bx;
00271         bx=u;
00272         fa=fb;
00273         fb=fu;
00274         return;
00275       } else if (fu > fb) {
00276         cx=u;
00277         fc=fu;
00278         return;
00279       }
00280       u=cx+GOLD*(cx-bx);
00281       fu=func(u);
00282     } else if ((cx-u)*(u-ulim) > 0.0) {
00283       fu=func(u);
00284       if (fu < fc) {
00285         shft3(bx,cx,u,cx+GOLD*(cx-bx));
00286         shft3(fb,fc,fu,func(u));
00287       }
00288     } else if ((u-ulim)*(ulim-cx) >= 0.0) {
00289       u=ulim;
00290       fu=func(u);
00291     } else {
00292       u=cx+GOLD*(cx-bx);
00293       fu=func(u);
00294     }
00295     shft3(ax,bx,cx,u);
00296     shft3(fa,fb,fc,fu);
00297   }
00298 }

void mnewt const int  ntrial,
Vec_IO_DP x,
const DP  tolx,
const DP  tolf
 

void moment Vec_I_DP data,
DP ave,
DP adev,
DP sdev,
DP var,
DP skew,
DP curt
 

void mp2dfr Vec_IO_UCHR a,
string &  s
 

void mpadd Vec_O_UCHR w,
Vec_I_UCHR u,
Vec_I_UCHR v
 

void mpdiv Vec_O_UCHR q,
Vec_O_UCHR r,
Vec_I_UCHR u,
Vec_I_UCHR v
 

void mpinv Vec_O_UCHR u,
Vec_I_UCHR v
 

void mplsh Vec_IO_UCHR u  ) 
 

void mpmov Vec_O_UCHR u,
Vec_I_UCHR v
 

void mpmul Vec_O_UCHR w,
Vec_I_UCHR u,
Vec_I_UCHR v
 

void mpneg Vec_IO_UCHR u  ) 
 

void mppi const int  np  ) 
 

void mprove Mat_I_DP a,
Mat_I_DP alud,
Vec_I_INT indx,
Vec_I_DP b,
Vec_IO_DP x
 

void mpsad Vec_O_UCHR w,
Vec_I_UCHR u,
const int  iv
 

void mpsdv Vec_O_UCHR w,
Vec_I_UCHR u,
const int  iv,
int &  ir
 

void mpsmu Vec_O_UCHR w,
Vec_I_UCHR u,
const int  iv
 

void mpsqrt Vec_O_UCHR w,
Vec_O_UCHR u,
Vec_I_UCHR v
 

void mpsub int &  is,
Vec_O_UCHR w,
Vec_I_UCHR u,
Vec_I_UCHR v
 

void NR::mrqcof Vec_I_DP x,
Vec_I_DP y,
Vec_I_DP sig,
Vec_I_DP a,
Vec_I_BOOL ia,
Mat_O_DP alpha,
Vec_O_DP beta,
DP chisq,
void   funcs(const DP, Vec_I_DP &, DP &, Vec_O_DP &)
 

Definition at line 301 of file nr.cxx.

References beta(), DP, Mat_O_DP, NRVec< T >::size(), Vec_DP, Vec_I_BOOL, Vec_I_DP, and Vec_O_DP.

Referenced by mrqmin().

00304 {
00305   int i,j,k,l,m,mfit=0;
00306   DP ymod,wt,sig2i,dy;
00307   
00308   int ndata=x.size();
00309   int ma=a.size();
00310   Vec_DP dyda(ma);
00311   for (j=0;j<ma;j++)
00312     if (ia[j]) mfit++;
00313   for (j=0;j<mfit;j++) {
00314     for (k=0;k<=j;k++) alpha[j][k]=0.0;
00315     beta[j]=0.0;
00316   }
00317   chisq=0.0;
00318   for (i=0;i<ndata;i++) {
00319     funcs(x[i],a,ymod,dyda);
00320     sig2i=1.0/(sig[i]*sig[i]);
00321     dy=y[i]-ymod;
00322     for (j=0,l=0;l<ma;l++) {
00323       if (ia[l]) {
00324         wt=dyda[l]*sig2i;
00325         for (k=0,m=0;m<l+1;m++)
00326           if (ia[m]) alpha[j][k++] += wt*dyda[m];
00327         beta[j++] += dy*wt;
00328       }
00329     }
00330     chisq += dy*dy*sig2i;
00331     //     cout << x[i] << " " << y[i] << " " << ymod << " " << dy 
00332     //   << " " << chisq << endl;
00333   }
00334   for (j=1;j<mfit;j++)
00335     for (k=0;k<j;k++) alpha[k][j]=alpha[j][k];
00336 }

void NR::mrqmin Vec_I_DP x,
Vec_I_DP y,
Vec_I_DP sig,
Vec_IO_DP a,
Vec_I_BOOL ia,
Mat_O_DP covar,
Mat_O_DP alpha,
DP chisq,
void   funcs(const DP, Vec_I_DP &, DP &, Vec_O_DP &),
DP alamda
 

Definition at line 339 of file nr.cxx.

References beta(), covsrt(), DP, gaussj(), Mat_DP, Mat_O_DP, mrqcof(), NRVec< T >::size(), Vec_DP, Vec_I_BOOL, Vec_I_DP, Vec_IO_DP, and Vec_O_DP.

00342 {
00343   static int mfit;
00344   static DP ochisq;
00345   int j,k,l;
00346   
00347   int ma=a.size();
00348   static Mat_DP oneda(ma,1);
00349   static Vec_DP atry(ma),beta(ma),da(ma);
00350   if (alamda < 0.0) {
00351     mfit=0;
00352     for (j=0;j<ma;j++)
00353       if (ia[j]) mfit++;
00354     alamda=0.001;
00355     mrqcof(x,y,sig,a,ia,alpha,beta,chisq,funcs);
00356     ochisq=chisq;
00357     for (j=0;j<ma;j++) atry[j]=a[j];
00358   }
00359   Mat_DP temp(mfit,mfit);
00360   for (j=0;j<mfit;j++) {
00361     for (k=0;k<mfit;k++) covar[j][k]=alpha[j][k];
00362     covar[j][j]=alpha[j][j]*(1.0+alamda);
00363     for (k=0;k<mfit;k++) temp[j][k]=covar[j][k];
00364     oneda[j][0]=beta[j];
00365   }
00366   gaussj(temp,oneda);
00367   for (j=0;j<mfit;j++) {
00368     for (k=0;k<mfit;k++) covar[j][k]=temp[j][k];
00369     da[j]=oneda[j][0];
00370   }
00371   if (alamda == 0.0) {
00372     covsrt(covar,ia,mfit);
00373     covsrt(alpha,ia,mfit);
00374     return;
00375   }
00376   for (j=0,l=0;l<ma;l++){
00377     if (ia[l]) atry[l]=a[l]+da[j++];
00378     //     cout << a[l] << " " << da[j-1] << " " << atry[l] << endl;
00379   }
00380   mrqcof(x,y,sig,atry,ia,covar,da,chisq,funcs);
00381   if (chisq < ochisq) {
00382     alamda *= 0.1;
00383     ochisq=chisq;
00384     for (j=0;j<mfit;j++) {
00385       for (k=0;k<mfit;k++) alpha[j][k]=covar[j][k];
00386       beta[j]=da[j];
00387     }
00388     for (l=0;l<ma;l++) a[l]=atry[l];
00389   } else {
00390     alamda *= 10.0;
00391     chisq=ochisq;
00392   }
00393 }

void newt Vec_IO_DP x,
bool &  check,
void   vecfunc(Vec_I_DP &, Vec_O_DP &)
 

void NR::nrerror const string  error_text  )  [inline]
 

Definition at line 50 of file nrutil_mtl.h.

Referenced by brent(), and gaussj().

00052         {
00053                 cerr << "Numerical Recipes run-time error..." << endl;
00054                 cerr << error_text << endl;
00055                 cerr << "...now exiting to system..." << endl;
00056                 exit(1);
00057         }

void odeint Vec_IO_DP ystart,
const DP  x1,
const DP  x2,
const DP  eps,
const DP  h1,
const DP  hmin,
int &  nok,
int &  nbad,
void   derivs(const DP, Vec_I_DP &, Vec_O_DP &),
void   rkqs(Vec_IO_DP &, Vec_IO_DP &, DP &, const DP, const DP, Vec_I_DP &, DP &, DP &, void(*)(const DP, Vec_I_DP &, Vec_O_DP &))
 

void orthog Vec_I_DP anu,
Vec_I_DP alpha,
Vec_I_DP beta,
Vec_O_DP a,
Vec_O_DP b
 

void pade Vec_IO_DP cof,
DP resid
 

void pccheb Vec_I_DP d,
Vec_O_DP c
 

void pcshft const DP  a,
const DP  b,
Vec_IO_DP d
 

void pearsn Vec_I_DP x,
Vec_I_DP y,
DP r,
DP prob,
DP z
 

void period Vec_I_DP x,
Vec_I_DP y,
const DP  ofac,
const DP  hifac,
Vec_O_DP px,
Vec_O_DP py,
int &  nout,
int &  jmax,
DP prob
 

void piksr2 Vec_IO_DP arr,
Vec_IO_DP brr
 

void piksrt Vec_IO_DP arr  ) 
 

void pinvs const int  ie1,
const int  ie2,
const int  je1,
const int  jsf,
const int  jc1,
const int  k,
Mat3D_O_DP c,
Mat_IO_DP s
 

DP plgndr const int  l,
const int  m,
const DP  x
 

DP poidev const DP  xm,
int &  idum
 

void polcoe Vec_I_DP x,
Vec_I_DP y,
Vec_O_DP cof
 

void polcof Vec_I_DP xa,
Vec_I_DP ya,
Vec_O_DP cof
 

void poldiv Vec_I_DP u,
Vec_I_DP v,
Vec_O_DP q,
Vec_O_DP r
 

void polin2 Vec_I_DP x1a,
Vec_I_DP x2a,
Mat_I_DP ya,
const DP  x1,
const DP  x2,
DP y,
DP dy
 

void polint Vec_I_DP xa,