From 9dc6cfc5d5f4dba2aba9ef965b3e9380f7fef52f Mon Sep 17 00:00:00 2001 From: Cristian C Lalescu <Cristian.Lalescu@ds.mpg.de> Date: Mon, 23 Apr 2018 17:44:50 +0200 Subject: [PATCH] temporary array for sampling needs to be cleaned up --- bfps/cpp/full_code/NSVEparticles.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bfps/cpp/full_code/NSVEparticles.cpp b/bfps/cpp/full_code/NSVEparticles.cpp index 5f9f480d..c4db9ee7 100644 --- a/bfps/cpp/full_code/NSVEparticles.cpp +++ b/bfps/cpp/full_code/NSVEparticles.cpp @@ -103,6 +103,7 @@ int NSVEparticles<rnumber>::do_stats() this->ps->get_step_idx()-1); /// sample velocity + std::fill_n(pdata.get(), 3*this->ps->getLocalNbParticles(), 0); this->ps->sample_compute_field(*this->tmp_vec_field, pdata.get()); this->particles_sample_writer_mpi->template save_dataset<3>( "tracers0", @@ -116,6 +117,7 @@ int NSVEparticles<rnumber>::do_stats() /// compute acceleration and sample it this->fs->compute_Lagrangian_acceleration(this->tmp_vec_field); this->tmp_vec_field->ift(); + std::fill_n(pdata.get(), 3*this->ps->getLocalNbParticles(), 0); this->ps->sample_compute_field(*this->tmp_vec_field, pdata.get()); this->particles_sample_writer_mpi->template save_dataset<3>( "tracers0", -- GitLab