This is the mail archive of the
gsl-discuss@sources.redhat.com
mailing list for the GSL project.
Re: predefined TINY ?
- From: Brian Gough <bjg at network-theory dot co dot uk>
- To: "Dan, Ho-Jin" <hjdan at sys713 dot kaist dot ac dot kr>
- Cc: gsl-discuss at sources dot redhat dot com
- Date: Tue, 8 Jan 2002 10:16:34 +0000 (GMT)
- Subject: Re: predefined TINY ?
- References: <3C39F274.1080405@sys713.kaist.ac.kr>
Dan, Ho-Jin writes:
> Is there a predefined TINY number in gsl?
> In my code, TINY is used for checking small number
> for example, in order to prevent divide by zero (ad hoc TINY=1.e-15)
> do I just use the mechanism GSL_POSINF et cetera?
>
> if (fabs(a-b) < TINY) {
> ...
Hi,
The header file gsl_machine.h should have all the constants you need,
or just use the standard C constants like DBL_EPSILON.
Brian