1
% @(#)computplan.hlq 19.1 (ESO-IPG) 02/25/03 14:03:03
2
%++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3
%.COPYRIGHT (c) 1990 European Southern Observatory
6
%.KEYWORDS MIDAS, help files, COMPUTE/PLANE
7
%.PURPOSE On-line help file for the command: COMPUTE/PLANE
8
%.VERSION 1.0 970701: Creation, KB
9
%----------------------------------------------------------------
13
COMPUTE/PLANE 01-JUL-1997 KB
15
COMPUTE/PLANE res_frame.plane = arithmetic_expression
16
do arithmetics on planes of images
19
Perform arithmetic operations on planes of 3-dim images and store
20
result in a plane of the result image.
23
COMPUTE/PLANE res_frame.plane = expression
25
res_frame.plane = image and plane to get result of expression,
26
the plane is specified by Pi (or pi), with i in [1,NPIX(3)];
28
expression = expression with up to 10 operands, which may be
29
functions and planes or/and constants in the usual algebraic
30
notation, planes of the res_frame are indicated by "Pi" (or "pi")
31
with i = plane_no. (beginning at 1);
33
planes of other frames are indicated via `frame.Pi'
36
Inside the expression may be spaces or not. However, if your
37
expression is longer than 100 chars. (the current max. token length)
38
without spaces, you should include spaces between some operands,
39
then the limit is 256 chars. for the complete command line.
41
The operations +, -, *, / and ** are supported with the same
42
precedence as in FORTRAN. Parentheses may be used to change that
43
order as well as to nest operations.
45
The functions SQRT(a), EXP(a), EXP10(a), LN(a), LOG10(a), SIN(a)
46
ASIN(a), COS(a), ACOS(a), TAN(a), ATAN(a), INT(a), ATAN2(a1,a2),
47
MAX(a1,a2), MIN(a1,a2), MOD(a1,a2) and ABS(a), are implemented as in
48
FORTRAN. Except that INT(a) will return the nearest integer of "a"
51
The trigonometric functions expect arguments in degrees!
53
Results of illegal operations (e.g. division by zero) are set to
54
the "null value" defined by the keyword NULL.
56
If planes from other frames are involved in the expression, they
57
must have the same no. of pixels per plane, i.e. NPIX(1),NPIX(2).
58
You can mix planes of 3-dim frames and 2-dim frames.
60
This command uses single precision (floating point) calculations,
61
if you need higher precision, use COMPUTE/DPIXEL instead.
64
COMPUTE/XYPLANE, COMPUTE/DPLANE, COMPUTE/ROW, COMPUTE/IMAGE
70
COMPUTE/PLANE tiburon.p2 = P1+P4
71
Use image frame `tiburon.bdf' and add the 1st plane and 4th plane,
72
store the result into the 2nd plane of frame `tiburon.bdf'.
74
COMPUTE/PLANE ballena.P7 = 99.9 * sin(delfin.p5)
75
Set the 7th plane of frame `ballena.bdf' to the product of 99.9
76
and the sine of the contents of plane no. 5 of frame `delfin.bdf'.
77
The no. of pixels per plane of `ballena.bdf' and `delfin.bdf' must
80
COMPUTE/PLANE ballena.p2 = (1.1+ima2) / p7
81
Compute 1.1+ima2, with 2-dim image `ima2.bdf', and divide the
82
result by the 7th plane of `ballena.bdf' and store that into
83
2nd plane of frame `ballena.bdf'.