beginning to fold in HOD code with jeremy tinker's approval

This commit is contained in:
P.M. Sutter 2013-12-30 22:48:07 -06:00
parent d8108d3a8e
commit 44cd0eb71f
95 changed files with 21950 additions and 0 deletions

18
c_tools/hod/f1dim.c Normal file
View file

@ -0,0 +1,18 @@
#define NRANSI
#include "nrutil.h"
extern int ncom;
extern double *pcom,*xicom,(*nrfunc)(double []);
double f1dim(double x)
{
int j;
double f,*xt;
xt=dvector(1,ncom);
for (j=1;j<=ncom;j++) xt[j]=pcom[j]+x*xicom[j];
f=(*nrfunc)(xt);
free_dvector(xt,1,ncom);
return f;
}
#undef NRANSI