ssa-gov/www.ssa.gov/OACT/anypia/source.html

522 lines
32 KiB
HTML

<!doctype html>
<html class="no-js" lang="en">
<head>
<!-- REQUIRED META INFORMATION -->
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
<meta name="viewport" content="width=device-width,initial-scale=1" />
<!-- DOCUMENT TITLE -->
<!-- #BeginEditable name="doctitle" --><title> Social Security Benefit Calculator Source Code </title><!-- #EndEditable -->
<!-- OCACT META INFORMATION -->
<!-- #BeginEditable name="metatags" -->
<meta name="dc.creator" content="OACT">
<meta name="lead_content_manager" content="OCACT Webmaster">
<meta name="coder" content="DavidOlson">
<meta name="dc.description" content="Benefit Calculators">
<meta name="dc.title" content="Estimate Your Benefit">
<meta name="keywords" content="benefit calculators, social security">
<!-- #EndEditable -->
<!-- OCOMM STYLES & SCRIPTS -->
<link href="/framework/css/style.css" type="text/css" rel="stylesheet" media="all" />
<!-- OACT STYLES -->
<link href="../templatefiles/ocact.css" type="text/css" rel="stylesheet" media="all" />
<!-- SSA INTERNET HEAD SCRIPTS -->
<script src="/framework/js/ssa.internet.head.js"></script>
<script>(window.BOOMR_mq=window.BOOMR_mq||[]).push(["addVar",{"rua.upush":"false","rua.cpush":"false","rua.upre":"false","rua.cpre":"false","rua.uprl":"false","rua.cprl":"false","rua.cprf":"false","rua.trans":"","rua.cook":"false","rua.ims":"false","rua.ufprl":"false","rua.cfprl":"false","rua.isuxp":"false","rua.texp":"norulematch","rua.ceh":"false","rua.ueh":"false","rua.ieh.st":"0"}]);</script>
<script>!function(e){var n="https://s.go-mpulse.net/boomerang/";if("False"=="True")e.BOOMR_config=e.BOOMR_config||{},e.BOOMR_config.PageParams=e.BOOMR_config.PageParams||{},e.BOOMR_config.PageParams.pci=!0,n="https://s2.go-mpulse.net/boomerang/";if(window.BOOMR_API_key="LERZW-HECFS-R8H4E-23UQ7-ERMQB",function(){function e(){if(!o){var e=document.createElement("script");e.id="boomr-scr-as",e.src=window.BOOMR.url,e.async=!0,i.parentNode.appendChild(e),o=!0}}function t(e){o=!0;var n,t,a,r,d=document,O=window;if(window.BOOMR.snippetMethod=e?"if":"i",t=function(e,n){var t=d.createElement("script");t.id=n||"boomr-if-as",t.src=window.BOOMR.url,BOOMR_lstart=(new Date).getTime(),e=e||d.body,e.appendChild(t)},!window.addEventListener&&window.attachEvent&&navigator.userAgent.match(/MSIE [67]\./))return window.BOOMR.snippetMethod="s",void t(i.parentNode,"boomr-async");a=document.createElement("IFRAME"),a.src="about:blank",a.title="",a.role="presentation",a.loading="eager",r=(a.frameElement||a).style,r.width=0,r.height=0,r.border=0,r.display="none",i.parentNode.appendChild(a);try{O=a.contentWindow,d=O.document.open()}catch(_){n=document.domain,a.src="javascript:var d=document.open();d.domain='"+n+"';void(0);",O=a.contentWindow,d=O.document.open()}if(n)d._boomrl=function(){this.domain=n,t()},d.write("<bo"+"dy onload='document._boomrl();'>");else if(O._boomrl=function(){t()},O.addEventListener)O.addEventListener("load",O._boomrl,!1);else if(O.attachEvent)O.attachEvent("onload",O._boomrl);d.close()}function a(e){window.BOOMR_onload=e&&e.timeStamp||(new Date).getTime()}if(!window.BOOMR||!window.BOOMR.version&&!window.BOOMR.snippetExecuted){window.BOOMR=window.BOOMR||{},window.BOOMR.snippetStart=(new Date).getTime(),window.BOOMR.snippetExecuted=!0,window.BOOMR.snippetVersion=12,window.BOOMR.url=n+"LERZW-HECFS-R8H4E-23UQ7-ERMQB";var i=document.currentScript||document.getElementsByTagName("script")[0],o=!1,r=document.createElement("link");if(r.relList&&"function"==typeof r.relList.supports&&r.relList.supports("preload")&&"as"in r)window.BOOMR.snippetMethod="p",r.href=window.BOOMR.url,r.rel="preload",r.as="script",r.addEventListener("load",e),r.addEventListener("error",function(){t(!0)}),setTimeout(function(){if(!o)t(!0)},3e3),BOOMR_lstart=(new Date).getTime(),i.parentNode.appendChild(r);else t(!1);if(window.addEventListener)window.addEventListener("load",a,!1);else if(window.attachEvent)window.attachEvent("onload",a)}}(),"".length>0)if(e&&"performance"in e&&e.performance&&"function"==typeof e.performance.setResourceTimingBufferSize)e.performance.setResourceTimingBufferSize();!function(){if(BOOMR=e.BOOMR||{},BOOMR.plugins=BOOMR.plugins||{},!BOOMR.plugins.AK){var n=""=="true"?1:0,t="",a="vht6pfix22vgcz6v47jq-f-014e74e59-clientnsv4-s.akamaihd.net",i="false"=="true"?2:1,o={"ak.v":"39","ak.cp":"1204614","ak.ai":parseInt("728289",10),"ak.ol":"0","ak.cr":3,"ak.ipv":4,"ak.proto":"http/1.1","ak.rid":"31292be","ak.r":35636,"ak.a2":n,"ak.m":"dsca","ak.n":"essl","ak.bpcip":"169.231.231.0","ak.cport":43778,"ak.gh":"23.214.170.93","ak.quicv":"","ak.tlsv":"tls1.3","ak.0rtt":"","ak.0rtt.ed":"","ak.csrc":"-","ak.acc":"bbr","ak.t":"1742071763","ak.ak":"hOBiQwZUYzCg5VSAfCLimQ==pHVJol8P5DjWjJokCV1wTWJOEEQeqZKwuygM8Zz4Ee5DaL6h3gx0hVj6gmPRovBv27WIgplD/chgCEZBzNrzgYLSrZ0h//2C/+1ZYm1GZVysb1LmKZSaPp10wl/KgTQmEhYgp+Jv1y9sJhq+YajKq6Ha0Hi119Rmru9jW9SgJPfLPAYeFnlJRG45RgK/b5OhtLnFpu6Yi7Vl/tjbC+8eBRXv8+7nm5vDf+gU82w9mJ+h7miE4DvpuFRnpWnaXPFJf8sgBgoH2xGTxYApah1bGmKlEDYAmPr8LEsuX/FVAG9RHULGP3E6+r6LM/5VsUKCGbKaDEHydQgs9ulVXh/4L+Q+v5jHvMKviJivKPkbCPONrKY+SZ6a5LUxG1POoX6uRwkN1Yad3wznWgaBIP1A1LOk4SXewh7u9/+ZUChs+U8=","ak.pv":"98","ak.dpoabenc":"","ak.tf":i};if(""!==t)o["ak.ruds"]=t;var r={i:!1,av:function(n){var t="http.initiator";if(n&&(!n[t]||"spa_hard"===n[t]))o["ak.feo"]=void 0!==e.aFeoApplied?1:0,BOOMR.addVar(o)},rv:function(){var e=["ak.bpcip","ak.cport","ak.cr","ak.csrc","ak.gh","ak.ipv","ak.m","ak.n","ak.ol","ak.proto","ak.quicv","ak.tlsv","ak.0rtt","ak.0rtt.ed","ak.r","ak.acc","ak.t","ak.tf"];BOOMR.removeVar(e)}};BOOMR.plugins.AK={akVars:o,akDNSPreFetchDomain:a,init:function(){if(!r.i){var e=BOOMR.subscribe;e("before_beacon",r.av,null,null),e("onbeacon",r.rv,null,null),r.i=!0}return this},is_complete:function(){return!0}}}}()}(window);</script></head>
<body class="oact-sidebar-rows ">
<!-- PAGE CONTAINER -->
<div id="page">
<!-- PAGE HEADER -->
<div class="bg-dark-gray accessibility" id="accessibility"><a id="skip-navigation" href="#content">Skip to main content</a></div><ssa-header class="print-hide"><noscript><header class="banner-neo" id="banner" role="banner" style="background-color: #0b4778;"><div class="banner-wrapper"><h1 class="banner-logo"><a class="banner-logo__link" href="/">Social Security</a></h1><nav class="banner-nav" id="banner-nav"><a class="banner-nav__link banner-search" href="https://search.ssa.gov/search?affiliate=ssa" title="Search" target="_blank"><svg class="banner-nav__icon" focusable="false" width="24" height="24" viewbox="0 0 24 24"><path d="M 10 23 C 11.219 23 12.384 22.762 13.496 22.285 C 14.608 21.808 15.565 21.169 16.367 20.367 C 17.169 19.565 17.808 18.608 18.285 17.496 C 18.762 16.384 19 15.219 19 14 C 19 12.953 18.829 11.951 18.488 10.992 C 18.147 10.033 17.661 9.164 17.031 8.383 L 22.711 2.711 C 22.904 2.518 23 2.281 23 2 C 23 1.713 22.905 1.475 22.715 1.285 C 22.525 1.095 22.287 1 22 1 C 21.719 1 21.482 1.096 21.289 1.289 L 15.617 6.969 C 14.836 6.339 13.966 5.853 13.008 5.512 C 12.05 5.171 11.047 5 10 5 C 8.781 5 7.616 5.238 6.504 5.715 C 5.392 6.192 4.435 6.831 3.633 7.633 C 2.831 8.435 2.192 9.392 1.715 10.504 C 1.238 11.616 1 12.781 1 14 C 1 15.219 1.238 16.384 1.715 17.496 C 2.192 18.608 2.831 19.565 3.633 20.367 C 4.435 21.169 5.392 21.808 6.504 22.285 C 7.616 22.762 8.781 23 10 23 Z M 10 21 C 9.052 21 8.146 20.815 7.281 20.445 C 6.416 20.075 5.672 19.578 5.047 18.953 C 4.422 18.328 3.925 17.584 3.555 16.719 C 3.185 15.854 3 14.948 3 14 C 3 13.052 3.185 12.146 3.555 11.281 C 3.925 10.416 4.422 9.672 5.047 9.047 C 5.672 8.422 6.416 7.925 7.281 7.555 C 8.146 7.185 9.052 7 10 7 C 10.948 7 11.854 7.185 12.719 7.555 C 13.584 7.925 14.328 8.422 14.953 9.047 C 15.578 9.672 16.075 10.416 16.445 11.281 C 16.815 12.146 17 13.052 17 14 C 17 14.948 16.815 15.854 16.445 16.719 C 16.075 17.584 15.578 18.328 14.953 18.953 C 14.328 19.578 13.584 20.075 12.719 20.445 C 11.854 20.815 10.948 21 10 21 Z" transform="matrix(-1, 0, 0, -1, 24.000001, 24.000001)" vector-effect="non-scaling-stroke"></path></svg> <span>Search</span> </a><a class="banner-nav__link banner-menu" href="/menu" id="ssa-menu" title="Menu"><svg class="banner-nav__icon" focusable="false" width="24" height="24" viewbox="0 0 24 24"><path d="M3 5h18q.414 0 .707.293T22 6t-.293.707T21 7H3q-.414 0-.707-.293T2 6t.293-.707T3 5zm0 12h18q.414 0 .707.293T22 18t-.293.707T21 19H3q-.414 0-.707-.293T2 18t.293-.707T3 17zm0-6h18q.414 0 .707.293T22 12t-.293.707T21 13H3q-.414 0-.707-.293T2 12t.293-.707T3 11z" vector-effect="non-scaling-stroke"></path></svg> <span>Menu</span> </a><a class="banner-nav__link banner-languages" href="/es" id="ssa-languages" title="Español" hreflang="es"><svg class="banner-nav__icon" focusable="false" width="24" height="24" viewbox="0 0 24 24"><path d="M12 0C5.373 0 0 5.373 0 12s5.373 12 12 12c.812 0 1.604-.08 2.37-.235-.31-.147-.343-1.255-.037-1.887.34-.703 1.406-2.485.35-3.08-1.053-.6-.76-.868-1.405-1.56-.644-.692-.38-.796-.422-.974-.14-.61.62-1.523.656-1.616.035-.094.035-.446.023-.55-.012-.107-.48-.387-.597-.4-.117-.01-.176.188-.34.2-.164.012-.88-.433-1.03-.55-.154-.117-.224-.398-.435-.61-.21-.212-.235-.047-.562-.175-.327-.13-1.382-.516-2.19-.844-.81-.33-.88-.79-.892-1.114-.012-.325-.492-.797-.718-1.137-.225-.342-.267-.81-.348-.705-.082.106.422 1.336.34 1.37-.083.037-.26-.338-.493-.643-.235-.304.245-.14-.505-1.617-.75-1.476.235-2.23.282-3 .048-.77.633.28.328-.21-.304-.493.023-1.524-.21-1.9-.235-.374-1.57.423-1.57.423.034-.363 1.17-.985 1.99-1.56.82-.573 1.322-.128 1.982.083.66.21.703.142.48-.07-.222-.21.094-.316.61-.235.516.082.656.704 1.442.645.784-.06.08.152.186.35.105.2-.117.177-.633.53-.516.35.012.35.926 1.02.913.667.632-.447.538-.94-.094-.49.668-.105.668-.105.563.375.46.02.87.15.408.13 1.52 1.07 1.52 1.07-1.395.762-.516.844-.282 1.02.235.175-.48.515-.48.515-.294-.293-.34.012-.528.117-.187.105-.012.375-.012.375-.97.153-.75 1.173-.738 1.418.012.247-.62.622-.786.973-.164.35.423 1.113.117 1.16-.305.048-.61-1.148-2.25-.703-.495.134-1.593.703-1.008 1.863.585 1.16 1.558-.328 1.886-.164.33.163-.093.902-.023.913.07.012.927.033.974 1.032.048 1 1.3.914 1.57.938.27.023 1.173-.74 1.3-.774.13-.035.646-.47 1.77.175 1.126.644 1.7.55 2.086.82.387.27.117.81.48.985.365.176 1.818-.058 2.18.54.364.597-1.5 3.597-2.085 3.925-.586.328-.856 1.078-1.442 1.558-.69.563-1.418 1.076-2.18 1.535-.684.407-.807 1.137-1.112 1.367C19.984 22.52 24 17.73 24 12c0-6.627-5.373-12-12-12zm2.813 11.262c-.165.047-.504.352-1.336-.14-.832-.494-1.406-.4-1.477-.48 0 0-.07-.2.293-.236.747-.072 1.688.692 1.9.704.21.012.315-.21.69-.09.375.12.094.195-.07.242zM10.887 1.196c-.082-.06.068-.128.157-.246.05-.07.013-.182.078-.246.175-.177 1.043-.423.874.058-.17.48-.98.527-1.11.434zm2.098 1.523c-.293-.013-.983-.086-.856-.212.494-.492-.188-.633-.61-.668-.423-.036-.598-.27-.388-.294.21-.024 1.055.013 1.196.13.14.117.902.422.95.644.047.223 0 .41-.293.4zm2.542-.083c-.234.188-1.413-.673-1.64-.867-.985-.844-1.513-.563-1.72-.703-.206-.142-.132-.33.184-.61.318-.282 1.21.094 1.724.152.516.058 1.113.457 1.125.93.01.474.562.91.327 1.097z" vector-effect="non-scaling-stroke"></path></svg> <span>Español</span> </a><a class="banner-nav__link banner-signin" href="https://secure.ssa.gov/RIL/SiView.action" id="ssa-signin" title="Sign in" target="_blank"><svg class="banner-nav__icon" focusable="false" width="24" height="24" viewbox="0 0 24 24"><path d="M12 17.016q-.797 0-1.406-.61t-.61-1.405.61-1.405 1.406-.61 1.406.61.61 1.406-.61 1.407-1.406.61zm6 3V9.986H6v10.03h12zm-6-17.11q-1.266 0-2.18.914T8.906 6H9v2.016h6.094V6q0-1.266-.914-2.18T12 2.906zm6 5.11q.797 0 1.406.586t.61 1.383v10.03q0 .798-.61 1.384T18 21.984H6q-.797 0-1.406-.586t-.61-1.384V9.986q0-.798.61-1.384T6 8.016h.984V6q0-2.063 1.477-3.54T12 .985t3.54 1.477T17.015 6v2.016H18z" vector-effect="non-scaling-stroke"></path></svg> <span>Sign in</span></a></nav></div></header></noscript></ssa-header><script src="https://www.ssa.gov/legacy/components/dist/ssa-header.js"></script>
<!-- PAGE NAVIGATION -->
<!-- DEPRECATED -->
<!-- PAGE TITLE -->
<div id="title-bar">
<!-- #BeginEditable name="pagetitle" --><h2></h2><!-- #EndEditable -->
</div>
<!-- PAGE CONTENT -->
<div id="content" role="main">
<!-- GRID SYSTEM -->
<div class="row-12 equal-heights">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p><a href="../index.html">Office of the Chief Actuary</a></p>
<p><a href="./anypia.html">Detailed Calculator Home</a></p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<h1> Social Security Benefit Calculator Source Code </h1>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom border-top">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left ">
<p class="bold">Versions of the program</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9" >
<div class="pad-top">
<p>There are two versions of the Social Security Benefit Calculator: one for Windows
and one for the MacOS. The
version for Windows is compiled using the Microsoft Visual C/C++ compiler
(2022 version). The version for the MacOS is compiled using the Metrowerks
CodeWarrior compiler (version 9.0)</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image" >
<div class="pad-top pad-left ">
<p class="bold">Source code for the calculator</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p>The source code that does the actual benefit calculations is stored in
subdirectories <b>oactobjs</b> (for the MacOS) and <b>oactobjs32</b> (for
Windows). In addition there are extra files in each subdirectory saved by the
compiler to help the compiler build the libraries; those files differ from
Windows to MacOS.</p>
<p>The source code for the windowing part of the program is stored
in subdirectories <b>anypiamacprojOSX</b> (for the MacOS) and
<b>anypia32</b> (for Windows). There is also a subdirectory
<b>anypiab</b> with source code to make a console application;
it uses the Windows calculation code. (See
<a href="./anypiab.html">Batch Version of the Calculator</a> for
more details.)</p>
<p>You can download the MacOS calculation and windowing code
(subdirectories <b>oactobjs</b> and <b>anypiamacOSXproj</b>),
and/or the Windows calculation and windowing code (subdirectories
<b>oactobjs32</b>, <b>anypia32</b>, and <b>anypiab</b>). The
code for the MacOS is available as .sitx archives. The
Windows code is available as self-extracting zipped files
(executable on a Windows machine) or as plain zip files (which can
be expanded on any operating system with unzip capabilities).</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">Downloading Windows source code</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p>To download the Windows code, click one item from each of the following rows:</p>
<table summary="Windows source code download" class="border">
<tbody>
<tr>
<th>
<p>Source files</p>
</th>
<th>
<p>Self-extracting zip file</p>
</th>
<th>
<p>Plain zip file</p>
</th>
</tr>
<tr>
<td><p>oactobjs32</p>
</td>
<td><p><A href="./download/oactobjs32.exe" download>oactobjs32.exe</A>
(834,048 bytes)</p>
</td>
<td><p><A href="./download/oactobjs32.zip" download>oactobjs32.zip</A>
(644,977 bytes)</p>
</td>
</tr>
<tr>
<td><p>anypia32 and anypiab</p>
</td>
<td><p><A href="./download/source32.exe" download>source32.exe</A>
(339,456 bytes)</p>
</td>
<td><p><A href="./download/source32.zip" download>source32.zip</A>
(150,147 bytes)</p>
</td>
</tr>
</tbody>
</table>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">Downloading MacOS source code</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p>To download the MacOS code, click on each of the following items:</p>
<table summary="MacOS source code download" class="border">
<tbody>
<tr>
<th>
<p>Source files</p>
</th>
<th>
<p>Archive file (.sitx)</p>
</th>
</tr>
<tr>
<td><p>oactobjs</p>
</td>
<td><p><A href="./download/oactobjs.sitx" download>oactobjs.sitx</A>
(260,645 bytes)</p>
</td>
</tr>
<tr>
<td><p>anypiamacproj</p>
</td>
<td><p><A href="./download/anypiamacprojOSX.sitx" download>anypiamacprojOSX.sitx</A>
(159,969 bytes)</p>
</td>
</tr>
</tbody>
</table>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">The Boost Libraries</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p>In the 2006.2 and later versions of the code, we use the Boost libraries, which are a
set of free open-source libraries that perform common functions not included
in the C++ Standard Library. In order to use our source code, you will have
to download and install the libraries from
<a href="http://www.boost.org/">www.boost.org</a>.
That website has instructions on how to install the libraries on your computer.
The Windows code uses the 1.81.0 version of the Boost libraries, and the
Mac version uses 1.33.1.</p>
<p>In your C++ projects for each of the libraries in our source code and the
main program project, you must put an include path to the base of your Boost
install directory. Here's where we have boost installed in the ready-made
projects we include with our source code:
On a Windows machine, the libraries are in a subdirectory
of oactobjs32 named "boost_1_81_0". On a Mac, the libraries are in
a directory parallel to oactobjs and anypiamacprojOSX named "boost_1_33_1".
Once this is done, you can use our projects to build the program.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">The oactobjs directory (for MacOS)</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p><b>oactobjs</b> contains 183 include files (ending in .h) and
four subdirectories with library source code. The first subdirectory, <b>miscproj</b>,
contains 38 files (ending in .cpp) for classes that are not tied specifically
to Social Security benefit calculations. The second subdirectory, <b>piadataproj</b>,
contains 149 files (ending in .cpp) for classes involving benefit calculations.
The third subdirectory, <b>piaoutproj</b>, contains 38 include files (ending in
.h) and 38 files (ending in .cpp) for classes involving printing out the
results of a benefit calculation. The fourth subdirectory, <b>mac</b>,
contains six header files (ending in .h) and one file (ending in .cpp)
for functions which are not available in MacOS, or that differ from similar
functions on other operating systems. The code in all four subdirectories has only
been tested with the Metrowerks compiler within the MacOS environment.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">The oactobjs32 directory (for Windows)</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p><b>oactobjs32</b> contains five subdirectories with library source
code. The first subdirectory, <b>windows</b>, contains 15 include
files (ending in .h), 6 C files (ending in .c) and 4 C++ files (ending in
.cpp) for functions that are not available with the Windows
operating system, or that differ from similar functions on other
operating systems. The second subdirectory, <b>misc</b>,
contains 31 files (ending in .cpp) for classes that are not tied
specifically to Social Security benefit calculations. The third
subdirectory, <b>piadata</b>, contains 152 files (ending in
.cpp) for classes involving benefit calculations. The fourth
subdirectory, <b>piaout</b>, contains 40 include files (ending
in .h) and 40 files (ending in .cpp) for classes involving
printing out the results of a benefit calculation. The fifth
subdirectory, <b>include</b>, contains 182 header files
(ending in .h). In addition, each subdirectory except include
contains a solution file (ending in .sln) and
a project file (ending in .vcxproj) that work with the Microsoft
compiler, 2022 version, to create each library. However, the
code in the three subdirectories other than <b>windows</b> has
been compiled in the past on the Linux operating system using the
Gnu C++ compiler, where the subdirectory <b>linux</b> takes the place
of the subdirectory <b>windows</b>.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image" >
<div class="pad-top pad-left">
<p class="bold">The anypiamacprojOSX directory</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p><b>anypiamacprojOSX</b> contains five subdirectories: one with the user interface
code for the MacOS version of the benefit calculation program, one with
resource files, one with information for prebuilding include files, one for target
information, and one for output. The subdirectory named <b>Source</b> contains 33 include files
(ending in .h), 31 files with class functions (ending in .cp or .cpp), and 1 file
with utility functions (ending in .c). The subdirectory named <b>Resources</b> contains
10 files for icons and visual layout information. The subdirectory named <b>Prefix</b>
contains 3 files for prebuilding include files. The directory <b>anypiamacData</b> is
empty, but will contain target information after the project has been opened in CodeWarrior.
The directory <b>Output</b> will contain the executable file when the program is built.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">The anypiab directory</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p><b>anypiab</b> contains the necessary files to make a console
application (command prompt executable) that reads either one file with
multiple cases or multiple individual data files and calculates
the benefit for each case (see <a href="./anypiab.html">Batch
Version of the Calculator</a>). There are 3 include files
(ending in .h), 3 files with C++ code (ending in .cpp), a
solution file (anypiab.sln) and a project file (anypiab.vcxproj)
for compiling with the Microsoft compiler, 2022 version, and two
illustrative data files (anypiab.pia and anypiac.dat). The
solution references three libraries in the <b>oactobjs32</b>
directory (<b>windows</b>, <b>misc</b>, and <b>piadata</b>), so
those libraries need to be made before compiling the files in
this subdirectory. There is a macro named DETAILS which can be
defined to allow <b>anypiab</b> to produce detailed output. If
it is defined, the fourth library (<b>piaout</b>) must also be
made before compiling the files in this subdirectory. The
<b>anypiab</b> program has been compiled on other operating
systems, including Linux using the Gnu C++ compiler with the
<b>linux</b> library replacing the <b>windows</b> library.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">The anypia32 directory</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p><b>anypia32</b> contains the user interface code for the Windows
version of the Calculator and one subdirectory with resource
files. There are 40 include files (ending in .h), 39 files with
class functions (ending in .cpp), a resource file (anypia32.rc),
a solution file (anypia32.sln), a project file
(anypia32.vcxproj), and a help macro file (resource.hm). The
subdirectory <b>res</b> contains 4 files for icons and bitmaps.
The solution references the four libraries in the
<b>oactobjs32</b> subdirectory and the Boost libraries, so those
libraries need to be made before compiling the files in this
subdirectory.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">Compilers</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p>The source code, as distributed, may not compile correctly with compilers
other than those mentioned above. The author will provide limited assistance to
anyone trying to recompile the program with another compiler or in another
operating system.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">Documentation</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p>We provide descriptions of the functions available in the
<b>oactobjs32</b> libraries in a compiled help file for Windows and a set of
HTML files in a sitx archive for Mac OSX.
To download the documentation, click the following item:</p>
<table summary="oactobjs documentation download" class="border">
<tbody>
<tr>
<th>
<p>Source documentation</p>
</th>
<th>
<p>Compiled HTML file (Windows)</p>
</th>
<th>
<p>Archive file (Mac)</p>
</th>
</tr>
<tr>
<td><p>oactobjs</p>
</td>
<td><p><A href="./download/oactobjsdoc.chm" download>oactobjsdoc.chm</A>
(6,129,334 bytes)</p>
</td>
<td><p><A href="./download/oactobjsdoc.sitx" download>oactobjsdoc.sitx</A>
(2,037,626 bytes)</p>
</td>
</tr>
</tbody>
</table>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">Creating a program with changes from present law</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9" >
<div class="pad-top">
<p>A version of the interactive or console program that can handle some changes
from present law can be created by using the LawChangeArray created on line 69
of anypiabdoc.cpp (for the console version) or line 195 of AnypiaDoc.cpp (for
the Windows interactive version). Note, however, that only some of the 40 listed
changes from present law have actually been implemented. Also note that there
is not yet any user interface code to handle the indicators for changes from
present law.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image " >
<div class="pad-top pad-left">
<p class="bold">Program in Fortran</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p>We also have a Social Security benefit estimate program in Fortran,
the operation of which is similar to that of the C++ version. The Fortran
source code is structured similarly to the C++ version, but has not been
updated for some years. The source code for the program, or the program
compiled for MS-DOS, is available in a self-extracting zipped file
<a href="./download/sourcef.exe" download>sourcef.exe</a>
(384,000 bytes), or in a plain zipped file,
<a href="./download/sourcef.zip" download>sourcef.zip</a>
(358,085 bytes).</p>
<p>The program compiles in Windows 98 or NT, using Compaq Fortran. There are also
separate files of subroutines enabling the program to compile on a Unix system
or on an IBM mainframe. However, the compiled program does not have some of the
screen-handling capabilities of the C++ version; therefore we distribute the
C++ version, rather than the Fortran version, as the Calculator.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
<div class="row-12 equal-heights border-bottom">
<div class="column-3 no-bg-image ">
<div class="pad-top pad-left">
<p class="bold">Questions or comments</p>
</div>
</div><!-- end .column-3 -->
<div class="column-9 " >
<div class="pad-top">
<p>If you have questions or comments about the Detailed Calculator, please visit our
<a href="https://www.ssa.gov/agency/contact">Contact Social Security</a>
page for ways to contact us. Remember to use "Detailed Calculator" as the subject
so we know which calculator your question or comment refers to.</p>
</div>
</div><!-- end .column-9 -->
</div><!-- end .row-12 -->
</div><!-- end #content -->
<!-- PAGE FOOTER -->
<ssa-footer class="print-hide"><noscript><footer class="footer" id="footer" role="contentinfo"><a href="/menu#footer">Footer menu</a></footer></noscript></ssa-footer><script src="https://www.ssa.gov/legacy/components/dist/ssa-footer.js"></script>
</div><!-- end #page -->
<!-- OCOMM BODY CONTENT -->
<!-- SSA INTERNET BODY SCRIPTS -->
<script src="/framework/js/ssa.internet.body.js"></script>
</body>
</html>