Skip to content
Snippets Groups Projects
Commit 97a04907 authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Correct i/o also in MPI mode(s)

parent 91cc3a7e
Branches
Tags
2 merge requests!136Master,!79First version of the multiple time-stepping
......@@ -270,7 +270,7 @@ void read_ic_parallel(char* fileName, double dim[3], struct part** parts,
COMPULSORY);
readArray(h_grp, "SmoothingLength", FLOAT, *N, 1, *parts, N_total, offset, h,
COMPULSORY);
readArray(h_grp, "InternalEnergy", FLOAT, *N, 1, *parts, N_total, offset, u,
readArray(h_grp, "InternalEnergy", FLOAT, *N, 1, *parts, N_total, offset, entropy,
COMPULSORY);
readArray(h_grp, "ParticleIDs", ULONGLONG, *N, 1, *parts, N_total, offset, id,
COMPULSORY);
......@@ -580,7 +580,7 @@ void write_output_parallel(struct engine* e, struct UnitSystem* us,
writeArray(h_grp, fileName, xmfFile, "SmoothingLength", FLOAT, N, 1, parts,
N_total, mpi_rank, offset, h, us, UNIT_CONV_LENGTH);
writeArray(h_grp, fileName, xmfFile, "InternalEnergy", FLOAT, N, 1, parts,
N_total, mpi_rank, offset, u, us, UNIT_CONV_ENERGY_PER_UNIT_MASS);
N_total, mpi_rank, offset, entropy, us, UNIT_CONV_ENERGY_PER_UNIT_MASS);
writeArray(h_grp, fileName, xmfFile, "ParticleIDs", ULONGLONG, N, 1, parts,
N_total, mpi_rank, offset, id, us, UNIT_CONV_NO_UNITS);
/* writeArray(h_grp, fileName, xmfFile, "TimeStep", FLOAT, N, 1, parts,
......
......@@ -311,7 +311,7 @@ void read_ic_serial(char* fileName, double dim[3], struct part** parts, int* N,
readArray(h_grp, "SmoothingLength", FLOAT, *N, 1, *parts, N_total, offset,
h, COMPULSORY);
readArray(h_grp, "InternalEnergy", FLOAT, *N, 1, *parts, N_total, offset,
u, COMPULSORY);
entropy, COMPULSORY);
readArray(h_grp, "ParticleIDs", ULONGLONG, *N, 1, *parts, N_total, offset,
id, COMPULSORY);
/* readArray(h_grp, "TimeStep", FLOAT, *N, 1, *parts, N_total, offset, dt,
......@@ -670,7 +670,7 @@ void write_output_serial(struct engine* e, struct UnitSystem* us, int mpi_rank,
writeArray(h_grp, "SmoothingLength", FLOAT, N, 1, N_total, offset, parts,
h);
writeArray(h_grp, "InternalEnergy", FLOAT, N, 1, N_total, offset, parts,
u);
entropy);
writeArray(h_grp, "ParticleIDs", ULONGLONG, N, 1, N_total, offset, parts,
id);
//writeArray(h_grp, "TimeStep", FLOAT, N, 1, N_total, offset, parts, dt);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment