Open luchete80 opened 2 years ago
Current order is:
accel
density
velocity
position
stress/strain
LastComputeAcceleration();
Move(deltat); // DOES NOT INCLUDE GHOST PARTICLES
inline void Particle::Move_Leapfrog(Mat3_t I, double dt)
{
if (FirstStep) {
Densitya = Density - dt/2.0*dDensity;
va = v - dt/2.0*a;
}
Densityb = Densitya;
Densitya += dt*dDensity;
Density = (Densitya+Densityb)/2.0;
vb = va;
va += dt*a;
v = (va + vb)/2.0;
x += dt*(va+VXSPH);
Displacement += dt*va;
Mat2Leapfrog(dt);
if (FirstStep) FirstStep = false;
}
Leapfrog in SolverGPU is working Ok, should be compared with that
According to Randles and Libersky (1996)