Ejemplo n.º 1
0
        private double[,] GetB(double[,] X)
        {
            int rowNum = X.GetLength(0);

            double[,] B   = MatrixTool.Init(rowNum, 7);
            double[,] M   = GetM();
            double[,] Mdx = GetMdx();
            double[,] Mdy = GetMdy();
            double[,] Mdz = GetMdz();
            double[,] mi  = MatrixTool.Ident(3);
            double[,] MX, MY, MZ, MK;

            MK = specialMulti(M, X);
            MX = specialMulti(Mdx, X);
            MY = specialMulti(Mdy, X);
            MZ = specialMulti(Mdz, X);

            for (int i = 0; i < rowNum; i += 3)
            {
                MatrixTool.CopySub(mi, 0, 0, 3, 3, ref B, i, 0);
            }
            MatrixTool.CopySub(MX, 0, 0, rowNum, 1, ref B, 0, 3);
            MatrixTool.CopySub(MY, 0, 0, rowNum, 1, ref B, 0, 4);
            MatrixTool.CopySub(MZ, 0, 0, rowNum, 1, ref B, 0, 5);
            MatrixTool.CopySub(MK, 0, 0, rowNum, 1, ref B, 0, 6);
            return(B);
        }
Ejemplo n.º 2
0
        private double[,] GetA()
        {
            double[,] M  = GetM();
            double[,] I2 = MatrixTool.Ident(3);
            double[,] A  = MatrixTool.Init(3, 6);

            MatrixTool.MutliConst(ref I2, -1);
            MatrixTool.MutliConst(ref M, (1 + k));
            MatrixTool.CopySub(M, 0, 0, 3, 3, ref A, 0, 0);
            MatrixTool.CopySub(I2, 0, 0, 3, 3, ref A, 0, 3);
            return(A);
        }