Thread: foo^(n/m)
View Single Post
  #1  
Old 10-16-2005, 10:05 PM
Dach Dach is offline
call me Chad, it's cooler
Dach's Avatar
Join Date: Aug 2002
Posts: 1,899
Dach is on a distinguished road
foo^(n/m)

player.chat = 2^(1/3)@" "@(-2)^(1/3);

Will produce "1.259921049 0"
The first is correct, the second is clearly not. This seems to occur for any foo^(n/m) combination where n/m is not an integer as a whole.
Edit: It shouldn't do anything for when m is even, obviously. Since that does involve i (sqrt(-1)). Unless you want to return an array, but I don't really know when that would be usefull.

-1.259921049^3 is equivalent to 2, f.y.i.
__________________
Scripting Documents:Old Script Documentation-Movement Tutorial

Last edited by Dach; 10-17-2005 at 12:17 AM..
Reply With Quote