added Druckrohrleitungs class, based on ETH Code

This commit is contained in:
Brantegger Georg
2022-06-29 13:51:53 +02:00
parent 57cb951f5b
commit 8cfd14838c
7 changed files with 401 additions and 16 deletions

View File

@@ -4,11 +4,11 @@ class Ausgleichsbecken_class:
# units
area_unit = r'$\mathrm{m}^2$'
area_outflux_unit = r'$\mathrm{m}^2$'
level_unit = 'm'
volume_unit = r'$\mathrm{m}^3$'
flux_unit = r'$\mathrm{m}^3/\mathrm{s}$'
time_unit = 's'
level_unit = 'm'
pressure_unit = 'Pa'
time_unit = 's'
volume_unit = r'$\mathrm{m}^3$'
# init
def __init__(self,area,outflux_area,level_min,level_max,timestep = 1):
@@ -73,6 +73,7 @@ class Ausgleichsbecken_class:
h = self.level
dt = self.timestep
p,_ = pressure_conversion(self.pressure,self.pressure_unit,'Pa')
# update to include p_halfstep
p_hs,_ = pressure_conversion(self.pressure,self.pressure_unit,'Pa')
alpha = (self.area_outflux/self.area-1)
h_hs = self.update_level(dt/2)

View File

@@ -91,6 +91,7 @@
"i_max = -1\n",
"\n",
"for i in range(np.size(time_vec)-1):\n",
" # update to include p_halfstep\n",
" V.pressure = pressure_vec[i]\n",
" V.e_RK_4()\n",
" V.level = V.update_level(V.timestep)\n",