changed graph and calculation for flood