Esempio n. 1
0
 public void MinSumDiagon_Visualize()
 {
     int[] arrResult = MatrixFunctionality.MinSumDiagon();
     InitializeMinSumDiagon(arrResult.Length, 1);
     NumerateRowsAndCols_MinSumDiagon();
     for (int i = 0; i < arrResult.Length; i++)
     {
         DataGrid_MinSumDiagon[0, i].Value = arrResult[i];
     }
 }
Esempio n. 2
0
 public void Fill(MatrixFunctionality matrix)
 {
     int [,] matr = matrix.GetMatrix();
     Initialize(matr.GetLength(0), matr.GetLength(1));
     for (int i = 0; i < matr.GetLength(0); i++)
     {
         for (int j = 0; j < matr.GetLength(1); j++)
         {
             DataGrid[j, i].Value = matr[i, j];
         }
     }
 }
Esempio n. 3
0
        public void TransposedMatrix_Visualize()
        {
            int[,] arrResult = MatrixFunctionality.TransposedMatrix();
            InitializeTransposed(arrResult.GetLength(0), arrResult.GetLength(1));
            NumerateRowsAndCols_Transposed();

            for (int i = 0; i < arrResult.GetLength(0); i++)
            {
                for (int j = 0; j < arrResult.GetLength(1); j++)
                {
                    DataGrid_Transposed[j, i].Value = arrResult[i, j];
                }
            }
        }
Esempio n. 4
0
        public void MultiplyRowsElementsWithoutNegativeElements_Visualize()
        {
            double[] arrTempMul = MatrixFunctionality.MultiplyRowsElementsWithoutNegativeElements();

            InitializeMul(arrTempMul.Length, 1);
            NumerateRowsAndCols_Mul();
            for (int i = 0, j = 1; i < arrTempMul.Length; i++, j++)
            {
                if (arrTempMul[i] == 1)
                {
                    DataGrid_Mul[0, i].Value = "-";
                }
                else
                {
                    DataGrid_Mul[0, i].Value = arrTempMul[i];
                }
            }
        }
Esempio n. 5
0
        public void SumColumnElementsNegative_Visualize()
        {
            int[] arrTempSum = MatrixFunctionality.SumColumnElementsNegative();

            InitializeSumNeg(arrTempSum.Length, 1);
            NumerateRowsAndCols_SumNeg();

            for (int i = 0, j = 1; i < arrTempSum.Length; i++, j++)
            {
                if (arrTempSum[i] == 0)
                {
                    DataGrid_SumNeg[0, i].Value = "-";
                }
                else
                {
                    DataGrid_SumNeg[0, i].Value = arrTempSum[i];
                }
            }
        }