| | |
| | | |
| | | String time = wd.getTableName().replace("su_yuan_", ""); |
| | | double lastVal = 0; |
| | | double speed1 = CalculateUtils.getWindSpeed(suYuan.getV(), suYuan.getU()); |
| | | double speed1 = CalculateUtils.round2(CalculateUtils.getWindSpeed(suYuan.getV(), suYuan.getU())); |
| | | double direction1 = CalculateUtils.getWindDirection(suYuan.getV(), suYuan.getU()); |
| | | String dir = CalculateUtils.getDir(direction1); |
| | | |
| | | double maxVal = suMax.getVocsValue(); |
| | | |
| | | double dis = CalculateUtils.getDistance2(c1.getX(), c1.getY(), c2.getX(), c2.getY()); |
| | | //double dis = CalculateUtils.getDistance2(c1.getX(), c1.getY(), c2.getX(), c2.getY()); |
| | | double dis1 = CalculateUtils.getDistance1(c1.getX(), c1.getY(), c2.getX(), c2.getY()); |
| | | double angle = CalculateUtils.getAngle(c1.getX(), c1.getY(), c2.getX(), c2.getY()); |
| | | double angle = CalculateUtils.getAngle2(c1.getX(), c1.getY(), c2.getX(), c2.getY()); |
| | | |
| | | double speed2 = CalculateUtils.getWindSpeed(suMax.getV(), suMax.getU()); |
| | | double direction2 = CalculateUtils.getWindDirection(suMax.getV(), suMax.getU()); |
| | | String maxDir = CalculateUtils.getDir(direction2); |
| | | int isSame = (Math.abs(direction1 - direction2) < 15 && Math.abs(speed1 - speed2) < 0.3) ? 1 : 0; |
| | | String maxDir = CalculateUtils.getDir(angle); |
| | | int isSame = (Math.abs(direction1 - direction2) < 30 && Math.abs(speed1 - speed2) < 0.5) ? 1 : 0; |
| | | |
| | | return new Report(wd.getLocationName(), c1.getX(), c1.getY(), wd.getValue(), lastVal, time, |
| | | speed1, dir, maxVal, dis, maxDir, isSame); |
| | | speed1, dir, maxVal, dis1, maxDir, isSame); |
| | | } |
| | | |
| | | public String getName() { |