Ignore:
Timestamp:
Mar 1, 2010 1:57:12 PM (12 years ago)
Author:
srkline
Message:

incorporating Jae-Hie's changes to the library functions to explicitly handle the cases at qr==0. Also a lot of changes to explicitly declare constant values as floating point, rather than chance the interpretation as integer. (probably not necessary)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sans/XOP_Dev/SANSAnalysis/lib/libTwoPhase.c

    r554 r632  
    417417         
    418418        uval = Mw_Mn - 1.0; 
    419         if(uval == 0) { 
     419        if(uval == 0.0) { 
    420420                uval = 1e-6;            //avoid divide by zero error 
    421421        } 
     
    453453        bgd = dp[4];  
    454454         
    455         inten = Ig0*exp(-1.0*x*x*gg*gg/2.0) + Il0/(1 + (x*ll)*(x*ll)) + bgd; 
     455        inten = Ig0*exp(-1.0*x*x*gg*gg/2.0) + Il0/(1.0 + (x*ll)*(x*ll)) + bgd; 
    456456         
    457457        return(inten); 
Note: See TracChangeset for help on using the changeset viewer.