NAME

ghost_filter - filter selected rays based on ghost ray properties.


PARAMETERS

ghost_filter acts as a tap. The unfiltered raystream is passed through from input to output. The filtered stream (based on the settings of pass_p_ghosts, pass_h_ghosts, pass_nr_ghosts, and pass_goodrays) is written to filtered.

ghost_filter uses an IRAF-compatible parameter interface. A template parameter file is in /proj/axaf/simul/lib/uparm/ghost_filter.par. It acts as a filter which selectively removes rays from the stream. The ray ``id'' for passed rays is optionally written to a file.

In the following it is assumed that we have two X-ray optical surfaces, a paraboloid and a hyperboloid, in a Wolter Type I configuration. A ray is considered to be a P-ghost if it is reflected by a paraboloid but misses the hyperboloid. A ray is considered to be an H-ghost if it missed the paraboloid and reflected from the hyperboloid. Rays which miss both surfaces are termed nonreflected rays, or NR-ghosts. Finally, double-reflected rays (reflected once by each optic) are called good rays.

input

The input bpipe ray stream to process. If it is the string stdin, it reads from the UNIX standard input stream.

output

the destination for the output rays. if it is the string stdout, it writes to the UNIX standard output stream. It writes bpipe formatted rays

filtered

the destination for the filtered stream. if it is the string stdout, it writes to the UNIX standard output stream. It writes bpipe formatted rays.

id_file

the name of the ray id file to be used. This variable is queried only if print_id is true.

print_id

a boolean variable which, if true, indicates the ray id of passed rays should be written to a ray id file.

print_ascii

a boolean variable which, if true, indicates the ray id is written as an ascii character string. If print_ascii is false, the ray id is written as a binary int. This variable is queried only if print_id is true.

pass_p_ghosts

a boolean variable which, if true, indicates that ghost_filter should allow P-ghost rays to pass unaltered; otherwise, P-ghost rays are blocked and not passed to the output stream.

pass_h_ghosts

a boolean variable which, if true, indicates that ghost_filter should allow H-ghost rays to pass unaltered; otherwise, H-ghost rays are blocked and not passed to the output stream.

pass_nr_ghosts

a boolean variable which, if true, indicates that ghost_filter should allow NR-ghost rays (i.e., nonreflected rays) to pass unaltered; otherwise, NR-ghost rays are blocked and not passed to the output stream.

pass_goodrays

a boolean variable which, if true, indicates that ghost_filter should allow good rays (i.e., proper double-reflected rays) to pass unaltered; otherwise, good rays are blocked and not passed to the output stream.

help

If true, print out usage instructions and exit.

version

Print the version and exit.

debug

A list of debug flags. The presently supported flags are:

summary

print out a summary using tf_message


DESCRIPTION

ghost_filter acts as a tap. The unfiltered raystream is passed through from input to output. The filtered stream is written to filtered.

ghost_filter tests the BP_AXAF_surf_missed field of the bpipe stream.


BUGS

Presently the code assumes that there are only two optics, a P and an H. It doesn't test that this precondition is satisfied, though.


AUTHOR

Terry Gaetz ( tgaetz@cfa.harvard.edu )