Pow bug in Gen?
Hi,
I'm late to the game with Gen.
I'm using the pow function.
If I have [pow 2] and I send it a value of 0 it should return a value of 1, but for some reason it returns a value of 0.
Has anyone else observed this behaviour?
Thanks,
D
mixed inputs? the pow story is not exactly linear.
Max: base, exponent
MSP: exponent, base
Gen: base, exponent
Gen~ : doesnt exist
Danke!
[pow] certainly does exist in gen~! It has two inputs for base and exponent respectively, just like Max's [pow], the C pow(base, exponent) function, and the equivalent in most common math libraries.
[pow 2] in gen~ replaces the 2nd input with a 2, i.e. it raises the input to the power of 2.
If you want to raise 2 to the power of something in gen~, hook up a [2] to the first input of a [pow] or use an [expr pow(2,in)].
Yes. I slightly misread the last post so I figured out the I just had the inputs swapped. In retrospect, I probably should have spotted this. Many thanks for your clarification Graham.
D