Commit bf45fac8 authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Merge branch 'master' into test_125

parents 4855f1da 352f3185
......@@ -96,17 +96,17 @@ void dump_indv_particle_fields(char *fileName, struct part *p) {
fprintf(file,
"%6llu %10f %10f %10f %10f %10f %10f %10f %10f %10f %13e %13e %13e "
"%13e %13e %13e %13e "
"%13e %13e %13e\n",
"%13e %13e %13e %10f\n",
p->id, p->x[0], p->x[1], p->x[2], p->v[0], p->v[1], p->v[2],
p->a_hydro[0], p->a_hydro[1], p->a_hydro[2], p->rho, p->rho_dh,
p->density.wcount, p->density.wcount_dh, p->force.h_dt,
p->force.v_sig,
#if defined(GADGET2_SPH)
p->density.div_v, p->density.rot_v[0], p->density.rot_v[1],
p->density.rot_v[2]
p->density.rot_v[2], p->entropy_dt
#elif defined(DEFAULT_SPH)
p->density.div_v, p->density.curl_v[0], p->density.curl_v[1],
p->density.curl_v[2]
p->density.div_v, p->density.rot_v[0], p->density.rot_v[1],
p->density.rot_v[2], 0.
#else
0., 0., 0., 0., 0., 0., 0., 0., 0., 0.
#endif
......@@ -146,7 +146,6 @@ void test_interactions(struct part *parts, int count,
/* Use the first particle in the array as the one that gets updated. */
struct part pi = parts[0];
// const float hig2 = hi * hi * kernel_gamma2;
FILE *file;
char serial_filename[200] = "";
......@@ -223,7 +222,7 @@ void test_interactions(struct part *parts, int count,
dump_indv_particle_fields(vec_filename, pjq[i]);
/* Perform vector interaction. */
runner_iact_nonsym_vec_density(r2q, dxq, hiq, hjq, piq, pjq);
vec_inter_func(r2q, dxq, hiq, hjq, piq, pjq);
file = fopen(vec_filename, "a");
fprintf(file, "\nPARTICLES AFTER INTERACTION:\n");
......
......@@ -193,7 +193,7 @@ int main() {
runner_do_ghost(&r, ci);
message("h=%f rho=%f N_ngb=%f", p->h, p->rho, p->density.wcount);
message("c=%f", p->force.soundspeed);
message("soundspeed=%f", p->force.soundspeed);
runner_doself2_force(&r, ci);
runner_do_kick(&r, ci, 1);
......
......@@ -87,8 +87,8 @@ int main(int argc, char *argv[]) {
p2.force.balsara = 0.0f;
p1.u = 1.e-5 / (hydro_gamma_minus_one * p1.rho);
p2.u = 1.e-5 / (hydro_gamma_minus_one * p2.rho) + 100.0f / (33 * p2.mass);
p1.force.POrho2 = p1.u * hydro_gamma_minus_one / p1.rho;
p2.force.POrho2 = p2.u * hydro_gamma_minus_one / p2.rho;
p1.force.P_over_rho2 = p1.u * hydro_gamma_minus_one / p1.rho;
p2.force.P_over_rho2 = p2.u * hydro_gamma_minus_one / p2.rho;
/* Dump a header. */
// printParticle_single(&p1, NULL);
......
# ID pos_x pos_y pos_z v_x v_y v_z rho rho_dh wcount wcount_dh div_v curl_vx curl_vy curl_vz
0 1e-6 1e-6 1e-6 1e-6 1e-6 1e-6 1e-5 1e-5 2e-5 3e-2 1e-5 1e-5 1e-5 1e-5
0 1e-6 1e-6 1e-6 1e-6 1e-6 1e-6 1e-5 1e-5 4e-5 3e-2 1e-5 1e-5 1e-5 1e-5
0 1e-6 1e-6 1e-6 1e-6 1e-6 1e-6 1e-5 1.2e-5 1e-5 1e-2 1e-4 1e-4 1e-4 1e-4
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