Run Code
|
API
|
Code Wall
|
Users
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Blog
COMPLEX NUMBER
//Rextester.Program.Main is the entry point for your code. Don't change it. //Compiler version 4.0.30319.17929 for Microsoft (R) .NET Framework 4.5 using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; using System.Numerics; //DEVELOPER: PANNA CHATTERJEE namespace Rextester { public class Program { public static void Main(string[] args) { // Initializing the complex: (-1.0+0.0i) Complex mycomplex = new Complex(0.0, 1.0); //Cos,Sin,Tan Console.WriteLine(Complex.Cos(mycomplex)); Console.WriteLine(Complex.Sin(mycomplex)); Console.WriteLine(Complex.Tan(mycomplex)); //Pow Console.WriteLine(Complex.Pow(Complex.One, -1)); // Instantiate a complex number from its polar coordinates. Console.WriteLine(Complex.FromPolarCoordinates(10, .524)); //Log Console.WriteLine(Complex.Log(10)); //Sqrt Complex minusOne = new Complex(-1, 0); Console.WriteLine(Complex.Sqrt(minusOne)); } } }
run
|
edit
|
history
|
help
0
Remember:-[In case of C# you need Namespace: System.Numerics]
by PANNA CHATTERJEE, 3 years ago
Please
log in
to post a comment.
ch.murali krishna
Bid Status
Collection Basic
Interface with same methods
RegEx
SKYIES
split string
Test equality
Número primers
D110
Remember:-[In case of C# you need Namespace: System.Numerics]
by PANNA CHATTERJEE, 3 years agoPlease log in to post a comment.