An improved friction calculation for water level and flow velocity simulation