/// <summary> /// Подбирает точки Безье для указанного полинома. /// </summary> /// <param name="polynomial"></param> /// <returns></returns> private static double[] GetBezierPoints(Polynomial polynomial) { return(LinearSystem.Resolve(new[] { new Linear(Line1, polynomial[0]), new Linear(Line2, polynomial[1]), new Linear(Line3, polynomial[2]), new Linear(Line4, polynomial[3]), })); }
public void TestResolve() { Matrix mat = new Matrix() { { 3, 5, 20 }, { -1, 1, 0 } }; LinearSystem ls = new LinearSystem(mat); Dictionary <string, double> dic = ls.Resolve(); Assert.AreEqual(dic["0"], 2.5); Assert.AreEqual(dic["1"], 2.5); }