Skip to content

Commit 149abb1

Browse files
Fixed index problem in WellBores.py calculation of overpressure and added edge test case.
1 parent cb29e6f commit 149abb1

File tree

3 files changed

+366
-1
lines changed

3 files changed

+366
-1
lines changed

src/geophires_x/WellBores.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ def ReservoirPressurePredictor(project_lifetime_yr: int, timesteps_per_year: int
7878
delta_pressure = (pressure[0] - initial_pressure_kPa)
7979
depletion_timesteps = int((100.0 / depletion_rate) * timesteps_per_year)
8080
pressure_change_per_timestep = delta_pressure / depletion_timesteps
81-
for timestep in range(1, depletion_timesteps):
81+
for timestep in range(1, project_lifetime_yr * timesteps_per_year):
8282
pressure[timestep] = pressure[0] - (pressure_change_per_timestep * timestep)
8383
if pressure[timestep] < initial_pressure_kPa:
8484
# If the pressure drops below the hydrostatic pressure, set it to the hydrostatic pressure and break out

0 commit comments

Comments
 (0)