[chuck-users] Power operator in chuck

Ge Wang gewang at CS.Princeton.EDU
Mon Nov 28 23:38:20 EST 2005


Welcome Tennessee!

> I just downloaded chuck. Perhaps I'm being a bit blind/dense, but
> there doesn't seem to be a simple power operator in chuck. Given that 
> power-laws appear in many places, it would be a very useful operator. 
> Hopefully I'm just missing it?

Currently, there is math.pow( float, float ) but no dedicated power 
operator (like ** in python?).  Other languages sometimes use a^b to 
denote power, however ^ is the xor binary operator in ChucK (like in C). 
Unless there is a really compelling reason to include a specialized
power operator, it is unlikely chuck will support it (at least for now).

Best,
Ge!


More information about the chuck-users mailing list