예제 #1
0
        public Result Work(int size)
        {
            startMas = new decimal[size, size];
            for (int i = 0; i < size; i++)
            {
                for (int j = 0; j < size; j++)
                {
                    startMas[i, j] = mas[i, j];
                }
            }
            createB();

            WorkMethods wm = new WorkMethods();

            setMas = wm.createULJordan(getMas, size);
            setX2  = wm.solutionOfTheSystem(getMas, getB);
            int     count         = wm.getCountOperations();
            decimal maxDifference = wm.findMaxDifferenceX(x, x2);
            decimal maxNorm       = wm.findMaxDifferenceInverseMatrix(startMas, mas);

            return(new Result(size, maxDifference, count, maxNorm));
        }
예제 #2
0
        private void createB()
        {
            WorkMethods wm = new WorkMethods();

            b = wm.matrixCompositionResultVector(mas, x);
        }