User Tools

Site Tools


en:hydro:abm

Alternating Block Method

|ABM.Py
import numpy as np
 
def altblocks(idf,dur,dt,RP):
    aDur = np.arange(dt,dur+dt,dt)    # in minutes
    aInt = (idf[0]*RP**idf[1])/((aDur+idf[2])**idf[3])  # idf equation - in mm/h
    aDeltaPmm = np.diff(np.append(0,np.multiply(aInt,aDur/60.0)))
    aOrd=np.append(np.arange(1,len(aDur)+1,2)[::-1],np.arange(2,len(aDur)+1,2))
    prec = np.asarray([aDeltaPmm[x-1] for x in aOrd])
    aAltBl = np.vstack((a,b))
    return aAltBl
 
 
/usr/www/users/uhydro/doku/data/pages/en/hydro/abm.txt · Last modified: 2024/04/10 10:02 by 127.0.0.1