using System; using AngouriMath; using System.Numerics;
var func = expr.Compile<Complex, Complex>("x");
Console.WriteLine(func(new Complex(1, 0)));
Console.WriteLine(func(new Complex(0, 1)));
Console.WriteLine(func(new Complex(1, 1)));
Entity expr2 = "x + sin(x) + y";
var func2 = expr2.Compile<double, double, double>("x", "y");
Console.WriteLine(func2(2, 3));
Entity expr3 = "x > 3 and tan(y) < 6";
var func3 = expr3.Compile<double, double, bool>("x", "y");
Console.WriteLine(func3(4, 5));
Console.WriteLine(func3(2, 5));
Console.WriteLine(func3(4, 0));
Console.WriteLine(func3(2, 0));