4

I need to evaluate what simplifies to:

using System;
using System.Collections.Generic;
using MathNet.Symbolics;

namespace GtEq {
    static class Program {
        private static void Main(string[] args) {
            var eq = Infix.ParseOrThrow("a > b");
            var result = Evaluate.Evaluate(new Dictionary<string, FloatingPoint>() {
                {"a", 5.0},
                {"b", 1.0}
            }, eq);
            Console.WriteLine(result);
        }
    }
}

And it throws on parser line not getting what ">" means. enter image description here I wonder if there is a comon way to expand MathNet.Symbolics for it to support "> < >= <=" operations?

Community
  • 1
  • 1
DuckQueen
  • 772
  • 10
  • 62
  • 134

0 Answers0