Commit 7eb4af5e authored by Jonathan Lambrechts's avatar Jonathan Lambrechts
Browse files

no need to initialize r0,r1

parent a4e141c4
Pipeline #9339 failed with stages
in 2 minutes and 22 seconds
......@@ -266,8 +266,6 @@ static int contact_init_particle_particle(Contact *c, const ParticleProblem *p,
c->o1 = id1;
for (int i = 0; i < DIMENSION; ++i) {
c->reaction[i] = 0;
c->r0[i] = 0;
c->r1[i] = 0;
}
c->type = PARTICLE_PARTICLE;
double basis[DIMENSION][DIMENSION];
......@@ -328,8 +326,6 @@ static int contact_init_disk_particle(Contact *c, ParticleProblem *p, size_t dis
c->o1 = particle_id;
for (int i = 0; i < DIMENSION; ++i) {
c->reaction[i] = 0;
c->r0[i] = 0;
c->r1[i] = 0;
}
c->type = PARTICLE_DISK;
double basis[DIMENSION][DIMENSION];
......@@ -402,8 +398,6 @@ static int contact_init_segment_particle(Contact *c, ParticleProblem *p, size_t
c->o1 = particle_id;
for (int i = 0; i < DIMENSION; ++i) {
c->reaction[i] = 0;
c->r0[i] = 0;
c->r1[i] = 0;
}
c->type = PARTICLE_SEGMENT;
double basis[DIMENSION][DIMENSION];
......@@ -478,8 +472,6 @@ static int contact_init_triangle_particle(Contact *c, const ParticleProblem *p,
for (int i = 0; i < 3; ++i){
c->reaction[i] = 0;
basis[0][i] = N[i] / (nn == 0 ? 1 : nn);
c->r0[i] = 0;
c->r1[i] = 0;
}
double dd[3] = {x[0]+particle->x[0] - t->p[0][0],x[1] + particle->x[1]- t->p[0][1],x[2] + particle->x[2]- t->p[0][2]};
double D = dot(basis[0], dd);
......
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