STScI Logo

testfunc stsdas.sobsolete



testfunc -- Create test data for a specified function.


testfunc function


The testfunc task generates dependent-variable values for any number of pixels and writes them to the standard output device (STDOUT). The user selects the form for the data from a list of 18 commonly-known functions.

The mkfunc task can be used to place these functional data in a real data file (with the correct FITS coordinate parameters).


function [string]
[Allowed values: bessel | constant | delta | gaussian | heaviside | pe | po | box | rectangle | signum | comb | shah | sinc | sine | cosine | triangle | y | line]
Name of the function to be used. The following table shows the supported functions, which are described in Bracewell's book "The Fourier Transform and Its Applications."

Value             Function
=====             ========
bessel            Bessel function ('J0')
box               Bracewell's box function
comb              Dirac comb, Bracewell shah
constant          Constant
cosine            cosine
delta             Delta function
gaussian          Gaussian
heaviside         Heaviside unit step
line              Unit-slope line
pe                Even impulse pair
po                Odd impulse pair
rectangle         Bracewell's box function
shah              Dirac comb, Bracewell shah
signum            sign (x)
sinc              sin (pi x) / (pi x)
sine              sine
triangle          Bracewell's wedge function
y                 Unit-slope line
(constant = 1.0) [real]
Y-value for constant function.
(delta = 0.1) [real, min=1.0e-10]
X increment.
(npoints = 100) [integer, min=1]
Number of points.
(oshift = 0) [integer]
Origin shift.


1. Create a 100-point rectangle (i.e., a boxcar) function, centered at pixel 1.

fo> testfunc box
2. Create a 235-point triangle (i.e, a wedge) function, centered at pixel 41.

fo> testfunc tri npoint=235 oshift=40




Type "help fourier option=sys" for a higher-level description of the fourier package.

Source Code · Package Help · Search Form · STSDAS