/* timbes.c CCMATH mathematics library source code. * * Copyright (C) 2000 Daniel A. Atkinson All rights reserved. * This code may be redistributed under the terms of the GNU library * public license (LGPL). ( See the lgpl.license file for details.) * ------------------------------------------------------------------------ */ /* Time execution of Bessel function evaluation. Input parameter: n -> evaluation on n by n grid (n^2 evaluations) */ #include #include #include "ccmath.h" void main(int na,char **av) { double x,v,f,dx,dv,*s,*p; int i,j,n; clock_t st,en; if(na!=2){ printf("para: loop_sz\n"); exit(1);} n=atoi(*++av); printf(" %d evaluations of Jbessel\n",n*n); st=clock(); dx=20./n; dv=10./n; for(i=0,x=0.,p=s; i