Exemplo n.º 1
0
 /**
  * Calculate VDOT by heart rate with elevation influence
  * @return float
  */
 public function calculateVDOTbyHeartRateWithElevation()
 {
     if ($this->knowsRoute()) {
         if ($this->Route->elevationUp() > 0 || $this->Route->elevationDown() > 0) {
             return $this->calculateVDOTbyHeartRateWithElevationFor($this->Route->elevationUp(), $this->Route->elevationDown());
         }
         return $this->calculateVDOTbyHeartRateWithElevationFor($this->Route->elevation(), $this->Route->elevation());
     }
     return $this->calculateVDOTbyHeartRateWithElevationFor($this->Activity->elevation(), $this->Activity->elevation());
 }