Commit c5a751c3 authored by Jonathan Lambrechts's avatar Jonathan Lambrechts
Browse files

fix

parent cb36d6f7
Pipeline #8679 failed with stages
in 3 minutes and 47 seconds
......@@ -1766,6 +1766,8 @@ void fluid_problem_set_particles(FluidProblem *problem, int n, double *mass, dou
problem->particle_contact = (double*)malloc(sizeof(double)*n*D);
}
for (int i = 0; i < n; ++i) {
problem->particle_mass[i] = mass[i];
problem->particle_volume[i] = volume[i];
for (int k = 0; k < D; ++k) {
problem->particle_position[i*D+k] = position[i*D+k];
problem->particle_velocity[i*D+k] = velocity[i*D+k];
......
......@@ -109,7 +109,7 @@ fluid.set_wall_boundary("Bottom")
fluid.set_wall_boundary("Lateral")
fluid.set_wall_boundary("Top",pressure=0)
# Set location of the particles in the mesh and compute the porosity in each computation cell
fluid.set_particles(p.mass(), p.volume(), p.position(), p.velocity(), p.contact_forces(),init=True)
fluid.set_particles(p.mass(), p.volume(), p.position(), p.velocity(), p.contact_forces())
fluid.export_vtk(outputdir,0,0)
p.write_vtk(outputdir, 0, 0)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment