Skip to content

Commit

Permalink
fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
atmyers committed Nov 22, 2023
1 parent 8fcb201 commit f14695e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/AgentContainer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -766,7 +766,7 @@ void AgentContainer::updateStatus (MultiFab& disease_stats)
// do hospital things
timer_ptr[i] -= 1.0;
if (timer_ptr[i] == 0) {
if (CVF[age_group_ptr[i]] > 2.0)
if (CVF[age_group_ptr[i]] > 2.0) {
if (amrex::Random(engine) < (CVF[age_group_ptr[i]] - 2.0)) {
amrex::Gpu::Atomic::AddNoRet(
&ds_arr(home_i_ptr[i], home_j_ptr[i], 0,
Expand All @@ -779,9 +779,10 @@ void AgentContainer::updateStatus (MultiFab& disease_stats)
DiseaseStats::hospitalization), -1.0_rt);
status_ptr[i] = Status::immune; // If alive, hospitalized patient recovers
}
}
}
if (timer_ptr[i] == 10) {
if (CVF[age_group_ptr[i]] > 1.0)
if (CVF[age_group_ptr[i]] > 1.0) {
if (amrex::Random(engine) < (CVF[age_group_ptr[i]] - 1.0)) {
amrex::Gpu::Atomic::AddNoRet(
&ds_arr(home_i_ptr[i], home_j_ptr[i], 0,
Expand All @@ -794,6 +795,7 @@ void AgentContainer::updateStatus (MultiFab& disease_stats)
DiseaseStats::ICU), -1.0_rt);
status_ptr[i] = Status::immune; // If alive, ICU patient recovers
}
}
}
if (timer_ptr[i] == 20) {
if (amrex::Random(engine) < CVF[age_group_ptr[i]]) {
Expand Down

0 comments on commit f14695e

Please sign in to comment.