From 1c68d78862622ac9df00c797c9a7c8c944f0e680 Mon Sep 17 00:00:00 2001 From: Pablo Seleson <31291133+pabloseleson@users.noreply.github.com> Date: Thu, 24 Aug 2023 15:37:05 -0400 Subject: [PATCH] Remove unused mvv2e factor (#37) Originally used in the MD codes --- src/CabanaPD_Integrate.hpp | 4 ++-- src/CabanaPD_Solver.hpp | 3 +-- unit_test/tstIntegrator.hpp | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/CabanaPD_Integrate.hpp b/src/CabanaPD_Integrate.hpp index 753f95ea..843ebc96 100644 --- a/src/CabanaPD_Integrate.hpp +++ b/src/CabanaPD_Integrate.hpp @@ -75,10 +75,10 @@ class Integrator double _dt, _half_dt; public: - Integrator( double dt, double mvv2e ) + Integrator( double dt ) : _dt( dt ) { - _half_dt = 0.5 * dt / mvv2e; + _half_dt = 0.5 * dt; } ~Integrator() {} diff --git a/src/CabanaPD_Solver.hpp b/src/CabanaPD_Solver.hpp index 1d9c7a69..dd38941b 100644 --- a/src/CabanaPD_Solver.hpp +++ b/src/CabanaPD_Solver.hpp @@ -126,8 +126,7 @@ class SolverElastic output_frequency = inputs->output_frequency; // Create integrator. - // FIXME: hardcoded. - integrator = std::make_shared( inputs->timestep, 1.0 ); + integrator = std::make_shared( inputs->timestep ); // Add ghosts from other MPI ranks. comm = std::make_shared( *particles ); diff --git a/unit_test/tstIntegrator.hpp b/unit_test/tstIntegrator.hpp index 91884e59..e24f4fb6 100644 --- a/unit_test/tstIntegrator.hpp +++ b/unit_test/tstIntegrator.hpp @@ -48,7 +48,7 @@ void testIntegratorReversibility( int steps ) auto x = particles.slice_x(); std::size_t num_particle = x.size(); - CabanaPD::Integrator integrator( 0.001, 1.0 ); + CabanaPD::Integrator integrator( 0.001 ); // Keep a copy of initial positions on the host using DataTypes = Cabana::MemberTypes;