예제 #1
0
 public void BuildMatrices()
 {
     if (timeIncrement < BDForder - 1)
     {
         var coeffs = new ImplicitIntegrationCoefficients
         {
             Mass      = 1 / timeStep / timeStep,
             Damping   = -1,
             Stiffness = 1 / timeStep
         };
         foreach (ILinearSystem linearSystem in linearSystems.Values)
         {
             linearSystem.Matrix = provider.LinearCombinationOfMatricesIntoStiffness(coeffs, linearSystem.Subdomain);
         }
     }
     else
     {
         var coeffs = new ImplicitIntegrationCoefficients
         {
             Mass      = BDFcoeff[BDForder - 1, BDForder] / timeStep / timeStep,
             Damping   = -BDFcoeff[BDForder - 1, BDForder + 1],
             Stiffness = BDFcoeff[BDForder - 1, BDForder + 1] / timeStep
         };
         foreach (ILinearSystem linearSystem in linearSystems.Values)
         {
             linearSystem.Matrix = provider.LinearCombinationOfMatricesIntoStiffness(coeffs, linearSystem.Subdomain);
         }
     }
 }
예제 #2
0
        public void BuildMatrices()
        {
            var coeffs = new ImplicitIntegrationCoefficients
            {
                Mass      = 1,
                Stiffness = 0
            };

            foreach (ILinearSystem linearSystem in linearSystems.Values)
            {
                linearSystem.Matrix = provider.LinearCombinationOfMatricesIntoStiffness(coeffs, linearSystem.Subdomain);
            }
        }