gmo61520

Untitled

Jan 7th, 2016
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. public static double GetRoadTemperature(int seconds, double ambientTemperature, double weatherCoefficient) {
  2. var wc = Equals(weatherCoefficient, 0.0) ? 1.0 : weatherCoefficient;
  3. var tc = ((double) seconds/60/60 - 7.0) * 0.04167;
  4. return 20.0 * wc * (1.0 - tc) * (
  5. (0.4 * Math.Exp(-6.0 * tc) * Math.Sin(6.0 * tc) + 0.1) * Math.Sin(0.9 * tc) * ambientTemperature / 1.5
  6. );
  7. }
Advertisement
Add Comment
Please, Sign In to add comment