yorick banner

Home

Manual

Packages

Global Index

Keywords

Quick Reference

functions in yeti_fit_2d_spike.i - f

 
 
 
fit_2d_spike


              
 
     Parameters:  
       A(1) = peak intensity of spike  
       A(2) = FWHM of spike  
       A(3) = abscissa of spike  
       A(4) = ordinate of spike  
       A(5) = background level  
       A(6) = background X-slope  
       A(7) = background Y-slope  
     Model:  
       MODEL(X,Y) = A1*P((X-A3)/A2)*P((Y-A4)/A2) + A5 + A6*(X-A3) + A7*(Y-A4)  
     where P(U) is the shape function.  
     SHAPE is the 1-D shape of the spike, it can be "spline" to use a  
     cubic B-spline function, "gauss" to use a gaussian or any user  
     defined routine which has the following prototype:  
       func SHAPE(&p, &dp, u) {gg_fit_2d_spike(data)  
         p = f(u);  
         dp = f'(u);  
       }  
    
     where f(u) is a "bell-shaped" function and f'(u) is  
     its derivative; f(u) should have  
     with the following properties:  
       f(0) = 1  
       f(0.5) = 0.5  
       f(-u) = f(u)                              (i.e. f is symmetric)  
       f(u) >= 0     everywhere  
       f'(u)>0 for u<0, f'(0)=0, f'(u)<0 for u>0 (i.e. f is "bell-shaped")  
     the 3 first properties are needed to properly define the FWHM (Full  
     Half Width at Half Maximum).  
         
     Background:  
       BG = nil/0  no background (BG = 0 everywhere)  
       BG = 1      uniform background  
       BG = 2      BG(x,y) = a() + a()*(x-x0) + a()*(y-y0)  
     Spike:  
     Support: */  
interpreted function, defined at contrib/yeti_fit_2d_spike.i   line 385