mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-13 16:18:42 +00:00
Merge pull request #1279 from amtriathlon/master
Fixed GOVSS & SwimScore for manual workouts
This commit is contained in:
@@ -352,7 +352,8 @@ class GOVSS : public RideMetric {
|
||||
assert(deps.contains("time_riding"));
|
||||
double watts = running_power(weight, height, deps.value("average_speed")->value(true) / 3.6);
|
||||
double secs = deps.value("time_riding")->value(true);
|
||||
rawGOVSS = watts * secs;
|
||||
double iwf = rtp->value(true) ? watts / rtp->value(true) : 0.0;
|
||||
rawGOVSS = watts * secs * iwf;
|
||||
}
|
||||
double workInAnHourAtRTP = rtp->value(true) * 3600;
|
||||
score = workInAnHourAtRTP ? rawGOVSS / workInAnHourAtRTP * 100.0 : 0;
|
||||
|
||||
@@ -298,7 +298,8 @@ class SwimScore : public RideMetric {
|
||||
assert(deps.contains("time_riding"));
|
||||
double watts = swimming_power(weight, deps.value("average_speed")->value(true) / 3.6);
|
||||
double secs = deps.value("time_riding")->value(true);
|
||||
rawGOVSS = watts * secs;
|
||||
double sri = stp->value(true) ? watts / stp->value(true) : 0.0;
|
||||
rawGOVSS = watts * secs * sri;
|
||||
}
|
||||
double workInAnHourAtSTP = stp->value(true) * 3600;
|
||||
score = workInAnHourAtSTP ? rawGOVSS / workInAnHourAtSTP * 100.0 : 0;
|
||||
|
||||
Reference in New Issue
Block a user