Open-source calculator for determining best Social Security claiming age(s)
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.vscode
Notes on SS Rules
e2e
src
.editorconfig
.gitignore
.nojekyll
3rdpartylicenses.txt
404.html
CNAME
README.md
angular.json
favicon.ico
index.html
inline.318b50c57b4eba3d437b.bundle.js
inline.bundle.js
inline.bundle.js.map
karma.conf.js
main.05a621713d31553be47d.js
main.1291ed946b73b5c7fa9a.js
main.141890be6ee06f461b79.js
main.26a9502ec72aca9a9fcd.js
main.46e88f060323f9957df7.js
main.4ce583f2f514d0c83bd0.js
main.54fbeafbb54243d792c3.bundle.js
main.570ce1badc0c6125b548.js
main.5ba6f88b7a9326815fbd.js
main.641320d4cf9c8008c21f.bundle.js
main.65c6e6bb4d17fad15363.js
main.66a65a2204165e1f26f5.js
main.69525751f2271e54162a.js
main.7049fc58ba4278756266.js
main.771a6038b51fd031fa7e.js
main.7982c8cca422bbcd765a.js
main.7aa8946f33fe3e6161ec.js
main.7b829e4046bd8c86aded.js
main.80029aa1090c986224f2.js
main.80d3c148b5cd2fdd78b4.js
main.80f66fa3b31c91d2085d.js
main.90d804754d3faff2b2a8.js
main.9196ca0ceb9233fbc98d.js
main.966b9719124268566bae.js
main.99a2fef672c5dea80432.js
main.9cc0a9e581787e5895b3.js
main.a31a3f8d1597967b0338.js
main.a38cf59c4975a3a63c18.js
main.a92d1e7344701f254b79.js
main.b2847a27934929a16d7b.js
main.b3fa86d823d93101ccd0.js
main.bundle.js
main.bundle.js.map
main.c0867a6d240c6b08186a.js
main.c3fbea838bf0c8c3a585.js
main.c58268422164f8ea7c18.js
main.c6c2abfec57e7409bb0c.js
main.c75ad24d42f4eefdf57a.bundle.js
main.d369ed41830a81d4152c.js
main.d8f86272f56ca78aa274.js
main.e9f18179a7cdc2e9fc32.bundle.js
main.ebeb2f7dceb0235f984a.js
main.ed04b53209ad67c8f868.js
main.fb9757f21a35e2d1f712.js
package-lock.json
package.json
polyfills.4c4977c7d0485f1a615c.js
polyfills.7f9d473f1d5c840b0bca.js
polyfills.b6b2cd0d4c472ac3ac12.bundle.js
polyfills.bundle.js
polyfills.bundle.js.map
protractor.conf.js
runtime.a66f828dca56eeb90e02.js
styles.011fbe93f5aa02ab899c.css
styles.1c1e1a3f0f964f4480c8.css
styles.20ca9953539e160095d7.css
styles.2649b7718ed7060584ee.bundle.css
styles.795c64eb81ee95abd882.css
styles.7cc4f3f2526cd25e41f1.css
styles.8f0fffdf37786dd0c891.css
styles.9834adb82a81ee260143.bundle.css
styles.abc647452f0f121b64df.css
styles.bundle.js
styles.bundle.js.map
styles.faf0d259a51ec1b90453.css
tsconfig.json
tslint.json
vendor.bundle.js
vendor.bundle.js.map

README.md

OpenSocialSecurity

This project was generated with Angular CLI version 1.7.4.

What Does This Calculator Do?

Firstly, please know that everything is done in "real" (i.e., inflation-adjusted) dollars. So there is no need for the user to make manual inflation adjustments.

Let's consider the simplest example: an unmarried person, using the calculator prior to age 62.

For such a person, the calculator:

  1. First assumes they file ASAP at 62.
  2. Calculates the amount of their monthly retirement benefit under such assumption.
  3. For each year up to age 115, the calculator multiplies the annual retirement benefit by the user's probability of being alive in such year, to arrive at a probability-weighted annual benefit.
  4. That probability-weighted benefit is then discounted back to age-62 value using the discount rate the user provided as input (i.e., to account for the fact that a dollar today can be invested and is therefore worth more than even an inflation-adjusted dollar in the future).
  5. All of those probability-weighted, discounted benefit amounts are summed, to arrive at a total "present value" for the assumed claiming strategy (e.g., claiming ASAP at 62).
  6. The above process is repeated for each possible claiming age (i.e., every month between 62 and 70).
  7. The claiming age that had the highest present value is then suggested to the user, and the present value associated with such claiming age is provided as well.

If the person is older than 62 when using the calculator, claiming strategies that are no longer possible (i.e., filing in the past) are eliminated from the analysis.

For a married couple, it's the same sort of process, but with more going on. Specifically:

  1. In addition to retirement benefits, spousal benefits and survivor benefits are included in the analysis.
  2. Probability weighting the various benefits each period involves separate calculations for "probability only Spouse A is alive", "probability only Spouse B is alive", and "probability both spouses are still alive."
  3. Each combination of possible claiming ages must be considered, for both spouses, and for both types of benefits (i.e., retirement and spousal).

Flow of Information

When a user clicks the "submit" button, the "onsubmit" method from home.component.ts is triggered. This is the "parent" function in which the whole process happens.

First, we use the findSSbirthDate and findFRA functions from birthday.service.ts to find the user(s) Social Security birthdate, full retirement age, and full retirement age for the sake of survivor benefits.

Then, either maximizeSinglePersonPV, maximizeCouplePV, or maximizeDivorceePV functions are called from presentvalue.service.ts, depending on the user's marital status.

The "maximizePV" functions call either calculateSinglePersonPV or calculateCouplePV for each possible claiming age (or set of claiming ages) to find that claiming age's present value. In the process of doing this step, the various functions from benefit.service.ts are called in order to calculate applicable monthly benefit amounts.

Then the claiming age (or set of claiming ages) with the highest PV is returned to the user, as well as the corresponding PV.