using System; using System.Collections.Generic; using System.Linq; using System.Text; using L = Science.Mathematics.LinearAlgebra; namespace Strang3Ed.Chapter03.Section2 { public class Example01 { public Example01() { } private string result; public string Result { get{return result;} } public void Compute() { double[,] a = { { 1.0, 2.0, 3.0 } }; L.Matrix A = new L.Matrix(a); L.Nullspace N = new L.Nullspace(A); result += N.Basis[0].ToString() + "\r\n"; result += N.Basis[1].ToString() + "\r\n"; double[] x = { 1.0, 2.0 }; L.Vector v = N.LinearCombination(x); result += v.ToString(); } } } /* -2 1 0 -3 0 1 -8 1 2 */