# BandMath

## Brief Description

Perform a mathematical operation on monoband images

## Tags

Util

## Long Description

This application performs a mathematical operation on monoband images.Mathematical formula interpretation is done via MuParser libraries. For MuParser version superior to 2.0 uses '&&' and '||' logical operators, and ternary operator 'boolean_expression ? if_true : if_false' For older version of MuParser (prior to v2) use 'and' and 'or' logical operators, and ternary operator 'if(; ; )'. The list of features and operators is available on MuParser website: http://muparser.sourceforge.net/

## Parameters

- [param] -il <string> Image list to perform computation on.. Mandatory: True. Default Value: "0"
- [param] -out <string> Output image.. Mandatory: True. Default Value: ""
- [param] -ram <int32> Available memory for processing (in MB). Mandatory: False. Default Value: "128"
- [param] -exp <string> The mathematical expression to apply. Use im1b1 for the first band, im1b2 for the second one.... Mandatory: True. Default Value: ""
- [param] -inxml <string> Load otb application from xml file. Mandatory: False. Default Value: ""
- [param] -outxml <string> Save otb application to xml file. Mandatory: False. Default Value: ""

## Limitations

None

## Authors

OTB-Team

## See Also

## Example of use

- il: verySmallFSATSW_r.tif verySmallFSATSW_nir.tif verySmallFSATSW.tif

- out: apTvUtBandMathOutput.tif

- exp: "cos(im1b1) > cos(im2b1) ? im3b1 : im3b2 "