11. Unary operations
A unary operation is one that is performed on a single object, with no additional inputs. A single object is returned.
11.1. unary plus
Unary plus. Returns the input object win
with no modification.
wout = +win
Equivalent to wout = uplus(win)
11.2. unary minus
Unary minus. Returns the intensity field of the input object multiplied by -1, i.e. wout = -1 win
.
wout = -win
Equivalent to wout = uminus(win)
11.3. Trigonometric and hyperbolic functions
With the form
wout = function(win)
where function
is any of the following, trigonometric or hyperbolic operations may be performed on dnd or sqw objects.
acos
- arc cosineacosh
- arc coshacot
- arc cotacoth
- arc cothacsc
- arc cosecacsch
- arc cosechasec
- arc secasech
- arc sechasin
- arc sineasinh
- arc sinhatan
- arc tangentatanh
- arc tanhcos
- cosinecosh
- coshcot
- cotcoth
- cothcsc
- coseccsch
- cosechsec
- secsech
- sechsin
- sinesinh
- sinhtan
- tangenttanh
- tanh
11.4. Other mathematical functions
Using the same syntax as above, one can perform the following operations:
exp
- exponentiallog
- natural logarithmlog10
- logarithm base 10