[AIT logo]

Institut für Astronomie und Astrophysik

Abteilung Astronomie

Sand 1, D-72076 Tübingen, Germany
[Uni logo]


gaussfold Source code in gaussfold.pro

gaussfold

Name
           gaussfold
Purpose
           Smoothes a plot by convolving with a Gaussian profile.
           Main purpose is to convolve a spectrum (flux against
           wavelength) with a given instrument resolution.
           Also applicable e.g. to smooth ligthcurves or in
           time-series analysis.
Category

Calling Sequence
           smoothedFlux = gaussfold(lambda, flux, sigma,
                                    LAMMIN=lammin, LAMMAX=lammax)
Input Parameters
           lambda = In ascending order sorted array (double or float)
                    containing the values of the x-axis (e.g. the
                    wavelength- or frequencygrid). Irregularly spaced
                    grids are acepted.
           flux   = Array (double or float) same size as lambda
                    containing the values of the y-axis (e.g. the
                    flux).
           fwhm   = FWHM in units of the x-axis (e.g. Angstroem) of
                    the Gaussian profile.
Optional Input Parameters
           NONE
Keyword Parameters
           lammin &
           lammax   = Defines the x-axis range. All y-data within
                      this range will be smoothed.
                      CAUTION: improtant in case of large arrays (memory!)
                      DEFAULTS: lammin = MIN(lambda) i.e. lambda[0]
                                lammax = MAX(lambda) i.e. lambda[N_ELEMENTS(lambda)-1]
Output Parameters
           smoothedFlux = Array (double of float) same size as lambda
                          containing the smoothed flux.
Optional Output
           NONE
Common Blocks
           NONE
Side Effects
           NONE
Restrictions
           NONE
Procedure
           1. Interpolation of the flux on a fine spaced grid.
              Oversamplingfaktor: 17
           2. Convolution of the flux with a gaussian profile
           3. Interpolation of the smoothed flux on the original grid.
Example
           fluxS = GAUSSFOLD( lambda, flux, 0.5)
Revision History
           Version 1.0  by Katja Pottschmidt  1999
           Version 2.0  by Jochen Deetjen     1999
                        - Documentation added
                        - Keyword defaults defined
                        - convolution with the gaussian kernel is
                          restricted within a window
                          -> by far less time consuming

Last modified by pro2html on 2005 January 04 at 16:38 UTC

[Home Page] [Software, Documentation] [IDL Documentation] [Quick Reference] [Feedback]

Jörn Wilms (wilms@astro.uni-tuebingen.de)
Updated automatically