From 7bbafda7ca37f4c6266dc6003adb0354912e5338 Mon Sep 17 00:00:00 2001 From: Austin Blevins Date: Wed, 1 Mar 2023 10:36:12 -0500 Subject: [PATCH] fixed a bug where regolith volumes weren't mixing correctly --- src/regolith/regolith_mix.f90 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/regolith/regolith_mix.f90 b/src/regolith/regolith_mix.f90 index 06b7da90..a7b36668 100644 --- a/src/regolith/regolith_mix.f90 +++ b/src/regolith/regolith_mix.f90 @@ -52,6 +52,8 @@ subroutine regolith_mix(surfi,mixing_depth,domain) newlayer%distvol(:) = 0.0_SP newlayer%ejm = 0.0_DP newlayer%ejmf = 0.0_DP + newlayer%meltvolume = 0.0_DP + newlayer%totvolume = 0.0_DP !poppedlist => poppedlist_top !do while(associated(poppedlist%next)) @@ -66,6 +68,7 @@ subroutine regolith_mix(surfi,mixing_depth,domain) newlayer%ejm = newlayer%ejm + poppedarray(i)%thickness * poppedarray(i)%ejm newlayer%ejmf = newlayer%ejmf + poppedarray(i)%thickness * poppedarray(i)%ejmf newlayer%meltvolume = newlayer%meltvolume + poppedarray(i)%thickness * poppedarray(i)%meltvolume + newlayer%totvolume = newlayer%totvolume + poppedarray(i)%thickness * poppedarray(i)%totvolume end do ! Get average values of composition and melt fraction