Making negatives positive
Hi all!
Does anyone know of an easy way to make a negative number (or list of numbers) change to its equivalent positive value?
Thanks Guy
For a number [abs] or [abs 0.]. For a list of ints, [vexpr abs($i1)] or floats [vexpr abs($f1)].
Thanks pal!!
....in addition to those elegant solutions, [!- 0] or [!- 0.] will also work on a stream of numbers: 0. - (-4.) = 4.
Brendan
[* -1] and [* -1.] will also work (assuming you know the input is negative). If you can have both positive and negative values, use [abs].
just to make the thread complete:
[expr -($f1)]
Yet another way: [scale 1. 10. -1. -10.]
Max Patch
Copy patch and select New From Clipboard in Max.
There is no limit to the convoluted ways of doing this. I'll see your [scale] and raise you this:
one could also convert the input into a video signal.