Doxygen Source Code Documentation
cdf_52.c
Go to the documentation of this file.00001 #include "cdflib.h" 00002 void dstzr(double *zxlo,double *zxhi,double *zabstl,double *zreltl) 00003 /* 00004 ********************************************************************** 00005 void dstzr(double *zxlo,double *zxhi,double *zabstl,double *zreltl) 00006 Double precision SeT ZeRo finder - Reverse communication version 00007 Function 00008 Sets quantities needed by ZROR. The function of ZROR 00009 and the quantities set is given here. 00010 Concise Description - Given a function F 00011 find XLO such that F(XLO) = 0. 00012 More Precise Description - 00013 Input condition. F is a double precision function of a single 00014 double precision argument and XLO and XHI are such that 00015 F(XLO)*F(XHI) .LE. 0.0 00016 If the input condition is met, QRZERO returns .TRUE. 00017 and output values of XLO and XHI satisfy the following 00018 F(XLO)*F(XHI) .LE. 0. 00019 ABS(F(XLO) .LE. ABS(F(XHI) 00020 ABS(XLO-XHI) .LE. TOL(X) 00021 where 00022 TOL(X) = MAX(ABSTOL,RELTOL*ABS(X)) 00023 If this algorithm does not find XLO and XHI satisfying 00024 these conditions then QRZERO returns .FALSE. This 00025 implies that the input condition was not met. 00026 Arguments 00027 XLO --> The left endpoint of the interval to be 00028 searched for a solution. 00029 XLO is DOUBLE PRECISION 00030 XHI --> The right endpoint of the interval to be 00031 for a solution. 00032 XHI is DOUBLE PRECISION 00033 ABSTOL, RELTOL --> Two numbers that determine the accuracy 00034 of the solution. See function for a 00035 precise definition. 00036 ABSTOL is DOUBLE PRECISION 00037 RELTOL is DOUBLE PRECISION 00038 Method 00039 Algorithm R of the paper 'Two Efficient Algorithms with 00040 Guaranteed Convergence for Finding a Zero of a Function' 00041 by J. C. P. Bus and T. J. Dekker in ACM Transactions on 00042 Mathematical Software, Volume 1, no. 4 page 330 00043 (Dec. '75) is employed to find the zero of F(X)-Y. 00044 ********************************************************************** 00045 */ 00046 { 00047 E0001(1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,zabstl,zreltl,zxhi,zxlo); 00048 } /* END */