Skip to content

Instantly share code, notes, and snippets.

@r38y
Created September 9, 2009 23:12
Show Gist options
  • Save r38y/184160 to your computer and use it in GitHub Desktop.
Save r38y/184160 to your computer and use it in GitHub Desktop.
Lose It or Lose It's formula to success
Maximum Weekly Reward = week# * $/lb * lb/wk + $5
Actual Weekly Reward = min(MWR, ((start - goal) - (actual - goal))*$/lb) + $5
where
* goal = start - week number * lb/wk
* start = first weigh-in weight
* actual = week's actual weigh-in weight
So, for week 5 of 2-2:
* goal = 200 - 5 * 2 lb/wk = 190lb
* MWR = 5 * 2 * 2 + $5 = $25
with a weigh-in of 200 (no weight lost)
AWR = min(25, ((200 - 190) - (200 - 190)) * $2/lb + $5)
= min(25, (10 - 10) * 2 + $5)
= min(25, 0 + $5)
= $5
with a weigh-in of 190 (on goal)
AWR = min(25, ((200 - 190) - (190 - 190)) * $2/lb + $5)
= min(25, (10 - 0) * 2 + $5)
= min(25, 20 + $5)
= $25
with a weigh-in of 188 (below goal)
AWR = min(25, ((200 - 190) - (188 - 190)) * $2/lb + $5)
= min(25, (10 - -2) * 2 + $5)
= min(25, 24 + $5)
= $25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment