Пример #1
0
        public static MultigridOperator CreateTestMGOperator(out double[] Vec, XDGusage UseXdg = XDGusage.none, int DGOrder = 2, MatrixShape MShape = MatrixShape.full, int Resolution = 4)
        {
            MultigridOperator retMGOp;

            using (var solver = new SubBlockTestSolver2Var()
            {
                m_UseXdg = UseXdg, m_DGorder = DGOrder, m_Mshape = MShape, m_Res = Resolution
            }) {
                solver.Init(null);
                solver.RunSolverMode();
                retMGOp = solver.MGOp;
                Vec     = solver.someVec;
            }
            return(retMGOp);
        }
Пример #2
0
        public static MultigridOperator CreateTestMGOperator(out AggregationGridData[] MGSeq, XDGusage UseXdg = XDGusage.all, int DGOrder = 2, MatrixShape MShape = MatrixShape.laplace, int Resolution = 4)
        {
            MultigridOperator retMGOp;

            using (var solver = new SubBlockTestSolver2Var()
            {
                m_UseXdg = UseXdg, m_DGorder = DGOrder, m_Mshape = MShape, m_Res = Resolution
            }) {
                solver.Init(null);
                solver.RunSolverMode();
                retMGOp = solver.MGOp;
                MGSeq   = solver.MgSeq;
            }
            return(retMGOp);
        }