* Static method to construct a complex number in rectangular form from polar coordinates * @param theta - The angle/arguement * @param magnitude - The magnitude * @returns Complex number in rectangular coordinates constructed from the arguement theta & the * magnitude
(theta: number, magnitude: number)
| 193 | * magnitude |
| 194 | */ |
| 195 | public static fromPolar(theta: number, magnitude: number): complex |
| 196 | { |
| 197 | return new complex (magnitude * Math.cos(theta), magnitude * Math.sin(theta)); |
| 198 | } |
| 199 | |
| 200 | /** |
| 201 | * Get the complex number's polar coordinates as a tuple |