预测来水量修改

master
wany 2024-11-15 13:34:03 +08:00
parent 3161b83a8a
commit aa3d966cd5
1 changed files with 1 additions and 1 deletions

View File

@ -166,7 +166,7 @@ public class GateValveRealService extends ServiceImpl<GateValveRealMapper, GateV
BigDecimal value = list.stream().filter(o -> nowMonth != o.getMonth()).map(TyYearRainfall::getDrp).reduce(BigDecimal.ZERO, BigDecimal::add); BigDecimal value = list.stream().filter(o -> nowMonth != o.getMonth()).map(TyYearRainfall::getDrp).reduce(BigDecimal.ZERO, BigDecimal::add);
//预测来水量 = 月降雨量和 * 水库坝址控制流域面积 //预测来水量 = 月降雨量和 * 水库坝址控制流域面积
BigDecimal sum = nowMonthDrp.add(value); BigDecimal sum = nowMonthDrp.add(value).divide(new BigDecimal(1000),2,RoundingMode.HALF_UP);
return sum.multiply(watShedArea); return sum.multiply(watShedArea);
} }