Performs mathematical functions on two images.
Allows the user to perform the following mathematical operations with images of a specified size and data type:
ADD Adds two input images together to form a single output image. AND Performs a bitwise logical "and" of two images. DIV Divides one image by another with a scaling factor. MAX Generates an image consisting of the maximum of two images. MIN Generates an image consisting of the minimum of two images. MUL Multiplies two images together. OR Performs a bitwise "or" of two images. SUB Subtracts two images to form a third. XOR Performs a bitwise "exclusive or" on two images.
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
- SCALFACT(1,1)
- Scale factor for images. The scale factors to be applied to both input images, respectively.
- OFFSET(0.0)
- Offset to be applied. The additive offset applied to the image after the input images have been added.
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
- SCALFACT(1,1)
- Scale factor for images. The scale factors to be applied to both input images, respectively.
- OFFSET(0.0)
- Offset to be applied. The additive offset applied to the image after the input images have been subtracted.
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
- SCALFACT(1.0)
- Scale factor applied. The scale factor to be applied after the images are divided.
- OFFSET(0.0)
- Offset to be applied. The additive offset applied to the image after the input images have been divided.
- PIXVAL(1.0)
- Pixel value. The pixel value to be inserted into the output location whenever division by zero is encountered.
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
- SCALFACT(1.0)
- Scale factor applied. The scale factor to be applied after the images are multiplied.
- OFFSET(0.0)
- Offset to be applied. The additive offset applied to the image after the input images have been multiplied.
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
- IN
- Input images. Allowed data types are BYTE, INTEGER*2, INTEGER*4, and REAL*4. Window and/or band options may also be specified.
- OUT
- Output image. Created by performing the specified operation. The output data type is determined by the ODTYPE parameter.
- ODTYPE(SAME)
- Output data type. The data type of the output image.
= SAME: Same as input = BYTE: BYTE (8-bit unsigned integer) (0 through 255) = I*2: INTEGER*2 (16-bit signed integer) (-32768 through 32767) = I*4: INTEGER*4 (32-bit signed integer) (-2147483648 through 2147483647) = R*4: REAL*4 (32-bit signed real) (System dependent)
The pixel values in the window of the input image A are scaled by a factor of 5 and added to the pixel values in the window of the input image B, which are scaled by a factor of 4. The pixels of the resultant image are offset by a value of 10 to create the output image C. If A and B are multi-band images, the number of bands in C is equal to the minimum number of bands contained in either A or B. The size of the output image C is 30 x 30.
A logical "and" is performed on the pixel values in the two windowed input images to generate the output C. The number of image bands in C is equal to the fewest number of bands in A or B. The size of the output image C is 30 x 30. The output bit value equals 0 if either compare bit values equal 0; otherwise, the output bit value equals 1.
If IN1 value = 11011011 If IN1 value = 11011011 and IN2 value = 00100100 and IN2 value = 00110010 then OUT value = 00000000 then OUT value = 00010010
The pixel values in the window of the input image A are divided by the pixel values in the window of the input image B. This resultant image, C, is scaled by a factor of 5 and offset by a value of 10. If a pixel value of B is 0, a value of 0 will be inserted in C. The number of bands in C is equal to the fewest number of bands contained in A or B. The size of the output image C is 30 x 30.
A "maximum" is performed on the pixel values in the two windowed input images to generate output C. The number of image bands in C is equal to the fewest number of bands in A or B. The size of the output image C is 30 x 30.
A "minimum" is performed on the pixel values in the two windowed input images to generate output C. The number of image bands in C is equal to the fewest number of bands in A or B. The size of the output image C is 30 x 30.
The pixel values in the window of A are multiplied by the pixel values in the window of B, and the result is scaled by a factor of 5. This product is offset by a value of l0 to create the output image C. The number of bands in C is equal to the minimum number of bands contained in A or B. The size of the output image C is 30 x 30.
A logical "or" is performed on the input pixel values for the windowed input images to generate the output image C. The number of bands in C is equal to the minimum number of bands contained in A or B. The size of the output image C is 30 x 30. The output bit value equals 1 if either compare bit values equal 1; otherwise, the output bit value equals 0.
If IN1 value = 11011011 If IN1 value = 11011011 and IN2 value = 00100100 and IN2 value = 00110010 then OUT value = 11111111 then OUT value = 11111011
The pixel values in the window of the input image B are scaled by a factor of 4 and subtracted from the pixel values in the window of the input image A, which are scaled by a factor of 5. The pixels of the resultant image are offset by a value of 10 to create the output image C. If A and B are multi-band images, the number of bands in C is equal to the minimum number of bands contained in A or B. The size of the output image C is 30 x 30.
An "exclusive or" is performed on the pixel values in the two windowed input images to generate output C. The number of members in C is equal to the minimum number in A or B. The output bit value equals 0 if both compare bit values are 1; otherwise, the output value equals 1.
If IN1 value = ll0ll0ll If IN1 value = ll0ll0ll and IN2 value = 00l00l00 and IN2 value = 00ll00l0 then OUT value = 11111111 then OUT value = 11101001
The size of the output image C is 30 x 30.
MATH has nine options within it to perform various mathematical computations against images. They each generate an image on a pixel-by-pixel basis for all bands in the input image.
MATH-ADD has the following algorithm: OUT(i,j) = SF1 * IN1(i,j) + SF2 * IN2(i,j) + OFFSET MATH-AND has the following algorithm: OUT(i,j) = IN1(i,j) .AND. IN2(i,j) MATH-DIV has the following algorithm: If IN2 <> 0: OUT(i,j) = (SCALFACT * (IN1(i,j)/IN2(i,j))) + OFFSET If IN2 = 0: OUT(i,j) = PIXVAL MATH-MAX has the following algorithm: OUT(i,j) = MAX(IN1,IN2) MATH-MIN has the following algorithm: OUT(i,j) = MIN(IN1,IN2) MATH-MUL has the following algorithm: OUT(i,j) = (SCALFACT * (IN1(i,j) * IN2(i,j))) + OFFSET MATH-OR has the following algorithm: OUT(i,j) = IN1(i,j) .OR. IN2(i,j) MATH-SUB has the following algorithm: OUT(i,j) = SF1 * IN1(i,j) - SF2 * IN2(i,j) + OFFSET MATH-XOR has the following algorithm: OUT(i,j)=IN1(i,j) .XOR. IN2(i,j) where (i,j) is a pixel location.
The input images do not contain the same number of bands. The number of output bands will be equal to the smaller of the two input image bands.
The number of lines for the specified images are different for the corresponding IN elements.
The number of samples for the specified images are different in the corresponding IN elements.
An error occurred while allocating dynamic memory for processing.
A bitwise comparison was attempted on a R*4 data type.
c_gettyp did not successfully retrieve the input image type.