diff --git a/Source/Initialization/InjectorMomentum.H b/Source/Initialization/InjectorMomentum.H index d5f19214e3c..98caae1bb23 100644 --- a/Source/Initialization/InjectorMomentum.H +++ b/Source/Initialization/InjectorMomentum.H @@ -341,7 +341,7 @@ struct InjectorMomentumBoltzmann for (auto& el : u) el = 0.0_rt; const amrex::Real beta = velocity(x,y,z); int const dir = velocity.direction(); - const auto gamma = static_cast(1._rt/sqrt(1._rt-beta*beta)); + const auto gamma = 1._rt/std::sqrt(1._rt-beta*beta); u[dir] = gamma*beta; return amrex::XDim3 {u[0],u[1],u[2]}; } @@ -444,7 +444,7 @@ struct InjectorMomentumJuttner for (auto& el : u) el = 0.0_rt; amrex::Real const beta = velocity(x,y,z); int const dir = velocity.direction(); - auto const gamma = static_cast(1._rt/sqrt(1._rt-beta*beta)); + auto const gamma = 1._rt/std::sqrt(1._rt-beta*beta); u[dir] = gamma*beta; return amrex::XDim3 {u[0],u[1],u[2]}; }