home *** CD-ROM | disk | FTP | other *** search
- /* General form test program for scientific functions */
-
- /* Routine Tested: SIMPS */
-
- main()
-
- {
- int *fp,m;
- static float y[4]={1.386294,1.458614,1.526056,1.589235};
- float xo,xn,simp;
-
- m = 4;
- xo = 4.;
- xn = 5.2;
-
- simps(m,xo,xn,y,&simp);
-
- *fp=fopen("PRN:","w"); /* open the printer */
-
- fprintf(*fp,"Test Results from SIMPS\n\n");
- printf("Test Results from SIMPS\n\n");
-
- fprintf(*fp," SIMP = %15.7f\n\n",simp);
- printf(" SIMP = %15.7f\n\n",simp);
-
- }
-