def create_equations(self): equations = [ # Properties computed set from the current state Group( equations=[ # p MieGruneisenEOS(dest='bar', sources=None, gamma=gamma, r0=r0, c0=C, S=S), # vi,j : requires properties v00, v01, v10, v11 VelocityGradient2D(dest='bar', sources=[ 'bar', ]), # rij : requires properties s00, s01, s11 VonMisesPlasticity2D(flow_stress=Yo, dest='bar', sources=None), ], ), # Acceleration variables are now computed Group(equations=[ # arho ContinuityEquation(dest='bar', sources=['bar']), # au, av MomentumEquationWithStress(dest='bar', sources=['bar']), # au, av MonaghanArtificialViscosity(dest='bar', sources=['bar'], alpha=0.5, beta=0.5), # au av MonaghanBoundaryForce(dest='bar', sources=['plate'], deltap=dx), # ae EnergyEquationWithStress(dest='bar', sources=['bar'], alpha=0.5, beta=0.5, eta=0.01), # a_s00, a_s01, a_s11 HookesDeviatoricStressRate(dest='bar', sources=None), # ax, ay, az XSPHCorrection(dest='bar', sources=[ 'bar', ], eps=0.5), ]) # End Acceleration Group ] # End Group list return equations
def create_equations(self): equations = [ # update smoothing length # Group( # equations = [ # UpdateSmoothingLengthFromVolume(dest='plate', sources=['plate', 'projectile'], dim=dim, k=hdx), # UpdateSmoothingLengthFromVolume(dest='projectile', sources=['plate', 'projectile'], dim=dim, k=hdx), # ], # update_nnps=True, # ), # compute properties from the current state Group(equations=[ # EOS (compute the pressure using one of the EOSs) # MieGruneisenEOS(dest='plate', sources=None, gamma=gamma1, r0=ro1 , c0=C1, S=S1), # MieGruneisenEOS(dest='projectile', sources=None, gamma=gamma2, r0=ro2 , c0=C2, S=S2), StiffenedGasEOS( dest='plate', sources=None, gamma=gamma1, r0=ro1, c0=C1), StiffenedGasEOS(dest='projectile', sources=None, gamma=gamma2, r0=ro2, c0=C2), # compute the velocity gradient tensor VelocityGradient3D(dest='plate', sources=['plate']), VelocityGradient3D(dest='projectile', sources=['projectile']), # # stress VonMisesPlasticity2D( dest='plate', sources=None, flow_stress=Yo1), VonMisesPlasticity2D( dest='projectile', sources=None, flow_stress=Yo2), # # artificial stress to avoid clumping MonaghanArtificialStress(dest='plate', sources=None, eps=0.3), MonaghanArtificialStress( dest='projectile', sources=None, eps=0.3), ]), # accelerations (rho, u, v, ...) Group(equations=[ # continuity equation ContinuityEquation(dest='plate', sources=['projectile', 'plate']), ContinuityEquation(dest='projectile', sources=['projectile', 'plate']), # momentum equation MomentumEquationWithStress(dest='projectile', sources=[ 'projectile', 'plate', ]), MomentumEquationWithStress(dest='plate', sources=[ 'projectile', 'plate', ]), # energy equation: EnergyEquationWithStress(dest='plate', sources=[ 'projectile', 'plate', ], alpha=avisc_alpha, beta=avisc_beta, eta=avisc_eta), EnergyEquationWithStress(dest='projectile', sources=[ 'projectile', 'plate', ], alpha=avisc_alpha, beta=avisc_beta, eta=avisc_eta), # avisc MonaghanArtificialViscosity(dest='plate', sources=['projectile', 'plate'], alpha=avisc_alpha, beta=avisc_beta), MonaghanArtificialViscosity(dest='projectile', sources=['projectile', 'plate'], alpha=avisc_alpha, beta=avisc_beta), # updates to the stress term HookesDeviatoricStressRate( dest='plate', sources=None, shear_mod=1.), HookesDeviatoricStressRate( dest='projectile', sources=None, shear_mod=1.), # position stepping XSPHCorrection(dest='plate', sources=['plate'], eps=xsph_eps), XSPHCorrection( dest='projectile', sources=['projectile'], eps=xsph_eps), ]), ] # End Group list return equations