Undefined Values (BLANKs)

GIPSY applications programmers should be aware of the fact that the so called undefined value (or BLANK as it is called in FITS terminology) is a fixed value which can only be different across different computer operating systems. On some computers any arithmetic operation on such a BLANK might cause a crash of your program. So it is absolutely necessary to check whether a certain pixel value is a BLANK before doing any operation on it. This is done with the function FBLANK. This function returns .TRUE. if the argument is BLANK, otherwise it will return .FALSE.

The subroutine SETFBLANK can be used to set one value to BLANK; subroutine SETFNBLANK sets a whole array to BLANK.

For the sake of speed it is advisable to compare data values directly with the system defined BLANK instead of using the slower function FBLANK. This is done in the following way: declare a REAL in the task and set it to BLANK by calling SETFBLANK. Then this variable can be used to compare with.

Also certain arithmetic operations are illegal like taking the square root of a negative value or dividing by zero. The task should also check on this prior to the execution of the operation. If the operation is illegal, then the result should be set to BLANK.

Programming GIPSY