Skip to content

AFNI/NIfTI Server

Sections
Personal tools
You are here: Home » AFNI » Documentation

Doxygen Source Code Documentation


Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals   Search  

cdf_44.c

Go to the documentation of this file.
00001 #include "cdflib.h"
00002 double dln1mx(double *x)
00003 /*
00004 **********************************************************************
00005  
00006      double dln1mx(double *x)
00007                Double precision LN(1-X)
00008  
00009  
00010                               Function
00011  
00012  
00013      Returns ln(1-x) for small x (good accuracy if x .le. 0.1).
00014      Note that the obvious code of
00015                LOG(1.0-X)
00016      won't work for small X because 1.0-X loses accuracy
00017  
00018  
00019                               Arguments
00020  
00021  
00022      X --> Value for which ln(1-x) is desired.
00023                                         X is DOUBLE PRECISION
00024  
00025  
00026                               Method
00027  
00028  
00029      If X > 0.1, the obvious code above is used ELSE
00030      The Taylor series for 1-x is expanded to 20 terms.
00031  
00032 **********************************************************************
00033 */
00034 {
00035 static double dln1mx,T1;
00036 /*
00037      ..
00038      .. Executable Statements ..
00039 */
00040     T1 = -*x;
00041     dln1mx = dln1px(&T1);
00042     return dln1mx;
00043 } /* END */
 

Powered by Plone

This site conforms to the following standards: