Пример #1
0
        /// <summary>
        /// Ctor.
        /// </summary>
        /// <param name="LevelSetOperators"></param>
        /// <param name="multiphaseControl"></param>
        /// <param name="BDF"></param>
        public MatrixFactoryLevelSet(OperatorFactoryLevelSet LevelSetOperators, int LocalNoOfCells, SolverConfiguration solverConf, BDFScheme BDF)
        {
            LevelSet = new MatrixAssemblyLevelSet(LevelSetOperators.LevelSetAdvection);

            MultiphaseSIMPLEControl multiphaseControl = solverConf.Control as MultiphaseSIMPLEControl;

            if (multiphaseControl.LevelSetRelaxationType == RelaxationTypes.Implicit)
            {
                LevelSetApprox = new MatrixAssemblyApprox(
                    solverConf, LocalNoOfCells, LevelSet, BDF, 2 * multiphaseControl.PredictorApproximationUpdateCycle);
            }
        }
Пример #2
0
        /// <summary>
        /// Ctor.
        /// </summary>
        /// <param name="SolverConf"></param>
        /// <param name="WorkingSet"></param>
        /// <param name="WorkingSetMatrices"></param>
        public SIMPLEStepMultiphase(SolverConfiguration SolverConf, VariableSet WorkingSet, VariableMatrices WorkingSetMatrices)
            : base(SolverConf, WorkingSet, WorkingSetMatrices)
        {
            this.SolverConf        = SolverConf;
            this.MultiphaseControl = SolverConf.Control as MultiphaseSIMPLEControl;
            if (this.MultiphaseControl == null)
            {
                throw new ArgumentException("Invalid configuration", nameof(SolverConf));
            }

            // Construct SIMPLEOperators
            UnsetteledCoordinateMapping LevelSetMapping = new UnsetteledCoordinateMapping(WorkingSet.LevelSetBasis);

            OperatorsLevelSet = new OperatorFactoryLevelSet(LevelSetMapping,
                                                            WorkingSet.Velocity.Current,
                                                            WorkingSet.VelocityMean,
                                                            SolverConf);

            // Construct matrix assemblies
            MatrixAssembliesLevelSet = new MatrixFactoryLevelSet(OperatorsLevelSet, LevelSetMapping.GridDat.iLogicalCells.NoOfLocalUpdatedCells, SolverConf, base.BDF);
        }