TABLE OF CONTENTS


MLT_RSS/incidence_angle.f90 [ Programs ]

[ Top ] [ Programs ]

NAME

    module interpolate

PURPOSE

    module containing a number of interpolation routines

DESCRIPTION

    module containing a number of interpolation routines
    
   ROUTINES
     function interpolate_2D(x,y,mat,x_min,x_max,y_min,y_max,error,x_wrap,y_wrap)
        interpolates a 2-d array with possible wrapping in either dimension
     function lin_interpolate(x,x1,x2,y1,y2,error)
     function lin_interpolate_r4_r8(x,x1,x2,y1,y2,error)
     function lin_interpolate_r8_r4(x,x1,x2,y1,y2,error)
         these threee functions are identical, but use different input types
         perform linear interpolation of y values y1 and y2, located at x1 and x2 to x value x

INPUTS

           x   value to be interpolated to
           x1 x2  two x values on either side of x
           y1 y2  y values at x1 and x2

OUTPUTS

           error  error flag -- non zero indicates problems
         RETURN VALUE
           intepolated value y at x
     lin_interp_1D(x0,x,y,error)
         linearly interpolates a lies of x and y values to the point at xO

INPUTS

           x0   value to be interpolated to
           x   sorted list of  x values on either side of x
           y   y values at x

OUTPUTS

           error  error flag -- non zero indicates problems
         RETURN VALUE
           intepolated value y at x0

     subroutine locate(xx,x,j)
         locates the proper index near xx from a list of values x

INPUTS

           xx   list of x values
           x    x value to interpolate to
           j    index of xx just below x

     function exp_interpolate(x,x1,x2,y1,y2,error)
         performs exponential interpolation of y values y1 and y2, located at x1 and x2 to x value x

INPUTS

           x   value to be interpolated to
           x1 x2  two x values on either side of x
           y1 y2  y values at x1 and x2

OUTPUTS

           error  error flag -- non zero indicates problems
         RETURN VALUE
           intepolated value y at x
     function lin_interpolate_directions(x,x1,x2,dir1,dir2,error)
         perform linear interpolation of direction data of y values y1 and y2, located at x1 and x2 to x value x
         takes into account wrapping property of direction data by interpolating to "interior value"

INPUTS

           x   value to be interpolated to
           x1 x2  two x values on either side of x
           dir1 dir2  dir values at x1 and x2

OUTPUTS

           error  error flag -- non zero indicates problems
         RETURN VALUE
           intepolated value of direction at x

AUTHOR

    Carl Mears, Remote Sensing Systems

COPYRIGHT

    THIS SOFTWARE AND ITS DOCUMENTATION ARE CONSIDERED TO BE IN THE PUBLIC DOMAIN AND
    THUS ARE AVAILABLE FOR UNRESTRICTED PUBLIC USE.  THEY ARE FURNISHED "AS IS." THE 
    AUTHORS, THE UNITED STATES GOVERNMENT, ITS INSTRUMENTALITIES, OFFICERS, EMPLOYEES, 
    AND AGENTS MAKE NO WARRANTY, EXPRESS OR IMPLIED, AS TO THE USEFULNESS OF THE 
    SOFTWARE AND DOCUMENTATION FOR ANY PURPOSE. THEY ASSUME NO RESPONSIBILITY (1) FOR
    THE USE OF THE SOFTWARE AND DOCUMENTATION!  OR (2) TO PROVIDE TECHNICAL SUPPORT 
    TO USERS.

HISTORY

    2/21/2012 Initial Version prepared for NCDC

  COMMENTS

USAGE

    use interpolate