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

  1. INITIAL:
  2.     if not indemo then
  3.         load library gdemo
  4.         indemo = true
  5.         load anykey
  6.     endif
  7.     load fplace        /* load the forms needed    */
  8.     bestjob    = unknown    /* Set goal to unknown        */
  9.     e.cfco    = "p"        /* CF algebra is bayesian    */
  10.     e.cfjo    = "p"
  11.     e.rigr    = "a"        /* Try ALL rules for an unknown    */
  12.     e.best    = 15        /* Use up to 15 fuzzy values per variable */
  13.     e.auto  = true
  14.     e.lstr  = 75
  15.     ans1 = 0; ans2 = 0; ans3 = 0; ans4 = 0; ans5 = 0; ans6 = 0
  16.     second1 = 0; second2 = 0; second3 = 0; second4 = 0;
  17.     second5 = 0; second6 = 0
  18.     clear
  19.     putform place1; release place1    /* Put up the main header    */
  20.     putform place2; getform place2; clear place2; release place2
  21.     ans1 += second1 cf 75
  22.     putform place3; getform place3; clear place3; release place3
  23.     ans2 += second2 cf 75
  24.     putform place4; getform place4; clear place4; release place4
  25.     ans3 += second3 cf 75
  26.     putform place5; getform place5; clear place5; release place5
  27.     ans4 += second4 cf 75
  28.     putform place6; getform place6; clear place6; release place6
  29.     ans5 += second5 cf 75
  30.     putform place7; getform place7; release place7
  31.     ans6 += second6 cf 75
  32.     clear
  33.     at 12,34 ?"Thinking away..."
  34.  
  35. DO:
  36.     clear
  37.     putform place8
  38.     release place8
  39.     i = 1
  40.  
  41.         /* Display all the values of the fuzzy variable    BESTJOB    */
  42.         /* by scanning through and printing all values with     */
  43.         /* non-zero certainties.                */
  44.  
  45.     while cfn(bestjob,i) > 0 do
  46.         at 10+i,21 ?valn(bestjob,i),
  47.         at 10+i,54 ?cfn(bestjob,i) using "ddd",
  48.         i = i + 1
  49.     endwhile
  50.     putform anykey; wait; clear
  51.  
  52. GOAL:    bestjob
  53.  
  54. RULE:    LIKED1
  55.     IF:    ans1 = 1
  56.     THEN:    bestjob += {"Accounting" cf 20, "Financial Analysis" \
  57.         cf 12, "Data Processing" cf 12}
  58.     NEEDS:    ans1
  59.     CHANGES: bestjob
  60.     REASON:    If the person liked accounting in college, then they
  61.         are suited for accounting (cf 20), financial analysis
  62.         (cf 12), and data processing (cf 12).
  63.     COMMENT: The person liked accounting in college.
  64.  
  65. RULE:    LIKED2
  66.     IF:    ans1 = 2
  67.     THEN:    bestjob += {"Marketing Research" cf 18, \
  68.         "Financial Analysis" cf 20}
  69.     NEEDS:    ans1
  70.     CHANGES:    bestjob
  71.     REASON:    If the person liked quantitative methods in college,
  72.         then they are suited for marketing research
  73.         (cf 18) and financial analysis (cf 20).
  74.     COMMENT:    The person liked quantitative methods in college.
  75.  
  76. RULE:    LIKED3
  77.     IF:    ans1 = 3
  78.     THEN:    bestjob += {"Supervision" cf 18,"Personnel" cf 20, \
  79.         "Sales" cf 16, "Customer Support" cf 10}
  80.     NEEDS:    ans1
  81.     CHANGES:    bestjob
  82.     REASON:    If the person liked human relations in college, then
  83.         they are suited for supervision (cf 18), personnel
  84.         (cf 20), sales (cf 16), and customer support (cf 10).
  85.     COMMENT:    The person liked human relations in college.
  86.  
  87. RULE:    LIKED4
  88.     IF:    ans1 = 4
  89.     THEN:    bestjob += {"Accounting" cf 14, "Marketing Research" \
  90.         cf 14, "Financial Analysis" cf 14,"Data Processing" cf 20}
  91.     NEEDS:    ans1
  92.     CHANGES:    bestjob
  93.     REASON:    If the person liked computer science in college, then
  94.         they are suited for data processing (cf 20), accounting
  95.         (cf 14), marketing research (cf 14), and financial
  96.         analysis (cf 14).
  97.     COMMENT:    The client liked computer science in college.
  98.  
  99. RULE:    LIKED5
  100.     IF:    ans1 = 5
  101.     THEN:    bestjob += {"Personnel" cf 18, "Supervision" cf 16, \
  102.         "Sales" cf 16, "Customer Support" cf 16}
  103.     NEEDS:    ans1
  104.     CHANGES:    bestjob
  105.     REASON:    If the person liked communications in college, then
  106.         they are suited for personnel (cf 18), supervision
  107.         (cf 16), sales (cf 16), and customer support (cf 16).
  108.     COMMENT:    The person liked communications in college.
  109.  
  110. RULE:    LIKED6
  111.     IF:    ans1 = 6
  112.     THEN:    bestjob += {"Marketing Research" cf 18, "Supervision" \
  113.         cf 16, "Personnel" cf 18, "Sales" cf 14}
  114.     NEEDS:    ans1
  115.     CHANGES:    bestjob
  116.     REASON:    If the person liked psychology in college, then they
  117.         are suited for marketing research (cf 18), supervision
  118.         (cf 16), personnel (cf 18), and sales (cf 14).
  119.     COMMENT:    The person liked psychology in college.
  120.  
  121. RULE:    STRNGTH1
  122.     IF:    ans2 = 1
  123.     THEN:    bestjob += {"Supervision" cf 18, "Personnel" cf 20, \
  124.         "Sales" cf 18, "Customer Support" cf 16, \
  125.         "Data Processing" cf 14}
  126.     NEEDS:    ans2
  127.     CHANGES:    bestjob
  128.     REASON:    If their greatest strength is working with people,
  129.         then they are suited for supervision (cf 18),
  130.         personnel (cf 20), sales (cf 18), customer support
  131.         (cf 16), and data processing (cf 14).
  132.     COMMENT:    Greatest strength is working with people.
  133.  
  134. RULE:    STRNGTH2
  135.     IF:    ans2 = 2
  136.     THEN:    bestjob += {"Accounting" cf 20, "Marketing Research" \
  137.         cf 20, "Financial Analysis" cf 20, "Data Processing" \
  138.         cf 18}
  139.     NEEDS:    ans2
  140.     CHANGES:    bestjob
  141.     REASON:    If the person's strength is working with data, then
  142.         they are suited for accounting, marketing research,
  143.         and financial analysis with certainty 10, and data
  144.         processing with certainty 9.
  145.     COMMENT:    Their strength is working with data.
  146.  
  147. RULE:    STRNGTH3
  148.     IF:    ans2 = 3
  149.     THEN:    bestjob += {"Marketing Research" cf 18, "Financial Analysis" \
  150.         cf 18}
  151.     NEEDS:    ans2
  152.     CHANGES:    bestjob
  153.     REASON:    If the person's strength is working with ideas, then
  154.         they are suited for marketing reasearch of financial
  155.         analysis (cf 18).
  156.     COMMENT:    Their strength is working with ideas.
  157.  
  158. RULE:    STRNGTH4
  159.     IF:    ans2 = 4
  160.     THEN:    bestjob += {"Customer Support" cf 20, "Marketing Research" \
  161.         cf 16, "Financial Analysis" cf 16, "Personnel" cf 16}
  162.     NEEDS:    ans2
  163.     CHANGES:    bestjob
  164.     REASON:    If the person's strength is solving problems, then
  165.         they are suited for customer support (cf 20),
  166.         marketing research (cf 16), financial analysis (cf 16),
  167.         and personnel (cf 16).
  168.     COMMENT:    Their strength is solving problems.
  169.  
  170. RULE:    GRADES1
  171.     IF:    ans3 = 1
  172.     THEN:    bestjob += {"Personnel" cf 16, "Sales" cf 16}
  173.     NEEDS:    ans3
  174.     CHANGES:    bestjob
  175.     REASON:    If the person's highest grades were in liberal arts
  176.         courses, then they are suited for personnel (cf 16)
  177.         and sales (cf 16).
  178.     COMMENT:    Highest grades were in liberal arts.
  179.  
  180. RULE:    GRADES2
  181.     IF:    ans3 = 2
  182.     THEN:    bestjob += {"Marketing Research" cf 18, \
  183.         "Financial Analysis" cf 18, "Data Processing" cf 16}
  184.     NEEDS:    ans3
  185.     CHANGES:    bestjob
  186.     REASON:    If the person's highest grades were in math and
  187.         statistics, then they are suited for marketing
  188.         research (cf 18), financial analysis (cf 18), and
  189.         data processing (cf 16).
  190.     COMMENT:    Highest grades were in math and statistics.
  191.  
  192. RULE:    GRADES3
  193.     IF:    ans3 = 3
  194.     THEN:    bestjob += {"Data Processing" cf 20, "Accounting" cf 14, \
  195.         "Marketing Research" cf 14, "Financial Analysis" cf 14}
  196.     NEEDS:    ans3
  197.     CHANGES:    bestjob
  198.     REASON:    If the person's highest grades were in computer
  199.         science, then they are suited for data processing
  200.         (cf 20), accounting (cf 14), marketing research (cf 14),
  201.         and financial analysis (cf 14).
  202.     COMMENT:    Highest grades were in computer science.
  203.  
  204. RULE:    GRADES4
  205.     IF:    ans3 = 4
  206.     THEN:    bestjob += {"Accounting" cf 20, "Financial Analysis" \
  207.         cf 18, "Data Processing" cf 16}
  208.     NEEDS:    ans3
  209.     CHANGES:    bestjob
  210.     REASON:    If their highest grades were in accounting, then they
  211.         are suited for accounting (cf 20), financial analysis
  212.         (cf 18), and data processing (cf 16).
  213.     COMMENT:    Highest grades were in accounting.
  214.  
  215. RULE:    GRADES5
  216.     IF:    ans3 = 5
  217.     THEN:    bestjob += {"Marketing Research" cf 20, "Supervision" \
  218.         cf 16, "Personnel" cf 18, "Sales" cf 16, \
  219.         "Customer Support" cf 14}
  220.     NEEDS:    ans3
  221.     CHANGES:    bestjob
  222.     REASON:    If their highest grades were in psychology, then they
  223.         are suited for marketing research (cf 20),
  224.         supervision (cf 16), personnel (cf 18), sales (cf 16),
  225.         and customer support (cf 14).
  226.     COMMENT:    Highest grades were in psychology.
  227.  
  228. RULE:    GRADES6
  229.     IF:    ans3 = 6
  230.     THEN:    bestjob += {"Financial Analysis" cf 16, \
  231.         "Marketing Research" cf 14, "Data Processing" cf 14, \
  232.         "Supervision" cf 16, "Sales" cf 16}
  233.     NEEDS:    ans3
  234.     CHANGES:    bestjob
  235.     REASON:    If their highest grades were in general management,
  236.         then they are suited for financial analysis (cf 16),
  237.         marketing research (cf 14), data processing (cf 14),
  238.         supervision (cf 16), and sales (cf 16).
  239.     COMMENT:    Highest grades were in general management.
  240.  
  241. RULE:    SEENOW1
  242.     IF:    ans4 = 1
  243.     THEN:    bestjob += {"Financial Analysis" cf 20, \
  244.         "Data Processing" cf 14, "Accounting" cf 12}
  245.     NEEDS:    ans4
  246.     CHANGES:    bestjob
  247.     REASON:    If the person prefers solving mathematical problems,
  248.         then they are suited for financial analysis (cf 20),
  249.         data processing (cf 14), and accounting (cf 12).
  250.     COMMENT:    They prefer solving complex mathematical problems.
  251.  
  252. RULE:    SEENOW2
  253.     IF:    ans4 = 2
  254.     THEN:    bestjob += {"Personnel" cf 20, "Sales" cf 20, \
  255.         "Supervision" cf 18, "Customer Support" cf 16}
  256.     NEEDS:    ans4
  257.     CHANGES:    bestjob
  258.     REASON:    If the person prefers working with people, then they
  259.         are suited for personnel (cf 20), sales (cf 20),
  260.         supervision (cf 18), and customer support (cf 16).
  261.     COMMENT:    They prefer working with people.
  262.  
  263. RULE:    SEENOW3
  264.     IF:    ans4 = 3
  265.     THEN:    bestjob += {"Financial Analysis" cf 20, "Accounting" \
  266.         cf 16, "Marketing Research" cf 16}
  267.     NEEDS:    ans4
  268.     CHANGES:    bestjob
  269.     REASON:    If the person prefers working alone on data collection
  270.         and analysis, then they are suited for financial
  271.         analysis (cf 20), accounting (cf 16), and marketing
  272.         research (cf 16).
  273.     COMMENT:    They prefer working alone on data collection
  274.         and analysis.
  275.  
  276. RULE:    SEENOW4
  277.     IF:    ans4 = 4
  278.     THEN:    bestjob += {"Financial Analysis" cf 20, "Accounting" \
  279.         cf 20, "Marketing Research" cf 16}
  280.     NEEDS:    ans4
  281.     CHANGES:    bestjob
  282.     REASON:    If the person prefers doing financial computations,
  283.         then they are suited for financial analysis (cf 20),
  284.         accounting (cf 20), and marketing research (cf 16).
  285.     COMMENT:    They prefer doing financial computations.
  286.  
  287. RULE:    SEENOW5
  288.     IF:    ans4 = 5
  289.     THEN:    bestjob += {"Supervision" cf 20, "Personnel" cf 18, \
  290.         "Sales" cf 18, "Customer Support" cf 16}
  291.     NEEDS:    ans4
  292.     CHANGES:    bestjob
  293.     REASON:    If the person prefers working with groups of people,
  294.         then they are suited for supervision (cf 20),
  295.         personnel (cf 18), sales (cf 18), and customer support
  296.         (cf 16).
  297.     COMMENT:    They prefer working with groups of people.
  298.  
  299. RULE:    FUTURE1
  300.     IF:    ans5 = 1
  301.     THEN:    bestjob += {"Financial Analysis" cf 20, \
  302.         "Data Processing" cf 16}
  303.     NEEDS:    ans5
  304.     CHANGES:    bestjob
  305.     REASON:    If they see themselves in five years solving
  306.         mathematical problems, then they are suited for
  307.         financial analysis (cf 20), and data processing
  308.         (cf 18).
  309.     COMMENT:    They see themselves in five years solving
  310.         complex mathematical problems.
  311.  
  312. RULE:    FUTURE2
  313.     IF:    ans5 = 2
  314.     THEN:    bestjob += {"Financial Analysis" cf 18, "Sales" cf 18, \
  315.         "Customer Support" cf 16}
  316.     NEEDS:    ans5
  317.     CHANGES:    bestjob
  318.     REASON:    If they see themselves in five years making decisions,
  319.         then they are suited for financial analysis (cf 18),
  320.         sales (cf 18), and data processing (cf 16)
  321.     COMMENT:    They see themselves in five years making
  322.         decisions.
  323.  
  324. RULE:    FUTURE3
  325.     IF:    ans5 = 3
  326.     THEN:    bestjob += {"Personnel" cf 20, "Customer Support" \
  327.         cf 20}
  328.     NEEDS:    ans5
  329.     CHANGES:    bestjob
  330.     REASON:    If they see themselves in five years solving people
  331.         problems, then they are suited for personnel (cf 20),
  332.         and customer support (cf 20).
  333.     COMMENT:    They see themselves in five years solving people
  334.         problems.
  335.  
  336. RULE:    FUTURE4
  337.     IF:    ans5 = 4
  338.     THEN:    bestjob += {"Supervision" cf 20, "Personnel" cf 20, \
  339.         "Marketing Research" cf 16}
  340.     NEEDS:    ans5
  341.     CHANGES:    bestjob
  342.     REASON:    If they see themselves in five years working with
  343.         groups of people, then they are suited for supervision
  344.         (cf 20), personnel (cf 20), and marketing research
  345.         (cf 16).
  346.     COMMENT:    They see themselves in five years working with
  347.         groups of people.
  348.  
  349. RULE:    FUTURE5
  350.     IF:    ans5 = 5
  351.     THEN:    bestjob += {"Marketing Research" cf 20, "Supervision" \
  352.         cf 20, "Financial Analysis" cf 18, "Data Processing" \
  353.         cf 16}
  354.     NEEDS:    ans5
  355.     CHANGES:    bestjob
  356.     REASON:    If they see themselves in five years making
  357.         recommendations, then they are suited for marketing
  358.         research (cf 20), supervision (cf 20), financial
  359.         analysis (cf 18), and data processing (cf 16).
  360.     COMMENT:    They see themselves in five years making
  361.         recommendations.
  362.  
  363. RULE:    FUTURE6
  364.     IF:    ans5 = 6
  365.     THEN:    bestjob += {"Financial Analysis" cf 20, \
  366.         "Marketing Research" cf 18}
  367.     NEEDS:    ans5
  368.     CHANGES:    bestjob
  369.     REASON:    If they see themselves in five years working along
  370.         on data collection and analysis, then they are suited
  371.         for financial analysis (cf 20) and marketing research
  372.         (cf 18).
  373.     COMMENT:    They see themselves in five years working alone
  374.         on data collection and analysis.
  375.  
  376. RULE:    FUTURE7
  377.     IF:    ans5 = 7
  378.     THEN:    bestjob += {"Accounting" cf 20, "Financial Analysis" \
  379.         cf 20}
  380.     NEEDS:    ans5
  381.     CHANGES:    bestjob
  382.     REASON:    If they see themselves in five years doing financial
  383.         computations, then they are suited for accounting
  384.         (cf 20), and financial analysis (cf 20).
  385.     COMMENT:    The see themselves in five years doing financial
  386.         computations.
  387.  
  388. RULE:    GOALS1
  389.     IF:    ans6 = 1
  390.     THEN:    bestjob += {"Supervision" cf 20, "Sales" cf 20, \
  391.         "Customer Support" cf 20}
  392.     NEEDS:    ans6
  393.     CHANGES:    bestjob
  394.     REASON:    If the most important goal is career development, then
  395.         they are suited for supervision, sales, and customer
  396.         support (cf 20).
  397.     COMMENT:    Most important goal is career development.
  398.  
  399. RULE:    GOALS2
  400.     IF:    ans6 = 2
  401.     THEN:    bestjob += {"Accounting" cf 20, "Data Processing" \
  402.         cf 20, "Financial Analysis" cf 18, "Marketing Research" \
  403.         cf 16, "Customer Support" cf 16}
  404.     NEEDS:    ans6
  405.     CHANGES:    bestjob
  406.     REASON:    If the main goal in improving skills, then they are
  407.         suited for accounting (cf 20), data processing (cf 20),
  408.         financial analysis (cf 18), marketing research (cf 16),
  409.         and customer support (cf 16).
  410.     COMMENT:    Most important goal is improving skills.
  411.  
  412. RULE:    GOALS3
  413.     IF:    ans6 = 3
  414.     THEN:    bestjob += {"Supervision" cf 18, "Personnel" cf 18, \
  415.         "Sales" cf 18, "Marketing Research" cf 16}
  416.     NEEDS:    ans6
  417.     CHANGES:    bestjob
  418.     REASON:    If the main goal is achievement of personal goals,
  419.         then they are suited for supervision (cf 18),
  420.         personnel (cf 18), sales (cf 18), and marketing research
  421.         (cf 18).
  422.     COMMENT:    Main goal is achievement of personal goals.
  423.  
  424. RULE:    GOALS4
  425.     IF:    ans6 = 4
  426.     THEN:    bestjob += {"Sales" cf 20, "Supervision" cf 18}
  427.     NEEDS:    ans6
  428.     CHANGES:    bestjob
  429.     REASON:    If the main goal is making lots of money, then they
  430.         are suited for sales (cf 20) and supervision (cf 18).
  431.     COMMENT:    Main goal is making lots of money.
  432.  
  433. RULE:    GOALS5
  434.     IF:    ans6 = 5
  435.     THEN:    bestjob += {"Customer Support" cf 18, "Data Processing" \
  436.         cf 16, "Accounting" cf 14}
  437.     NEEDS:    ans6
  438.     CHANGES:    bestjob
  439.     REASON:    If the main goal is working with a congenial group of
  440.         people, then they are suited for customer support
  441.         (cf 18), data processing (cf 16), and accounting (cf 14).
  442.     COMMENT:    Main goal is working with a congenial group of
  443.         people.
  444.  
  445. RULE:    GOALS6
  446.     IF:    ans6 = 6
  447.     THEN:    bestjob += {"Sales" cf 20, "Supervision" cf 18, \
  448.         "Data Processing" cf 18}
  449.     NEEDS:    ans6
  450.     CHANGES:    bestjob
  451.     REASON:    If the main goal is rank or status, then they are
  452.         suited for sales (cf 20), supervision (cf 18), and
  453.         data processing (cf 18).
  454.     COMMENT:    Main goal is rank or status.
  455.  
  456. RULE:    GOALS7
  457.     IF:    ans6 = 7
  458.     THEN:    bestjob += {"Personnel" cf 20, "Supervision" cf 16, \
  459.         "Sales" cf 16, "Customer Support" cf 16, \
  460.         "Data Processing" cf 14}
  461.     NEEDS:    ans6
  462.     CHANGES:    bestjob
  463.     REASON:    If the main goal is helping others, then they are
  464.         suited for personnel (cf 20), supervision (cf 16),
  465.         sales (cf 16), customer support (cf 16), and data
  466.         processing (cf 14).
  467.     COMMENT:    Main goal is helping others.
  468.  
  469. RULE:    GOALS8
  470.     IF:    ans6 = 8
  471.     THEN:    bestjob += {"Marketing Research" cf 18, \
  472.         "Financial Analysis" cf 18, "Data Processing" cf 18}
  473.     NEEDS:    ans6
  474.     CHANGES:    bestjob
  475.     REASON:    If the main goal is solving difficult problems, then
  476.         they are suited for marketing research, financial
  477.         analysis, and data processing (cf 18).
  478.     COMMENT:    Main goal is solving difficult problems.
  479.  
  480. RULE:    GOALS9
  481.     IF:    ans6 = 9
  482.     THEN:    bestjob += {"Personnel" cf 16}
  483.     NEEDS:    ans6
  484.     CHANGES:    bestjob
  485.     REASON:    If the main goal is contributing to society, then they
  486.         are suited for personnel (cf 16).
  487.     COMMENT:    Main goal is contributing to society.
  488.  
  489. RULE:    GOALS10
  490.     IF:    ans6 = 0
  491.     THEN:    bestjob += {"Marketing Research" cf 20, \
  492.         "Data Processing" cf 20, "Accounting" cf 16}
  493.     NEEDS:    ans6
  494.     CHANGES:    bestjob
  495.     REASON:    If the main goal is learning or developing new ideas
  496.         or methods, then they are suited for marketing
  497.         research (cf 20), data processing (cf 20), and
  498.         accounting (cf 16).
  499.     COMMENT:    Main goal is learning or developing new ideas
  500.         or methods.
  501.  
  502. VAR:    BESTJOB
  503.     TYPE:    pp
  504.     LIMIT:    10
  505.     LABEL:    The best position for the applicant
  506.  
  507. VAR:    ANS1
  508.     LABEL:    Courses liked best
  509.  
  510. VAR:    ANS2
  511.     LABEL:    Greatest strength
  512.  
  513. VAR:    ANS3
  514.     LABEL:    Highest grade courses
  515.  
  516. VAR:    ANS4
  517.     LABEL:    How I see myself now
  518.  
  519. VAR:    ANS5
  520.     LABEL:    See myself in 5 years
  521.  
  522. VAR:    ANS6
  523.     LABEL:    Most important goal
  524.  
  525. END:
  526.