home *** CD-ROM | disk | FTP | other *** search
- /* General form test program for scientific functions */
-
- /* Routine Tested: PLYIRT */
-
- main()
-
- {
- int *fp,nd,ni;
- static float a[5]={1.,-3.,-2.,5.,1.};
- float e,root;
-
- nd = 4;
- e = .00002;
- ni = 1000;
- root = 1.;
- /* NOTE: There are actually 3 roots to this equation.
- Testing with root= 0. and root=3. will
- approximate the other two. */
-
-
- plyirt(a,nd,ni,e,&root);
-
-
- *fp=fopen("PRN:","w"); /* open the printer */
-
- fprintf(*fp,"Test Results from PLYIRT\n\n");
- printf("Test Results from PLYIRT\n\n");
-
- fprintf(*fp," NUMRT = %f\n\n",root);
- printf(" NUMRT = %f\n\n",root);
-
- }
-