|
@@ -109,9 +109,16 @@ public class GhostService {
|
|
|
if(CacheContext.wpwtlsmap.containsKey(wpday.getWindpowerstationid()))
|
|
|
{
|
|
|
List<Windturbine> wtls=CacheContext.wpwtlsmap.get(wpday.getWindpowerstationid());
|
|
|
- double rfdl= wpday.getGeneratingcapacity();
|
|
|
+ double rfdl= wpday.getGeneratingcapacity2();
|
|
|
double ssdl = new BigDecimal(rfdl).divide(new BigDecimal(wtls.size()), 2, RoundingMode.HALF_EVEN).divide(new BigDecimal(24), 2, RoundingMode.HALF_EVEN).multiply(new BigDecimal(gzsc)).doubleValue();
|
|
|
+
|
|
|
+
|
|
|
fr.setPowerloss(StringUtils.round(ssdl,2));
|
|
|
+ if(StringUtils.round(ssdl,2)==0)
|
|
|
+ {
|
|
|
+ ssdl=0.01;
|
|
|
+ fr.setPowerloss(ssdl);
|
|
|
+ }
|
|
|
faultrecordService.saveOrUpdate(fr);
|
|
|
}
|
|
|
|
|
@@ -166,9 +173,15 @@ public class GhostService {
|
|
|
if(CacheContext.wpwtlsmap.containsKey(wpday.getWindpowerstationid()))
|
|
|
{
|
|
|
List<Windturbine> wtls=CacheContext.wpwtlsmap.get(wpday.getWindpowerstationid());
|
|
|
- double rfdl= wpday.getGeneratingcapacity();
|
|
|
- double ssdl = new BigDecimal(rfdl).divide(new BigDecimal(wtls.size()), 2, RoundingMode.HALF_EVEN).divide(new BigDecimal(24), 2, RoundingMode.HALF_EVEN).multiply(new BigDecimal(gzsc)).doubleValue();
|
|
|
+ double rfdl= wpday.getGeneratingcapacity2();
|
|
|
+ double ssdl = new BigDecimal(rfdl).divide(new BigDecimal(wtls.size()), 4, RoundingMode.HALF_EVEN).divide(new BigDecimal(24), 4, RoundingMode.HALF_EVEN).multiply(new BigDecimal(gzsc)).doubleValue();
|
|
|
fr.setPowerloss(StringUtils.round(ssdl,2));
|
|
|
+ if(StringUtils.round(ssdl,2)==0)
|
|
|
+ {
|
|
|
+ ssdl=0.01;
|
|
|
+ fr.setPowerloss(ssdl);
|
|
|
+ }
|
|
|
+
|
|
|
mainrecordService.saveOrUpdate(fr);
|
|
|
}
|
|
|
|