home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 9 / 09.iso / e / e060 / 7.ddi / TUTOR / FINANCE.RSS < prev    next >
Encoding:
Text File  |  1986-04-26  |  8.8 KB  |  323 lines

  1. /*  FINANCE.RSS        This rule set determines how much money    an    */
  2. /*            investment client should invest in various    */
  3. /*            investments.  This rule set also checks various    */
  4. /*            aspects of an individuals financial picture     */
  5. /*            against normal averages and provides certain     */
  6. /*            advice.                        */
  7.  
  8. INITIAL:
  9.     clear
  10.     if not inuse("investor")    /* User is not performing FINANCE */
  11.         e.lstr=60
  12.         at 12,20 ?"This rule set can only be consulted"
  13.         at 14,23 ?"from within the demo program."
  14.         bchn=true
  15.         sleep(2)
  16.         e.serr=true
  17.     else
  18.         at 5,20 ?"Beginning financial analysis for client:"
  19.         at 8,30 ?investor.fname,investor.lname,
  20.         perform getinfo
  21.         calc compute
  22.         nothing = unknown
  23.         complt    = unknown
  24.         fchn = false
  25.         e.rigr = "a"
  26.         if (currec(investor) ne 0) then
  27.             tage    = investor.age
  28.             tmstat    = investor.mstat
  29.         endif
  30.     endif
  31.  
  32. GOAL:    bchn
  33.  
  34. DO:    if inuse("investor")
  35.         wtcl
  36.     else
  37.         e.serr = false
  38.         clear
  39.     endif
  40.  
  41. RULE:    R0
  42.     IF:    true
  43.     THEN:    bchn = true
  44.     COMMENT:This rule set is not set up for back chaining
  45.         It should be consulted with forward chaining
  46.  
  47. RULE:    R1
  48.     IF:    #n24 > (0.13 * #e34)/12
  49.     THEN:   wtclear
  50.         ?"    If your current interest rate exceeds 13%, then you can probably"
  51.         ?"    benefit from refinancing your mortgage  to  a  more  competitive"
  52.         ?"    rate.  Current rates are close to 9.5%."
  53.     CHANGES:nothing
  54.     REASON: If the current mortgage interest rate exceeds 13%,
  55.         you can probably benefit from refinancing to the
  56.         current rates of arount 9.5 percent
  57.     COMMENT: Check for unacceptable interest rates
  58.  
  59. RULE:    R2
  60.     IF:    #e14 < 2000
  61.     THEN:    wtclear
  62.         ?"    You have IRA savings of less than $2000.  This is  clearly  not"
  63.         ?"    using IRAs to the extent possible.  Money should be put into an"
  64.         ?"    IRA, generally even if one has to borrow to do so."
  65.     CHANGES:nothing
  66.     REASON: If you have iras less than 2000, then you are clearly not
  67.         using iras to the extent possible.
  68.     COMMENT: Might even want to check for iras < 4000
  69.  
  70. RULE:    R3
  71.     IF:    tage > 35 and #e14 < (tage-32) * 2000 * iraeligible
  72.     THEN:    wtclear
  73.         ?"    Generally, people over 35 years of age have reached a  point"
  74.         ?"    where they can afford to put money into IRA's.  Your balance"
  75.         ?"    sheet indicates that you  have not been putting the maximum"
  76.         ?"    amount allowed into your IRA"
  77.     CHANGES:nothing
  78.     REASON:    If you are under 35, you have an excuse.  However if you
  79.         are over 35, you really should have been stashing away
  80.         those IRA funds for several years.
  81.  
  82. RULE:     R4
  83.     IF:    tmstat = "M"
  84.     THEN:    iranum = 2 ; iraeligible = Max(2000, #n5) + Max(2000, #n6)
  85.     NEEDS:    tmstat,#n5
  86.     CHANGES: iranum
  87.     REASON:    If you are married, you are eligible for two IRA deductions.
  88.  
  89. RULE:    R5
  90.     IF:    tmstat ne "M"
  91.     THEN:    iranum = 1 ; iraeligible = Max(2000, #n5) + 250
  92.     NEEDS:    tmstat,#n5
  93.     REASON: If you are not married, you are only eligible for one
  94.         ira deduction and an additional $250 for the non-working
  95.         spouse.
  96.  
  97. RULE:    R6
  98.     IF:    tmstat = "S"
  99.     THEN:    wtclear
  100.         ?"    You are currently not married.  Getting married can save on your"
  101.         ?"    taxes.  (Your mother asked me to mention this...)"
  102.     CHANGES:nothing
  103.     REASON: You can save taxes by getting married.
  104.     COMMENT: Some people may not take this advice
  105.  
  106. RULE:    R7
  107.     IF:    housing > .28 * #o12
  108.     THEN:    wtclear
  109.         i = (housing/#o12 )*100
  110.         ?"    Your mortgage payments are equal to ",i using "ddd",\
  111.             "  percent of  your  total"
  112.         ?"    monthly income.  Experts generally agree that housing should not"
  113.         ?"    exceed 28 percent of your total income."
  114.     CHANGES:nothing
  115.     REASON:    The standard rule of thumb says that your housing costs 
  116.         should not exceed 28% of you gross monthly income.
  117.  
  118. RULE:    R8
  119.     IF:    #e14 > 0
  120.     THEN:    wtclear
  121.         ?"    You currently indicate some IRA savings.  Be sure that none of"
  122.         ?"    the IRA  investments  currently used have a tax exempt status." 
  123.         ?"    The market values of these instruments are higher  while  they"
  124.         ?"    have no advantage for a tax exempt fund such as the IRA.  They"
  125.         ?"    should not be part of an IRA portfolio."
  126.     CHANGES:nothing
  127.     REASON:    The market tends to price these investments higher 
  128.         because of the tax deferred status which holds no
  129.         appeal in an IRA.
  130.  
  131. RULE:    R10
  132.     IF:    #n25 > 0 or #n7 > 0    
  133.     THEN:    wtclear
  134.         ?"    One of the best and safest investments available is to pay off"
  135.         ?"    existing debts upon which substantial interest is being paid."
  136.     CHANGES:nothing
  137.     REASON:    One of the best investments you can make is to pay off
  138.         existing debts on which you might be paying substantial
  139.         interest, especially if you have money invested elsewhere
  140.         at a lesser interest rate than you are paying.
  141.  
  142. RULE:    R11
  143.     IF:    #m19 > 0.10 * #o12
  144.     THEN:    wtclear
  145.         i = (#m19/#o12)*100
  146.         ?"    Groceries for the normal family, should not exceed 10 percent of"
  147.         ?"    their income.  This family spends approximately ",i using "ddd",\
  148.             "  percent."
  149.     CHANGES:nothing
  150.     REASON: If your grocery bill exceeds 10% of your family income,
  151.         then you are spending an excessive portion of your income
  152.         on groceries
  153.  
  154. RULE:    R13
  155.     IF:    #o45 < targsav
  156.     THEN:    wtclear
  157.         lowsav = true;
  158.         ?"    Based on the financial statements on file, you should be saving"
  159.         ?"    ",targsav using "$dddddd"," per month, but your cash flow is "\
  160.             ,#o45 using "$dddddd","."
  161.     CHANGES: lowsav
  162.     REASON: If your net savings are less than your target savings,
  163.         then your savings are too low.
  164.     COMMENT: There might also be variation based upon net income
  165.  
  166. RULE:    R14
  167.     IF:    housing + #n25 + #n41 > .33 * #o12
  168.     THEN:    wtclear
  169.         totdebt = (housing + #n25 + #n41)/#o12 * 100
  170.         ?"    Your total debt and housing payments should not exceed 33 percent"
  171.         ?"    of your income.  Your debt level is currently ",totdebt using "dd"\
  172.             " percent."
  173.     NEEDS:    #n25, #n41, #o12, housing
  174.     CHANGES: totdebt
  175.     REASON:    The standard rule of thumb says that your total debt
  176.         and housing payments should not exceed 33% of you gross
  177.         monthly income.
  178.  
  179. RULE:    R18
  180.     IF:    mtax ge 38
  181.     THEN:   wtclear
  182.         i = mtax
  183.         ?"    You are in the  ",i using "dd",\
  184.             "  percent tax bracket.  Individuals in this"
  185.         ?"    bracket can realize quite good yields in after tax amounts by"
  186.         ?"    by investing tax exempt securities."
  187.     CHANGES:nothing
  188.     REASON:    If you are in a high tax brackets, you can benefit
  189.         from tax exempt securities.
  190.  
  191.  
  192. /********
  193. *
  194. * The Following Rules are used to establish the target savings level
  195. * for this investor.
  196. *
  197. ********/
  198.  
  199. RULE:    R30
  200.     IF:     tage < 22 
  201.     THEN:    targsav = 0
  202.     REASON:    If you are under 22 years of age, you are probably
  203.         using your money for college or just earning enough
  204.         to get by.  Your target    savings therefore are 0.
  205.  
  206. RULE:    R31
  207.     IF:     tage >= 22 and tage < 30 
  208.     THEN:    targsav = 0.05 * #o12
  209.     REASON:    If you are in your twenties and out of college you
  210.         should be saving at least 5% of your family net income,
  211.         otherwise your savings are too low.
  212.  
  213. RULE:    R32
  214.     IF:     tage >= 30 and tage < 40 
  215.     THEN:    targsav = 0.06 * #o12
  216.     REASON:    If you are in your thirties, you should be saving at
  217.         least 6% of your family net income, otherwise your
  218.         savings are too low.
  219.  
  220. RULE:    R33
  221.     IF:     tage >= 40 and tage < 50 
  222.     THEN:    targsav = 0.08 * #o12
  223.     REASON:    If you are in your fourties, you should be saving at least
  224.         8% of your family net income, otherwise your savings are 
  225.         too low.
  226.  
  227. RULE:    R34
  228.     IF:     tage >= 50 and tage < 65 
  229.     THEN:    targsav = 0.09 * #o12
  230.     REASON:    If you are in your fifties, you should be saving at least
  231.         9% of your family net income, otherwise your savings are 
  232.         too low.
  233.  
  234. RULE:    R35
  235.     IF:     tage >= 65 
  236.     THEN:    targsav = 0
  237.     REASON:    If you are retired, it is intended that you live off
  238.         your savings, hence target savings are 0
  239.  
  240.  
  241. /********
  242. *
  243. * The Following Rules are used to establish this investors marginal
  244. * tax bracket
  245. *
  246. ********/
  247.  
  248. RULE:    R50
  249.     IF:     investor.fstat eq "J"
  250.     THEN:    perform margtax using "joint"
  251.     CHANGES: mtax
  252.  
  253. RULE:    R51
  254.     IF:     investor.fstat eq "S"
  255.     THEN:    perform margtax using "single"
  256.     CHANGES: mtax
  257.  
  258. RULE:    R52
  259.     IF:     investor.fstat eq "I"
  260.     THEN:    perform margtax using "indiv"
  261.     CHANGES: mtax
  262.  
  263. RULE:    R53
  264.     IF:     investor.fstat eq "H"
  265.     THEN:    perform margtax using "headofh"
  266.     CHANGES: mtax
  267.  
  268.  
  269. VAR:    #e14
  270.     LABEL:    Amount currently invested in iras
  271.  
  272. VAR:    #n40
  273.     LABEL:    Current mortgage principle payments/period
  274.  
  275. VAR:    #n24
  276.     LABEL:    Current mortgage interest payments/period
  277.  
  278. VAR:    #n41
  279.     LABEL:    Current non-mortgage principle payments/period
  280.  
  281. VAR:    #n25
  282.     LABEL:    Current non-mortgage interest payments/period
  283.  
  284. VAR:    #n5
  285.     LABEL:    Wages for this individual
  286.  
  287. VAR:    #n6
  288.     LABEL:    Wages for individuals spouse
  289.  
  290. VAR:    #m19
  291.     LABEL:    Amount spent for groceries per period
  292.  
  293. VAR:    TAGE
  294.     LABEL:    This individuals age
  295.  
  296. VAR:    TMSTAT
  297.     LABEL: Marital status
  298.  
  299. VAR:    HOUSING
  300.     LABEL:    Housing expense
  301.     FIND:    housing = #n24 + #n40
  302.  
  303. VAR:    COMPLT
  304.     LABEL:    Search is complete
  305.  
  306. VAR:    NOTHING
  307.     LABEL:    This rule changes nothing
  308.  
  309. VAR:    #E14
  310. VAR:    #N40
  311. VAR:    #N24
  312. VAR:    #N41
  313. VAR:    #N25
  314. VAR:    #N5
  315. VAR:    #N6
  316. VAR:    #M19
  317. VAR:    #E31
  318. VAR:    #O12
  319. VAR:    #N7
  320. VAR:    #O45
  321.  
  322. END:
  323.