WolffPack differences report |
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
|
*S*************************************************************************
*S***
*S*** WolffPack
*S***
*S*** Subprogram: WFNCI23N
*S*** System : FINANCIER
*S*** Title : Independent Need Analysis calc subroutine
*S*** Function : This subprogram does the Independent EFC calcs for
*S*** 2022-23 per the NAS Specifications
*S*** It is called by WFNAC23N
*S***
*S*** Copyright 1995 - 2022 WolffPack, Inc. All rights reserved.
*S***
*S*************************************************************************
*S**DEFINE DATA
*S** GLOBAL USING WWGDA
*S** PARAMETER USING WWPDA
*S** PARAMETER USING WFNAC23D
*S** PARAMETER USING WFFED23D
*S** PARAMETER USING WFMCA23D
*S***
*S** LOCAL USING WWCONST
*S** LOCAL USING WFISX23D
*S** LOCAL USING WWAOBJ
*S***
*S** LOCAL
*S** 01 #SUB1(P2) INIT <0>
*S** 01 #SUB2(P2) INIT <0>
*S***
*S** 01 #AID-YEAR(N4)
*S** 01 #TEST-YOB(A8)
*S** 01 REDEFINE #TEST-YOB
*S** 02 #TEST-BIRTHYEAR (N4)
*S***
*S** 01 #TABLE-IPA /* Income Protection Allowance Table
*S** 02 #TAB-IPA (P5/1:6,1:5)
*S** INIT (1,V) <00000,00000,00000,00000,00000>
*S** (2,V) <27720,22980,00000,00000,00000>
*S** (3,V) <34520,29800,25060,00000,00000>
*S** (4,V) <42620,37900,33180,28430,00000>
*S** (5,V) <50300,45550,40830,36100,31380>
*S** (6,V) <58820,54090,49380,44620,39910>
*S***
*S** 01 #TABLE-APA /* Education Savings and Asset Protection Allowance
*S** 02 #TAB-APA (P5/1:41,1:3) INIT (1,V) <25,00000,00000>
*S** (2,V) <26,00200,00000>
*S** (3,V) <27,00400,00000>
*S** (4,V) <28,00600,00000>
*S** (5,V) <29,00800,00000>
*S** (6,V) <30,01000,00000>
*S** (7,V) <31,01200,00000>
*S** (8,V) <32,01400,00000>
*S** (9,V) <33,01700,00000>
*S** (10,V) <34,01900,00000>
*S** (11,V) <35,02100,00000>
*S** (12,V) <36,02300,00000>
*S** (13,V) <37,02500,00000>
*S** (14,V) <38,02700,00000>
*S** (15,V) <39,02900,00000>
*S** (16,V) <40,03100,00000>
*S** (17,V) <41,03200,00000>
*S** (18,V) <42,03200,00000>
*S** (19,V) <43,03300,00000>
*S** (20,V) <44,03400,00000>
*S** (21,V) <45,03500,00000>
*S** (22,V) <46,03600,00000>
*S** (23,V) <47,03700,00000>
*S** (24,V) <48,03700,00000>
*S** (25,V) <49,03800,00000>
*S** (26,V) <50,03900,00000>
*S** (27,V) <51,04000,00000>
*S** (28,V) <52,04100,00000>
*S** (29,V) <53,04200,00000>
*S** (30,V) <54,04400,00000>
*S** (31,V) <55,04500,00000>
*S** (32,V) <56,04600,00000>
*S** (33,V) <57,04700,00000>
*S** (34,V) <58,04900,00000>
*S** (35,V) <59,05000,00000>
*S** (36,V) <60,05100,00000>
*S** (37,V) <61,05300,00000>
*S** (38,V) <62,05400,00000>
*S** (39,V) <63,05600,00000>
*S** (40,V) <64,05800,00000>
*S** (41,V) <65,05900,00000>
*S***
*S*** INTERMEDIATE RESULTS FIELDS
*S** 01 #S-ASSET-CONV-RATE(N2.3)
*S***
*S** 01 #A-ST-TAX-PC(N0.3)
*S** 01 #A-STU-EA(P7.3)
*S** 01 #A-STU-SST(P7.3)
*S** 01 #A-STU-SSTR(P7)
*S** 01 #A-SP-SSTR(P7)
*S** 01 #A-SP-SST(P7.3)
*S** 01 #A-STU-IPA(P7.3)
*S** 01 #A-STU-NIA(P7.3)
*S** 01 #A-STU-IPA-EXTRA(P7.3)
*S** 01 #A-FISAP-INCOME(P9)
*S***
*S** 01 #A-STU-TAXABLE-INC(P8.3)
*S** 01 #A-STU-UNTAX-INC(P8.3)
*S** 01 #A-STU-TAX-UNTAX-TOT(P9)
*S** 01 #A-STU-TOTAL-INCOME(P9.3)
*S** 01 #A-STU-STX(P7.3)
*S** 01 #A-STU-STXR(P7)
*S** 01 #A-STU-TOTAL-ALLOW(P9)
*S** 01 #A-STU-AI(P9)
*S** 01 #A-STU-ADJ-NWBF (P8)
*S** 01 #A-STU-NET-WORTH(P8)
*S** 01 #A-STU-CONT-ASSETS(P8)
*S** 01 #A-STU-TOT-CONT-AI(P8)
*S** 01 #A-STU-DNW(P8.3)
*S** 01 #A-STU-APA(P6.3)
*S** 01 #A-STU-AGE(N5)
*S** 01 #A-STU-AAI(P9)
*S** 01 #A-STU-TOT-CONT-AAI(P9)
*S** 01 #A-STU-TOTAL-CONT-AAI(P9.3)
*S** 01 #A-STUDENT-CONTRIBUTION(P9)
*S** 01 #STUDENT-OTH-CONTRIBUTION(P9)
*S** 01 #A-STU-MO-CONT-AI(P9)
*S** 01 #A-STU-OTH-CONT-AI(P9)
*S** 01 #STU-STATE(A2)
*S**END-DEFINE
*S***
*S*** Populate WW-GDA from WW-PDA
*S**MOVE BY POSITION WW-PDA TO WW-GDA
*S***
*S***
*S*************************************************************************
*S***
*S** PERFORM DETERMINE-STUDENT-AGE
*S** PERFORM DETERMINE-STUDENT-STATE
*S** /*
*S** IF #NAC-FULL
*S** IF #NAC-WITHOUT-DEP
*S** PERFORM FORMULA2-REGULAR-INDEPENDENT-WITHOUT
*S** ELSE
*S** PERFORM FORMULA3-REGULAR-INDEPENDENT-WITH
*S** END-IF
*S** ELSE
*S** IF #NAC-WITHOUT-DEP
*S** PERFORM FORMULA5-SIMPLE-INDEPENDENT-WITHOUT
*S** ELSE
*S** PERFORM FORMULA6-SIMPLE-INDEPENDENT-WITH
*S** END-IF
*S** END-IF
*S** /*
*S** PERFORM POPULATE-F9-MCALCS
*S** PERFORM POPULATE-FM-MCALCS
*S***
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE DETERMINE-STUDENT-AGE
*S*************************************************************************
*S** /*
*S** ASSIGN #AID-YEAR = VAL(##AID-YEAR)
*S** IF ##DOB NE INIT-DATE
*S** MOVE EDITED ##DOB (EM=YYYY) TO #TEST-YOB
*S** COMPUTE #A-STU-AGE = #AID-YEAR - #TEST-BIRTHYEAR - 1
*S** ELSE
*S** COMPUTE #A-STU-AGE = 23
*S** END-IF
*S**END-SUBROUTINE /* DETERMINE-STUDENT-AGE
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE DETERMINE-STUDENT-STATE
*S*************************************************************************
*S** /*
*S** ASSIGN #STU-STATE = WFFED23D.WF-FE-S-RES
*S** IF WFFED23D.WF-FE-S-RES = ' '
*S** ASSIGN #STU-STATE = #NAC-ST-AD-STATE
*S** END-IF
*S**END-SUBROUTINE /* DETERMINE-STUDENT-STATE
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE FORMULA2-REGULAR-INDEPENDENT-WITHOUT
*S*************************************************************************
*S** PERFORM STUDENT-INCOME-WITHOUT
*S** PERFORM STUDENT-ASSETS-REGULAR
*S** PERFORM STUDENT-CONTRIBUTIONS
*S**END-SUBROUTINE /* FORMULA2-REGULAR-INDEPENDENT-WITHOUT
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE FORMULA3-REGULAR-INDEPENDENT-WITH
*S*************************************************************************
*S** PERFORM STUDENT-INCOME-WITH
*S** PERFORM STUDENT-ASSETS-REGULAR
*S** PERFORM STUDENT-CONTRIBUTIONS
*S**END-SUBROUTINE /* FORMULA3-REGULAR-INDEPENDENT-WITH
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE FORMULA5-SIMPLE-INDEPENDENT-WITHOUT
*S*************************************************************************
*S** PERFORM STUDENT-INCOME-WITHOUT
*S** PERFORM STUDENT-ASSETS-SIMPLE
*S** PERFORM STUDENT-CONTRIBUTIONS
*S**END-SUBROUTINE /* FORMULA5-SIMPLE-INDEPENDENT-WITHOUT
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE FORMULA6-SIMPLE-INDEPENDENT-WITH
*S*************************************************************************
*S** PERFORM STUDENT-INCOME-WITH
*S** PERFORM STUDENT-ASSETS-SIMPLE
*S** PERFORM STUDENT-CONTRIBUTIONS
*S**END-SUBROUTINE /* FORMULA6-SIMPLE-INDEPENDENT-WITH
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-INCOME-WITHOUT
*S*************************************************************************
*S** /*
*S** /* Student AGI
*S** IF WFFED23D.WF-FE-S-AGI < 0
*S** ASSIGN WFFED23D.WF-FE-S-AGI = 0
*S** END-IF
*S** /*
*S** /* Student taxable income
*S** ASSIGN #A-STU-TAXABLE-INC = WFFED23D.WF-FE-S-AGI
*S** IF NOT #NAC-S-TAX-FILER
*S** COMPUTE #A-STU-TAXABLE-INC = WFFED23D.WF-FE-S-ST-INC
*S** + WFFED23D.WF-FE-S-SP-INC
*S** END-IF
*S** /*
*S** /* Student untaxed income and benefits
*S** COMPUTE #A-STU-UNTAX-INC = #NAC-S-UTX-TOTAL
*S** /*
*S** /* Student taxable and untaxed income
*S** COMPUTE #A-STU-TAX-UNTAX-TOT = #A-STU-TAXABLE-INC
*S** + #A-STU-UNTAX-INC
*S** /*
*S** /* Student total income
*S** COMPUTE #A-STU-TOTAL-INCOME = #A-STU-TAX-UNTAX-TOT
*S** - #NAC-S-AFI-TOTAL
*S** /*
*S** /* Student US income tax
*S** IF NOT #NAC-S-TAX-FILER OR WFFED23D.WF-FE-S-FED-TAX < 0
*S** ASSIGN WFFED23D.WF-FE-S-FED-TAX = 0
*S** END-IF
*S** /*
*S** /* Student state and other taxes
*S** DECIDE ON FIRST VALUE OF #STU-STATE
*S** VALUE 'AK'
*S** ASSIGN #A-ST-TAX-PC = 0
*S** VALUE 'FL','NV','NH','ND','SD','TN','TX','WA','WY'
*S** ASSIGN #A-ST-TAX-PC = .01
*S** VALUE 'AL','AZ','LA','MS','NM','OK'
*S** ASSIGN #A-ST-TAX-PC = .02
*S** VALUE 'AR','CO','DE','IL','IA','IN','KS','ME','MI','MO',
*S** 'MT','NC','NE','OH','PA','SC','VT','WV'
*S** ASSIGN #A-ST-TAX-PC = .03
*S** VALUE 'GA','HI','ID','KY','MA','RI','UT','VA','WI'
*S** ASSIGN #A-ST-TAX-PC = .04
*S** VALUE 'CT','MN','NJ','OR'
*S** ASSIGN #A-ST-TAX-PC = .05
*S** VALUE 'CA','MD','DC'
*S** ASSIGN #A-ST-TAX-PC = .06
*S** VALUE 'NY'
*S** ASSIGN #A-ST-TAX-PC = .07
*S** NONE
*S** ASSIGN #A-ST-TAX-PC = .01
*S** END-DECIDE
*S** COMPUTE ROUNDED #A-STU-STX = #A-ST-TAX-PC * #A-STU-TOTAL-INCOME
*S** IF #A-STU-STX < 0
*S** MOVE 0 TO #A-STU-STX
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-STXR = #A-STU-STX * 1
*S** /*
*S** /* Student FICA tax
*S** IF WFFED23D.WF-FE-S-ST-INC LE 137700
*S** COMPUTE #A-STU-SST = WFFED23D.WF-FE-S-ST-INC * .0765
*S** ELSE
*S** IF WFFED23D.WF-FE-S-ST-INC LE 200000
*S** COMPUTE #A-STU-SST =
*S** ((WFFED23D.WF-FE-S-ST-INC - 137700) * .0145) + 10534.05
*S** ELSE
*S** COMPUTE #A-STU-SST =
*S** ((WFFED23D.WF-FE-S-ST-INC - 200000) * .0235) + 11437.40
*S** END-IF
*S** END-IF
*S** IF #A-STU-SST < 0
*S** ASSIGN #A-STU-SST = 0
*S** END-IF
*S** IF WFFED23D.WF-FE-S-SP-INC LE 137700
*S** COMPUTE #A-SP-SST = WFFED23D.WF-FE-S-SP-INC * .0765
*S** ELSE
*S** IF WFFED23D.WF-FE-S-SP-INC LE 200000
*S** COMPUTE #A-SP-SST =
*S** ((WFFED23D.WF-FE-S-SP-INC - 137700) * .0145) + 10534.05
*S** ELSE
*S** COMPUTE #A-SP-SST =
*S** ((WFFED23D.WF-FE-S-SP-INC - 200000) * .0235) + 11437.40
*S** END-IF
*S** END-IF
*S** IF #A-SP-SST < 0
*S** ASSIGN #A-SP-SST = 0
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-SSTR = #A-STU-SST * 1
*S** COMPUTE ROUNDED #A-SP-SSTR = #A-SP-SST * 1
*S** COMPUTE ROUNDED #A-STU-SST = #A-STU-SSTR + #A-SP-SSTR
*S** /*
*S** /* Student income protection allowance
*S** ASSIGN #A-STU-IPA = 10950
*S** IF WFFED23D.WF-FE-S-MAR = '2' AND WFFED23D.WF-FE-S-FAM-COL < 2
*S** ASSIGN #A-STU-IPA = 17550
*S** END-IF
*S** /*
*S** /* Student employment allowance
*S** ASSIGN #A-STU-EA = 0
*S** IF WFFED23D.WF-FE-S-MAR = '2'
*S** IF (WFFED23D.WF-FE-S-ST-INC > 0 AND WFFED23D.WF-FE-S-SP-INC > 0)
*S** IF WFFED23D.WF-FE-S-ST-INC > WFFED23D.WF-FE-S-SP-INC
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-SP-INC * .35
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-ST-INC * .35
*S** END-IF
*S** ELSE
*S** MOVE 0 TO #A-STU-EA
*S** END-IF
*S** ELSE
*S** IF WFFED23D.WF-FE-S-MAR = '1' OR = '3' OR = '4'
*S** MOVE 0 TO #A-STU-EA
*S** END-IF
*S** END-IF
*S** IF #A-STU-EA < 0
*S** MOVE 0 TO #A-STU-EA
*S** END-IF
*S** IF #A-STU-EA > 4000
*S** MOVE 4000 TO #A-STU-EA
*S** END-IF
*S** /*
*S** /* Student total allowances
*S** IF #NAC-S-TAX-FILER
*S** ASSIGN #A-STU-TOTAL-ALLOW = WFFED23D.WF-FE-S-FED-TAX
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-TOTAL-ALLOW = #A-STU-TOTAL-ALLOW
*S** + #A-STU-STXR + #A-STU-SST
*S** + #A-STU-IPA + #A-STU-EA
*S** /*
*S** /* Student available income
*S** COMPUTE ROUNDED #A-STU-AI = #A-STU-TOTAL-INCOME - #A-STU-TOTAL-ALLOW
*S** /*
*S** /* Student contribution from available income
*S** COMPUTE ROUNDED #A-STU-TOT-CONT-AI = #A-STU-AI * .50
*S** IF #A-STU-UNTAX-INC > 99999999
*S** MOVE 99999999 TO #A-STU-UNTAX-INC
*S** END-IF
*S** IF #A-STU-TOTAL-INCOME > 99999999
*S** MOVE 99999999 TO #A-STU-TOTAL-INCOME
*S** END-IF
*S** IF #A-STU-STX > 9999999
*S** MOVE 9999999 TO #A-STU-STX
*S** END-IF
*S** IF #A-STU-SST > 9999999
*S** MOVE 9999999 TO #A-STU-SST
*S** END-IF
*S** IF #A-STU-TOTAL-ALLOW > 9999999
*S** MOVE 9999999 TO #A-STU-TOTAL-ALLOW
*S** END-IF
*S** IF #A-STU-AI > 99999999
*S** MOVE 99999999 TO #A-STU-AI
*S** END-IF
*S** IF #A-STU-TOT-CONT-AI > 9999999
*S** MOVE 9999999 TO #A-STU-TOT-CONT-AI
*S** END-IF
*S**END-SUBROUTINE /* STUDENT-INCOME-WITHOUT
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-INCOME-WITH
*S*************************************************************************
*S** /*
*S** /* Student AGI
*S** IF WFFED23D.WF-FE-S-AGI < 0
*S** ASSIGN WFFED23D.WF-FE-S-AGI = 0
*S** END-IF
*S** /*
*S** /* Student taxable income
*S** ASSIGN #A-STU-TAXABLE-INC = WFFED23D.WF-FE-S-AGI
*S** IF NOT #NAC-S-TAX-FILER
*S** COMPUTE #A-STU-TAXABLE-INC = WFFED23D.WF-FE-S-ST-INC
*S** + WFFED23D.WF-FE-S-SP-INC
*S** END-IF
*S** /*
*S** /* Student untaxed income and benefits
*S** COMPUTE #A-STU-UNTAX-INC = #NAC-S-UTX-TOTAL
*S** /*
*S** /* Student taxable and untaxed income
*S** COMPUTE #A-STU-TAX-UNTAX-TOT = #A-STU-TAXABLE-INC
*S** + #A-STU-UNTAX-INC
*S** /*
*S** /* Student Total Income
*S** COMPUTE #A-STU-TOTAL-INCOME = #A-STU-TAX-UNTAX-TOT
*S** - #NAC-S-AFI-TOTAL
*S** /*
*S** /* Student US Income tax paid
*S** IF NOT #NAC-S-TAX-FILER OR WFFED23D.WF-FE-S-FED-TAX < 0
*S** ASSIGN WFFED23D.WF-FE-S-FED-TAX = 0
*S** END-IF
*S** /*
*S** /* Student state and other taxes
*S** DECIDE ON FIRST VALUE OF #STU-STATE
*S** VALUE 'AK','ND','SD','TN','WY'
*S** ASSIGN #A-ST-TAX-PC = .01
*S** VALUE 'AL','FL','LA','NV','MS','NM','OK','TX','WA','WV'
*S** ASSIGN #A-ST-TAX-PC = .02
*S** VALUE 'AR','AZ','CO','IN','KS','NH','SC'
*S** ASSIGN #A-ST-TAX-PC = .03
*S** VALUE 'DE','GA','HI','IA','ID','KY','MI','MO','MT','NC',
*S** 'NE','OH','PA','UT'
*S** ASSIGN #A-ST-TAX-PC = .04
*S** VALUE 'IL','ME','RI','VA','VT','WI'
*S** ASSIGN #A-ST-TAX-PC = .05
*S** VALUE 'MA','MN','OR','DC'
*S** ASSIGN #A-ST-TAX-PC = .06
*S** VALUE 'MD'
*S** ASSIGN #A-ST-TAX-PC = .07
*S** VALUE 'CT','CA','NJ'
*S** ASSIGN #A-ST-TAX-PC = .08
*S** VALUE 'NY'
*S** ASSIGN #A-ST-TAX-PC = .09
*S** NONE
*S** ASSIGN #A-ST-TAX-PC = .01
*S** END-DECIDE
*S** IF #A-STU-TOTAL-INCOME < 15000
*S** COMPUTE #A-ST-TAX-PC = #A-ST-TAX-PC + .01
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-STX = #A-ST-TAX-PC * #A-STU-TOTAL-INCOME
*S** IF #A-STU-STX < 0
*S** MOVE 0 TO #A-STU-STX
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-STXR = #A-STU-STX * 1
*S** /*
*S** /* Student FICA tax
*S** IF WFFED23D.WF-FE-S-ST-INC LE 137700
*S** COMPUTE #A-STU-SST = WFFED23D.WF-FE-S-ST-INC * .0765
*S** ELSE
*S** IF WFFED23D.WF-FE-S-ST-INC LE 200000
*S** COMPUTE #A-STU-SST =
*S** ((WFFED23D.WF-FE-S-ST-INC - 137700) * .0145) + 10534.05
*S** ELSE
*S** COMPUTE #A-STU-SST =
*S** ((WFFED23D.WF-FE-S-ST-INC - 200000) * .0235) + 11437.40
*S** END-IF
*S** END-IF
*S** IF #A-STU-SST < 0
*S** ASSIGN #A-STU-SST = 0
*S** END-IF
*S** IF WFFED23D.WF-FE-S-SP-INC LE 137700
*S** COMPUTE #A-SP-SST = WFFED23D.WF-FE-S-SP-INC * .0765
*S** ELSE
*S** IF WFFED23D.WF-FE-S-SP-INC LE 200000
*S** COMPUTE #A-SP-SST =
*S** ((WFFED23D.WF-FE-S-SP-INC - 137700) * .0145) + 10534.05
*S** ELSE
*S** COMPUTE #A-SP-SST =
*S** ((WFFED23D.WF-FE-S-SP-INC - 200000) * .0235) + 11437.40
*S** END-IF
*S** END-IF
*S** IF #A-SP-SST < 0
*S** ASSIGN #A-SP-SST = 0
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-SSTR = #A-STU-SST * 1
*S** COMPUTE ROUNDED #A-SP-SSTR = #A-SP-SST * 1
*S** COMPUTE ROUNDED #A-STU-SST = #A-STU-SSTR + #A-SP-SSTR
*S** /*
*S** /* Student income protection allowance
*S** RESET #A-STU-IPA-EXTRA
*S** ASSIGN #SUB1 = 1
*S** ASSIGN #SUB2 = 1
*S** IF WFFED23D.WF-FE-S-FAM-SIZE > 0
*S** ASSIGN #SUB1 = WFFED23D.WF-FE-S-FAM-SIZE
*S** END-IF
*S** IF WFFED23D.WF-FE-S-FAM-COL > 0
*S** ASSIGN #SUB2 = WFFED23D.WF-FE-S-FAM-COL
*S** END-IF
*S** IF WFFED23D.WF-FE-S-FAM-SIZE > 6
*S** MOVE 6 TO #SUB1
*S** COMPUTE ROUNDED #A-STU-IPA-EXTRA =
*S** ((WFFED23D.WF-FE-S-FAM-SIZE - 6) * 6640)
*S** END-IF
*S** IF WFFED23D.WF-FE-S-FAM-COL > 5
*S** MOVE 5 TO #SUB2
*S** COMPUTE ROUNDED #A-STU-IPA-EXTRA = #A-STU-IPA-EXTRA +
*S** ((WFFED23D.WF-FE-S-FAM-COL - 5) * -4720)
*S** END-IF
*S** ASSIGN #A-STU-IPA = #TAB-IPA(#SUB1,#SUB2) + #A-STU-IPA-EXTRA
*S** IF #A-STU-IPA < 0
*S** MOVE 0 TO #A-STU-IPA
*S** END-IF
*S** /*
*S** /* Student employment allowance
*S** IF WFFED23D.WF-FE-S-MAR = '2'
*S** IF WFFED23D.WF-FE-S-ST-INC > WFFED23D.WF-FE-S-SP-INC
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-SP-INC * .35
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-ST-INC * .35
*S** END-IF
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-ST-INC * .35
*S** END-IF
*S** IF #A-STU-EA < 0
*S** MOVE 0 TO #A-STU-EA
*S** END-IF
*S** IF #A-STU-EA > 4000
*S** MOVE 4000 TO #A-STU-EA
*S** END-IF
*S** /*
*S** /* Student total allowances
*S** IF #NAC-S-TAX-FILER
*S** ASSIGN #A-STU-TOTAL-ALLOW = WFFED23D.WF-FE-S-FED-TAX
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-TOTAL-ALLOW = #A-STU-TOTAL-ALLOW
*S** + #A-STU-STXR + #A-STU-SST
*S** + #A-STU-IPA + #A-STU-EA
*S** /*
*S** /* Student available income
*S** COMPUTE ROUNDED #A-STU-AI = #A-STU-TOTAL-INCOME - #A-STU-TOTAL-ALLOW
*S** /*
*S** /* Student contribution from available income
*S** ASSIGN #A-STU-TOT-CONT-AI = #A-STU-AI
*S** IF #A-STU-UNTAX-INC > 99999999
*S** MOVE 99999999 TO #A-STU-UNTAX-INC
*S** END-IF
*S** IF #A-STU-TOTAL-INCOME > 99999999
*S** MOVE 99999999 TO #A-STU-TOTAL-INCOME
*S** END-IF
*S** IF #A-STU-STX > 9999999
*S** MOVE 9999999 TO #A-STU-STX
*S** END-IF
*S** IF #A-STU-SST > 9999999
*S** MOVE 9999999 TO #A-STU-SST
*S** END-IF
*S** IF #A-STU-TOTAL-ALLOW > 9999999
*S** MOVE 9999999 TO #A-STU-TOTAL-ALLOW
*S** END-IF
*S** IF #A-STU-AI > 99999999
*S** MOVE 99999999 TO #A-STU-AI
*S** END-IF
*S** IF #A-STU-TOT-CONT-AI > 9999999
*S** MOVE 9999999 TO #A-STU-TOT-CONT-AI
*S** END-IF
*S**END-SUBROUTINE /* STUDENT-INCOME-WITH
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-ASSETS-REGULAR
*S*************************************************************************
*S** /*
*S** /* Student investment net worth
*S** IF WFFED23D.WF-FE-S-INV < 0
*S** ASSIGN WFFED23D.WF-FE-S-INV = 0
*S** END-IF
*S** /*
*S** /* Student business/farm net worth
*S** IF WFFED23D.WF-FE-S-BUS-FRM < 0
*S** ASSIGN WFFED23D.WF-FE-S-BUS-FRM = 0
*S** END-IF
*S** /*
*S** /* Student adjusted business/farm net worth
*S** IF WFFED23D.WF-FE-S-BUS-FRM LE 140000
*S** COMPUTE ROUNDED #A-STU-ADJ-NWBF = WFFED23D.WF-FE-S-BUS-FRM * .4
*S** ELSE
*S** IF WFFED23D.WF-FE-S-BUS-FRM LE 420000
*S** COMPUTE ROUNDED #A-STU-ADJ-NWBF =
*S** ((WFFED23D.WF-FE-S-BUS-FRM - 140000) *.5) + 56000
*S** ELSE
*S** IF WFFED23D.WF-FE-S-BUS-FRM LE 700000
*S** COMPUTE ROUNDED #A-STU-ADJ-NWBF =
*S** ((WFFED23D.WF-FE-S-BUS-FRM - 420000) *.6) + 196000
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-ADJ-NWBF =
*S** (WFFED23D.WF-FE-S-BUS-FRM - 700000) + 364000
*S** END-IF
*S** END-IF
*S** END-IF
*S** IF WFFED23D.WF-FE-S-BUS-FRM < 1
*S** MOVE 0 TO #A-STU-ADJ-NWBF
*S** END-IF
*S** /*
*S** /* Student net worth
*S** COMPUTE ROUNDED #A-STU-NET-WORTH = WFFED23D.WF-FE-S-CASH
*S** + WFFED23D.WF-FE-S-INV
*S** + #A-STU-ADJ-NWBF
*S** /*
*S** /* Student asset protection allowance
*S** IF #A-STU-AGE < 25
*S** MOVE 25 TO #A-STU-AGE
*S** END-IF
*S** IF #A-STU-AGE > 65
*S** MOVE 65 TO #A-STU-AGE
*S** END-IF
*S** FOR #SUB1 = 1 TO 41
*S** IF #TAB-APA (#SUB1,1) = #A-STU-AGE
*S** IF WFFED23D.WF-FE-S-MAR = '2'
*S** COMPUTE ROUNDED #A-STU-APA = #TAB-APA (#SUB1,2)
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-APA = #TAB-APA (#SUB1,3)
*S** END-IF
*S** END-IF
*S** END-FOR
*S** /*
*S** /* Student discretionary net worth
*S** COMPUTE ROUNDED #A-STU-DNW = #A-STU-NET-WORTH - #A-STU-APA
*S** /*
*S** /* Student contribution from assets
*S** IF #NAC-WITHOUT-DEP
*S** ASSIGN #S-ASSET-CONV-RATE = 20
*S** ELSE
*S** ASSIGN #S-ASSET-CONV-RATE = 07
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-CONT-ASSETS =
*S** #A-STU-DNW * #S-ASSET-CONV-RATE / 100
*S** IF #A-STU-CONT-ASSETS < 0
*S** MOVE 0 TO #A-STU-CONT-ASSETS
*S** END-IF
*S** IF #A-STU-NET-WORTH > 99999999
*S** MOVE 99999999 TO #A-STU-NET-WORTH
*S** END-IF
*S** IF #A-STU-DNW > 99999999
*S** MOVE 99999999 TO #A-STU-DNW
*S** END-IF
*S** IF #A-STU-CONT-ASSETS > 9999999
*S** MOVE 9999999 TO #A-STU-CONT-ASSETS
*S** END-IF
*S**END-SUBROUTINE /* STUDENT-ASSETS-REGULAR
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-ASSETS-SIMPLE
*S*************************************************************************
*S** /*
*S** ASSIGN WFFED23D.WF-FE-S-CASH = 0
*S** ASSIGN WFFED23D.WF-FE-S-INV = 0
*S** ASSIGN WFFED23D.WF-FE-S-BUS-FRM = 0
*S**END-SUBROUTINE /* STUDENT-ASSETS-SIMPLE
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-CONTRIBUTIONS
*S*************************************************************************
*S** /*
*S** /* Student adjusted available income and contribution from AAI
*S** IF #NAC-WITHOUT-DEP
*S** COMPUTE ROUNDED #A-STU-AAI = #A-STU-AI
*S** COMPUTE #A-STU-TOT-CONT-AAI = #A-STU-TOT-CONT-AI
*S** + #A-STU-CONT-ASSETS
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-AAI = #A-STU-AI + #A-STU-CONT-ASSETS
*S** IF #A-STU-AAI LE -3410
*S** ASSIGN #A-STU-TOTAL-CONT-AAI = -750
*S** ELSE
*S** IF #A-STU-AAI LE 17500
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI = #A-STU-AAI * .22
*S** ELSE
*S** IF #A-STU-AAI LE 22000
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 17500) * .25) + 3850
*S** ELSE
*S** IF #A-STU-AAI LE 26500
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 22000) * .29) + 4975
*S** ELSE
*S** IF #A-STU-AAI LE 31000
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 26500) * .34) + 6280
*S** ELSE
*S** IF #A-STU-AAI LE 35500
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 31000) * .40) + 7810
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 35100) * .47) + 9494
*S** END-IF
*S** END-IF
*S** END-IF
*S** END-IF
*S** END-IF
*S** END-IF
*S** IF #A-STU-TOTAL-CONT-AAI < 0
*S** ASSIGN #A-STU-TOTAL-CONT-AAI = 0
*S** END-IF
*S** MOVE ROUNDED #A-STU-TOTAL-CONT-AAI TO #A-STU-TOT-CONT-AAI
*S** END-IF
*S** /*
*S** /* Student contribution
*S** COMPUTE ROUNDED #A-STUDENT-CONTRIBUTION =
*S** #A-STU-TOT-CONT-AAI / WFFED23D.WF-FE-S-FAM-COL
*S** IF #A-STUDENT-CONTRIBUTION < 0
*S** MOVE 0 TO #A-STUDENT-CONTRIBUTION
*S** END-IF
*S** /*
*S** /* FISAP income
*S** COMPUTE ROUNDED #A-FISAP-INCOME = #A-STU-TOTAL-INCOME
*S** IF #A-STU-AAI > 99999999
*S** MOVE 99999999 TO #A-STU-AAI
*S** END-IF
*S** IF #A-STU-TOT-CONT-AAI > 9999999
*S** MOVE 9999999 TO #A-STU-TOT-CONT-AAI
*S** END-IF
*S** IF #A-STUDENT-CONTRIBUTION > 9999999
*S** MOVE 9999999 TO #A-STUDENT-CONTRIBUTION
*S** END-IF
*S** IF #A-STUDENT-CONTRIBUTION < 0
*S** MOVE 0 TO #A-STUDENT-CONTRIBUTION
*S** END-IF
*S**END-SUBROUTINE /* STUDENT-CONTRIBUTIONS
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE POPULATE-F9-MCALCS
*S*************************************************************************
*S** /*
*S** IF #A-FISAP-INCOME > 99999999
*S** MOVE 99999999 TO #A-FISAP-INCOME
*S** END-IF
*S** /* General calculations
*S** MOVE 'I' TO WFMCA23D.WF-MC-F9-DEP
*S** MOVE #A-FISAP-INCOME TO WFMCA23D.WF-MC-F9-FISAP
*S** /*
*S** /* Autozero calculations
*S** IF #NAC-AUTOZERO
*S** RESET WFMCA23D.WF-MCALCS-F9-STUDENT
*S** MOVE 'B' TO WFMCA23D.WF-MC-F9-S-ANAL
*S** ELSE
*S** /*
*S** /* Regular/simple student calculations
*S** IF #NAC-FULL
*S** MOVE 'R' TO WFMCA23D.WF-MC-F9-S-ANAL
*S** ELSE
*S** MOVE 'S' TO WFMCA23D.WF-MC-F9-S-ANAL
*S** END-IF
*S** MOVE ROUNDED #A-STU-TAXABLE-INC TO WFMCA23D.WF-MC-F9-S-TI
*S** MOVE ROUNDED #A-STU-UNTAX-INC TO WFMCA23D.WF-MC-F9-S-UI
*S** MOVE #NAC-S-AFI-TOTAL TO WFMCA23D.WF-MC-F9-S-JI
*S** MOVE ROUNDED #A-STU-TOTAL-INCOME TO WFMCA23D.WF-MC-F9-S-IT
*S** MOVE WFFED23D.WF-FE-S-FED-TAX TO WFMCA23D.WF-MC-F9-S-FT
*S** MOVE ROUNDED #A-STU-STX TO WFMCA23D.WF-MC-F9-S-ST
*S** MOVE ROUNDED #A-STU-SST TO WFMCA23D.WF-MC-F9-S-FICA
*S** MOVE ROUNDED #A-STU-EA TO WFMCA23D.WF-MC-F9-S-EA
*S** MOVE ROUNDED #A-STU-IPA TO WFMCA23D.WF-MC-F9-S-IPA
*S** MOVE ROUNDED #A-STU-TOTAL-ALLOW TO WFMCA23D.WF-MC-F9-S-AT
*S** MOVE ROUNDED #A-STU-AI TO WFMCA23D.WF-MC-F9-S-AI
*S** MOVE ROUNDED #A-STU-TOT-CONT-AI TO WFMCA23D.WF-MC-F9-S-CAI
*S** MOVE WFFED23D.WF-FE-S-CASH TO WFMCA23D.WF-MC-F9-S-CASH
*S** MOVE WFFED23D.WF-FE-S-INV TO WFMCA23D.WF-MC-F9-S-IE
*S** MOVE WFFED23D.WF-FE-S-BUS-FRM TO WFMCA23D.WF-MC-F9-S-BFW
*S** MOVE ROUNDED #A-STU-NET-WORTH TO WFMCA23D.WF-MC-F9-S-NW
*S** MOVE ROUNDED #A-STU-APA TO WFMCA23D.WF-MC-F9-S-APA
*S** MOVE ROUNDED #A-STU-DNW TO WFMCA23D.WF-MC-F9-S-DNW
*S** MOVE #S-ASSET-CONV-RATE TO WFMCA23D.WF-MC-F9-S-CP
*S** MOVE ROUNDED #A-STU-CONT-ASSETS TO WFMCA23D.WF-MC-F9-S-IS
*S** MOVE ROUNDED #A-STU-AAI TO WFMCA23D.WF-MC-F9-S-AAI
*S** MOVE ROUNDED #A-STU-TOT-CONT-AAI TO WFMCA23D.WF-MC-F9-S-CT
*S** MOVE WFFED23D.WF-FE-S-FAM-COL TO WFMCA23D.WF-MC-F9-S-NC
*S** MOVE ROUNDED #A-STUDENT-CONTRIBUTION TO WFMCA23D.WF-MC-F9-S-CS
*S** END-IF
*S** /*
*S** /* Parent calculations
*S** RESET WFMCA23D.WF-MCALCS-F9-PARENT
*S**END-SUBROUTINE /* POPULATE-F9-MCALCS
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE POPULATE-FM-MCALCS
*S*************************************************************************
*S** /*
*S** MOVE BY POSITION WFMCA23D.WF-MCALCS-F9
*S** TO WFMCA23D.WF-MCALCS-FM
*S** MOVE BY POSITION WFMCA23D.WF-MCALCS-F9-STUDENT
*S** TO WFMCA23D.WF-MCALCS-FM-STUDENT
*S** MOVE BY POSITION WFMCA23D.WF-MCALCS-F9-PARENT
*S** TO WFMCA23D.WF-MCALCS-FM-PARENT
*S** /*
*S** /* If enrollment > 9 months, use 9-month EFC
*S** /* If enrollment < 9 months, pro-rate 9-month EFC
*S** IF NOT #NAC-AUTOZERO
*S** IF #NAC-ENR-DUR < 9
*S** COMPUTE ROUNDED #A-STUDENT-CONTRIBUTION =
*S** #A-STUDENT-CONTRIBUTION / 9
*S** COMPUTE ROUNDED #A-STUDENT-CONTRIBUTION =
*S** #A-STUDENT-CONTRIBUTION * #NAC-ENR-DUR
*S** MOVE ROUNDED #A-STUDENT-CONTRIBUTION TO WFMCA23D.WF-MC-FM-S-CS
*S** MOVE ROUNDED #A-STUDENT-CONTRIBUTION TO WFMCA23D.WF-MC-FM-S-CT
*S** END-IF
*S** END-IF
*S** IF WFMCA23D.WF-MC-FM-S-CS > 9999999
*S** MOVE 9999999 TO WFMCA23D.WF-MC-FM-S-CS
*S** END-IF
*S** IF WFMCA23D.WF-MC-FM-S-CT > 9999999
*S** MOVE 9999999 TO WFMCA23D.WF-MC-FM-S-CT
*S** END-IF
*S**END-SUBROUTINE /* POPULATE-FM-MCALCS
*S***
*S**MOVE BY POSITION WW-GDA TO WW-PDA
*S***
*S**END
*E
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
|
*S*************************************************************************
*S***
*S*** WolffPack
*S***
*S*** Subprogram: WFNCI23N
*S*** System : FINANCIER
*S*** Title : Independent Need Analysis calc subroutine
*S*** Function : This subprogram does the Independent EFC calcs for
*S*** 2022-23 per the NAS Specifications
*S*** It is called by WFNAC23N
*S***
*S*** Copyright 1995 - 2022 WolffPack, Inc. All rights reserved.
*S***
*S*************************************************************************
*S**DEFINE DATA
*S** GLOBAL USING WWGDA
*S** PARAMETER USING WWPDA
*S** PARAMETER USING WFNAC23D
*S** PARAMETER USING WFFED23D
*S** PARAMETER USING WFMCA23D
*S***
*S** LOCAL USING WWCONST
*S** LOCAL USING WFISX23D
*S** LOCAL USING WWAOBJ
*S***
*S** LOCAL
*S** 01 #SUB1(P2) INIT <0>
*S** 01 #SUB2(P2) INIT <0>
*S***
*S** 01 #AID-YEAR(N4)
*S** 01 #TEST-YOB(A8)
*S** 01 REDEFINE #TEST-YOB
*S** 02 #TEST-BIRTHYEAR (N4)
*S***
*S** 01 #TABLE-IPA /* Income Protection Allowance Table
*S** 02 #TAB-IPA (P5/1:6,1:5)
*S** INIT (1,V) <00000,00000,00000,00000,00000>
*S** (2,V) <27720,22980,00000,00000,00000>
*S** (3,V) <34520,29800,25060,00000,00000>
*S** (4,V) <42620,37900,33180,28430,00000>
*S** (5,V) <50300,45550,40830,36100,31380>
*S** (6,V) <58820,54090,49380,44620,39910>
*S***
*S** 01 #TABLE-APA /* Education Savings and Asset Protection Allowance
*S** 02 #TAB-APA (P5/1:41,1:3) INIT (1,V) <25,00000,00000>
*S** (2,V) <26,00200,00000>
*S** (3,V) <27,00400,00000>
*S** (4,V) <28,00600,00000>
*S** (5,V) <29,00800,00000>
*S** (6,V) <30,01000,00000>
*S** (7,V) <31,01200,00000>
*S** (8,V) <32,01400,00000>
*S** (9,V) <33,01700,00000>
*S** (10,V) <34,01900,00000>
*S** (11,V) <35,02100,00000>
*S** (12,V) <36,02300,00000>
*S** (13,V) <37,02500,00000>
*S** (14,V) <38,02700,00000>
*S** (15,V) <39,02900,00000>
*S** (16,V) <40,03100,00000>
*S** (17,V) <41,03200,00000>
*S** (18,V) <42,03200,00000>
*S** (19,V) <43,03300,00000>
*S** (20,V) <44,03400,00000>
*S** (21,V) <45,03500,00000>
*S** (22,V) <46,03600,00000>
*S** (23,V) <47,03700,00000>
*S** (24,V) <48,03700,00000>
*S** (25,V) <49,03800,00000>
*S** (26,V) <50,03900,00000>
*S** (27,V) <51,04000,00000>
*S** (28,V) <52,04100,00000>
*S** (29,V) <53,04200,00000>
*S** (30,V) <54,04400,00000>
*S** (31,V) <55,04500,00000>
*S** (32,V) <56,04600,00000>
*S** (33,V) <57,04700,00000>
*S** (34,V) <58,04900,00000>
*S** (35,V) <59,05000,00000>
*S** (36,V) <60,05100,00000>
*S** (37,V) <61,05300,00000>
*S** (38,V) <62,05400,00000>
*S** (39,V) <63,05600,00000>
*S** (40,V) <64,05800,00000>
*S** (41,V) <65,05900,00000>
*S***
*S*** INTERMEDIATE RESULTS FIELDS
*S** 01 #S-ASSET-CONV-RATE(N2.3)
*S***
*S** 01 #A-ST-TAX-PC(N0.3)
*S** 01 #A-STU-EA(P7.3)
*S** 01 #A-STU-SST(P7.3)
*S** 01 #A-STU-SSTR(P7)
*S** 01 #A-SP-SSTR(P7)
*S** 01 #A-SP-SST(P7.3)
*S** 01 #A-STU-IPA(P7.3)
*S** 01 #A-STU-NIA(P7.3)
*S** 01 #A-STU-IPA-EXTRA(P7.3)
*S** 01 #A-FISAP-INCOME(P9)
*S***
*S** 01 #A-STU-TAXABLE-INC(P8.3)
*S** 01 #A-STU-UNTAX-INC(P8.3)
*S** 01 #A-STU-TAX-UNTAX-TOT(P9)
*S** 01 #A-STU-TOTAL-INCOME(P9.3)
*S** 01 #A-STU-STX(P7.3)
*S** 01 #A-STU-STXR(P7)
*S** 01 #A-STU-TOTAL-ALLOW(P9)
*S** 01 #A-STU-AI(P9)
*S** 01 #A-STU-ADJ-NWBF (P8)
*S** 01 #A-STU-NET-WORTH(P8)
*S** 01 #A-STU-CONT-ASSETS(P8)
*S** 01 #A-STU-TOT-CONT-AI(P8)
*S** 01 #A-STU-DNW(P8.3)
*S** 01 #A-STU-APA(P6.3)
*S** 01 #A-STU-AGE(N5)
*S** 01 #A-STU-AAI(P9)
*S** 01 #A-STU-TOT-CONT-AAI(P9)
*S** 01 #A-STU-TOTAL-CONT-AAI(P9.3)
*S** 01 #A-STUDENT-CONTRIBUTION(P9)
*S** 01 #STUDENT-OTH-CONTRIBUTION(P9)
*S** 01 #A-STU-MO-CONT-AI(P9)
*S** 01 #A-STU-OTH-CONT-AI(P9)
*S** 01 #STU-STATE(A2)
*S**END-DEFINE
*S***
*S*** Populate WW-GDA from WW-PDA
*S**MOVE BY POSITION WW-PDA TO WW-GDA
*S***
*S***
*S*************************************************************************
*S***
*S** PERFORM DETERMINE-STUDENT-AGE
*S** PERFORM DETERMINE-STUDENT-STATE
*S** /*
*S** IF #NAC-FULL
*S** IF #NAC-WITHOUT-DEP
*S** PERFORM FORMULA2-REGULAR-INDEPENDENT-WITHOUT
*S** ELSE
*S** PERFORM FORMULA3-REGULAR-INDEPENDENT-WITH
*S** END-IF
*S** ELSE
*S** IF #NAC-WITHOUT-DEP
*S** PERFORM FORMULA5-SIMPLE-INDEPENDENT-WITHOUT
*S** ELSE
*S** PERFORM FORMULA6-SIMPLE-INDEPENDENT-WITH
*S** END-IF
*S** END-IF
*S** /*
*S** PERFORM POPULATE-F9-MCALCS
*S** PERFORM POPULATE-FM-MCALCS
*S***
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE DETERMINE-STUDENT-AGE
*S*************************************************************************
*S** /*
*S** ASSIGN #AID-YEAR = VAL(##AID-YEAR)
*S** IF ##DOB NE INIT-DATE
*S** MOVE EDITED ##DOB (EM=YYYY) TO #TEST-YOB
*S** COMPUTE #A-STU-AGE = #AID-YEAR - #TEST-BIRTHYEAR - 1
*S** ELSE
*S** COMPUTE #A-STU-AGE = 23
*S** END-IF
*S**END-SUBROUTINE /* DETERMINE-STUDENT-AGE
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE DETERMINE-STUDENT-STATE
*S*************************************************************************
*S** /*
*S** ASSIGN #STU-STATE = WFFED23D.WF-FE-S-RES
*S** IF WFFED23D.WF-FE-S-RES = ' '
*S** ASSIGN #STU-STATE = #NAC-ST-AD-STATE
*S** END-IF
*S**END-SUBROUTINE /* DETERMINE-STUDENT-STATE
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE FORMULA2-REGULAR-INDEPENDENT-WITHOUT
*S*************************************************************************
*S** PERFORM STUDENT-INCOME-WITHOUT
*S** PERFORM STUDENT-ASSETS-REGULAR
*S** PERFORM STUDENT-CONTRIBUTIONS
*S**END-SUBROUTINE /* FORMULA2-REGULAR-INDEPENDENT-WITHOUT
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE FORMULA3-REGULAR-INDEPENDENT-WITH
*S*************************************************************************
*S** PERFORM STUDENT-INCOME-WITH
*S** PERFORM STUDENT-ASSETS-REGULAR
*S** PERFORM STUDENT-CONTRIBUTIONS
*S**END-SUBROUTINE /* FORMULA3-REGULAR-INDEPENDENT-WITH
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE FORMULA5-SIMPLE-INDEPENDENT-WITHOUT
*S*************************************************************************
*S** PERFORM STUDENT-INCOME-WITHOUT
*S** PERFORM STUDENT-ASSETS-SIMPLE
*S** PERFORM STUDENT-CONTRIBUTIONS
*S**END-SUBROUTINE /* FORMULA5-SIMPLE-INDEPENDENT-WITHOUT
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE FORMULA6-SIMPLE-INDEPENDENT-WITH
*S*************************************************************************
*S** PERFORM STUDENT-INCOME-WITH
*S** PERFORM STUDENT-ASSETS-SIMPLE
*S** PERFORM STUDENT-CONTRIBUTIONS
*S**END-SUBROUTINE /* FORMULA6-SIMPLE-INDEPENDENT-WITH
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-INCOME-WITHOUT
*S*************************************************************************
*S** /*
*S** /* Student AGI
*S** IF WFFED23D.WF-FE-S-AGI < 0
*S** ASSIGN WFFED23D.WF-FE-S-AGI = 0
*S** END-IF
*S** /*
*S** /* Student taxable income
*S** ASSIGN #A-STU-TAXABLE-INC = WFFED23D.WF-FE-S-AGI
*S** IF NOT #NAC-S-TAX-FILER
*S** COMPUTE #A-STU-TAXABLE-INC = WFFED23D.WF-FE-S-ST-INC
*S** + WFFED23D.WF-FE-S-SP-INC
*S** END-IF
*S** /*
*S** /* Student untaxed income and benefits
*S** COMPUTE #A-STU-UNTAX-INC = #NAC-S-UTX-TOTAL
*S** /*
*S** /* Student taxable and untaxed income
*S** COMPUTE #A-STU-TAX-UNTAX-TOT = #A-STU-TAXABLE-INC
*S** + #A-STU-UNTAX-INC
*S** /*
*S** /* Student total income
*S** COMPUTE #A-STU-TOTAL-INCOME = #A-STU-TAX-UNTAX-TOT
*S** - #NAC-S-AFI-TOTAL
*S** /*
*S** /* Student US income tax
*S** IF NOT #NAC-S-TAX-FILER OR WFFED23D.WF-FE-S-FED-TAX < 0
*S** ASSIGN WFFED23D.WF-FE-S-FED-TAX = 0
*S** END-IF
*S** /*
*S** /* Student state and other taxes
*S** DECIDE ON FIRST VALUE OF #STU-STATE
*S** VALUE 'AK'
*S** ASSIGN #A-ST-TAX-PC = 0
*S** VALUE 'FL','NV','NH','ND','SD','TN','TX','WA','WY'
*S** ASSIGN #A-ST-TAX-PC = .01
*S** VALUE 'AL','AZ','LA','MS','NM','OK'
*S** ASSIGN #A-ST-TAX-PC = .02
*S** VALUE 'AR','CO','DE','IL','IA','IN','KS','ME','MI','MO',
*S** 'MT','NC','NE','OH','PA','SC','VT','WV'
*S** ASSIGN #A-ST-TAX-PC = .03
*S** VALUE 'GA','HI','ID','KY','MA','RI','UT','VA','WI'
*S** ASSIGN #A-ST-TAX-PC = .04
*S** VALUE 'CT','MN','NJ','OR'
*S** ASSIGN #A-ST-TAX-PC = .05
*S** VALUE 'CA','MD','DC'
*S** ASSIGN #A-ST-TAX-PC = .06
*S** VALUE 'NY'
*S** ASSIGN #A-ST-TAX-PC = .07
*S** NONE
*S** ASSIGN #A-ST-TAX-PC = .01
*S** END-DECIDE
*S** COMPUTE ROUNDED #A-STU-STX = #A-ST-TAX-PC * #A-STU-TOTAL-INCOME
*S** IF #A-STU-STX < 0
*S** MOVE 0 TO #A-STU-STX
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-STXR = #A-STU-STX * 1
*S** /*
*S** /* Student FICA tax
*S** IF WFFED23D.WF-FE-S-ST-INC LE 137700
*S** COMPUTE #A-STU-SST = WFFED23D.WF-FE-S-ST-INC * .0765
*S** ELSE
*S** IF WFFED23D.WF-FE-S-ST-INC LE 200000
*S** COMPUTE #A-STU-SST =
*S** ((WFFED23D.WF-FE-S-ST-INC - 137700) * .0145) + 10534.05
*S** ELSE
*S** COMPUTE #A-STU-SST =
*S** ((WFFED23D.WF-FE-S-ST-INC - 200000) * .0235) + 11437.40
*S** END-IF
*S** END-IF
*S** IF #A-STU-SST < 0
*S** ASSIGN #A-STU-SST = 0
*S** END-IF
*S** IF WFFED23D.WF-FE-S-SP-INC LE 137700
*S** COMPUTE #A-SP-SST = WFFED23D.WF-FE-S-SP-INC * .0765
*S** ELSE
*S** IF WFFED23D.WF-FE-S-SP-INC LE 200000
*S** COMPUTE #A-SP-SST =
*S** ((WFFED23D.WF-FE-S-SP-INC - 137700) * .0145) + 10534.05
*S** ELSE
*S** COMPUTE #A-SP-SST =
*S** ((WFFED23D.WF-FE-S-SP-INC - 200000) * .0235) + 11437.40
*S** END-IF
*S** END-IF
*S** IF #A-SP-SST < 0
*S** ASSIGN #A-SP-SST = 0
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-SSTR = #A-STU-SST * 1
*S** COMPUTE ROUNDED #A-SP-SSTR = #A-SP-SST * 1
*S** COMPUTE ROUNDED #A-STU-SST = #A-STU-SSTR + #A-SP-SSTR
*S** /*
*S** /* Student income protection allowance
*S** ASSIGN #A-STU-IPA = 10950
*S** IF WFFED23D.WF-FE-S-MAR = '2' AND WFFED23D.WF-FE-S-FAM-COL < 2
*S** ASSIGN #A-STU-IPA = 17550
*S** END-IF
*S** /*
*S** /* Student employment allowance
*S** ASSIGN #A-STU-EA = 0
*S** IF WFFED23D.WF-FE-S-MAR = '2'
*S** IF (WFFED23D.WF-FE-S-ST-INC > 0 AND WFFED23D.WF-FE-S-SP-INC > 0)
*S** IF WFFED23D.WF-FE-S-ST-INC > WFFED23D.WF-FE-S-SP-INC
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-SP-INC * .35
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-ST-INC * .35
*S** END-IF
*S** ELSE
*S** MOVE 0 TO #A-STU-EA
*S** END-IF
*S** ELSE
*S** IF WFFED23D.WF-FE-S-MAR = '1' OR = '3' OR = '4'
*S** MOVE 0 TO #A-STU-EA
*S** END-IF
*S** END-IF
*S** IF #A-STU-EA < 0
*S** MOVE 0 TO #A-STU-EA
*S** END-IF
*S** IF #A-STU-EA > 4000
*S** MOVE 4000 TO #A-STU-EA
*S** END-IF
*S** /*
*S** /* Student total allowances
*S** IF #NAC-S-TAX-FILER
*S** ASSIGN #A-STU-TOTAL-ALLOW = WFFED23D.WF-FE-S-FED-TAX
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-TOTAL-ALLOW = #A-STU-TOTAL-ALLOW
*S** + #A-STU-STXR + #A-STU-SST
*S** + #A-STU-IPA + #A-STU-EA
*S** /*
*S** /* Student available income
*S** COMPUTE ROUNDED #A-STU-AI = #A-STU-TOTAL-INCOME - #A-STU-TOTAL-ALLOW
*S** /*
*S** /* Student contribution from available income
*S** COMPUTE ROUNDED #A-STU-TOT-CONT-AI = #A-STU-AI * .50
*S** IF #A-STU-UNTAX-INC > 99999999
*S** MOVE 99999999 TO #A-STU-UNTAX-INC
*S** END-IF
*S** IF #A-STU-TOTAL-INCOME > 99999999
*S** MOVE 99999999 TO #A-STU-TOTAL-INCOME
*S** END-IF
*S** IF #A-STU-STX > 9999999
*S** MOVE 9999999 TO #A-STU-STX
*S** END-IF
*S** IF #A-STU-SST > 9999999
*S** MOVE 9999999 TO #A-STU-SST
*S** END-IF
*S** IF #A-STU-TOTAL-ALLOW > 9999999
*S** MOVE 9999999 TO #A-STU-TOTAL-ALLOW
*S** END-IF
*S** IF #A-STU-AI > 99999999
*S** MOVE 99999999 TO #A-STU-AI
*S** END-IF
*S** IF #A-STU-TOT-CONT-AI > 9999999
*S** MOVE 9999999 TO #A-STU-TOT-CONT-AI
*S** END-IF
*S**END-SUBROUTINE /* STUDENT-INCOME-WITHOUT
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-INCOME-WITH
*S*************************************************************************
*S** /*
*S** /* Student AGI
*S** IF WFFED23D.WF-FE-S-AGI < 0
*S** ASSIGN WFFED23D.WF-FE-S-AGI = 0
*S** END-IF
*S** /*
*S** /* Student taxable income
*S** ASSIGN #A-STU-TAXABLE-INC = WFFED23D.WF-FE-S-AGI
*S** IF NOT #NAC-S-TAX-FILER
*S** COMPUTE #A-STU-TAXABLE-INC = WFFED23D.WF-FE-S-ST-INC
*S** + WFFED23D.WF-FE-S-SP-INC
*S** END-IF
*S** /*
*S** /* Student untaxed income and benefits
*S** COMPUTE #A-STU-UNTAX-INC = #NAC-S-UTX-TOTAL
*S** /*
*S** /* Student taxable and untaxed income
*S** COMPUTE #A-STU-TAX-UNTAX-TOT = #A-STU-TAXABLE-INC
*S** + #A-STU-UNTAX-INC
*S** /*
*S** /* Student Total Income
*S** COMPUTE #A-STU-TOTAL-INCOME = #A-STU-TAX-UNTAX-TOT
*S** - #NAC-S-AFI-TOTAL
*S** /*
*S** /* Student US Income tax paid
*S** IF NOT #NAC-S-TAX-FILER OR WFFED23D.WF-FE-S-FED-TAX < 0
*S** ASSIGN WFFED23D.WF-FE-S-FED-TAX = 0
*S** END-IF
*S** /*
*S** /* Student state and other taxes
*S** DECIDE ON FIRST VALUE OF #STU-STATE
*S** VALUE 'AK','ND','SD','TN','WY'
*S** ASSIGN #A-ST-TAX-PC = .01
*S** VALUE 'AL','FL','LA','NV','MS','NM','OK','TX','WA','WV'
*S** ASSIGN #A-ST-TAX-PC = .02
*S** VALUE 'AR','AZ','CO','IN','KS','NH','SC'
*S** ASSIGN #A-ST-TAX-PC = .03
*S** VALUE 'DE','GA','HI','IA','ID','KY','MI','MO','MT','NC',
*S** 'NE','OH','PA','UT'
*S** ASSIGN #A-ST-TAX-PC = .04
*S** VALUE 'IL','ME','RI','VA','VT','WI'
*S** ASSIGN #A-ST-TAX-PC = .05
*S** VALUE 'MA','MN','OR','DC'
*S** ASSIGN #A-ST-TAX-PC = .06
*S** VALUE 'MD'
*S** ASSIGN #A-ST-TAX-PC = .07
*S** VALUE 'CT','CA','NJ'
*S** ASSIGN #A-ST-TAX-PC = .08
*S** VALUE 'NY'
*S** ASSIGN #A-ST-TAX-PC = .09
*S** NONE
*S** ASSIGN #A-ST-TAX-PC = .01
*S** END-DECIDE
*S** IF #A-STU-TOTAL-INCOME < 15000
*S** COMPUTE #A-ST-TAX-PC = #A-ST-TAX-PC + .01
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-STX = #A-ST-TAX-PC * #A-STU-TOTAL-INCOME
*S** IF #A-STU-STX < 0
*S** MOVE 0 TO #A-STU-STX
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-STXR = #A-STU-STX * 1
*S** /*
*S** /* Student FICA tax
*S** IF WFFED23D.WF-FE-S-ST-INC LE 137700
*S** COMPUTE #A-STU-SST = WFFED23D.WF-FE-S-ST-INC * .0765
*S** ELSE
*S** IF WFFED23D.WF-FE-S-ST-INC LE 200000
*S** COMPUTE #A-STU-SST =
*S** ((WFFED23D.WF-FE-S-ST-INC - 137700) * .0145) + 10534.05
*S** ELSE
*S** COMPUTE #A-STU-SST =
*S** ((WFFED23D.WF-FE-S-ST-INC - 200000) * .0235) + 11437.40
*S** END-IF
*S** END-IF
*S** IF #A-STU-SST < 0
*S** ASSIGN #A-STU-SST = 0
*S** END-IF
*S** IF WFFED23D.WF-FE-S-SP-INC LE 137700
*S** COMPUTE #A-SP-SST = WFFED23D.WF-FE-S-SP-INC * .0765
*S** ELSE
*S** IF WFFED23D.WF-FE-S-SP-INC LE 200000
*S** COMPUTE #A-SP-SST =
*S** ((WFFED23D.WF-FE-S-SP-INC - 137700) * .0145) + 10534.05
*S** ELSE
*S** COMPUTE #A-SP-SST =
*S** ((WFFED23D.WF-FE-S-SP-INC - 200000) * .0235) + 11437.40
*S** END-IF
*S** END-IF
*S** IF #A-SP-SST < 0
*S** ASSIGN #A-SP-SST = 0
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-SSTR = #A-STU-SST * 1
*S** COMPUTE ROUNDED #A-SP-SSTR = #A-SP-SST * 1
*S** COMPUTE ROUNDED #A-STU-SST = #A-STU-SSTR + #A-SP-SSTR
*S** /*
*S** /* Student income protection allowance
*S** RESET #A-STU-IPA-EXTRA
*S** ASSIGN #SUB1 = 1
*S** ASSIGN #SUB2 = 1
*S** IF WFFED23D.WF-FE-S-FAM-SIZE > 0
*S** ASSIGN #SUB1 = WFFED23D.WF-FE-S-FAM-SIZE
*S** END-IF
*S** IF WFFED23D.WF-FE-S-FAM-COL > 0
*S** ASSIGN #SUB2 = WFFED23D.WF-FE-S-FAM-COL
*S** END-IF
*S** IF WFFED23D.WF-FE-S-FAM-SIZE > 6
*S** MOVE 6 TO #SUB1
*S** COMPUTE ROUNDED #A-STU-IPA-EXTRA =
*S** ((WFFED23D.WF-FE-S-FAM-SIZE - 6) * 6640)
*S** END-IF
*S** IF WFFED23D.WF-FE-S-FAM-COL > 5
*S** MOVE 5 TO #SUB2
*S** COMPUTE ROUNDED #A-STU-IPA-EXTRA = #A-STU-IPA-EXTRA +
*S** ((WFFED23D.WF-FE-S-FAM-COL - 5) * -4720)
*S** END-IF
*S** ASSIGN #A-STU-IPA = #TAB-IPA(#SUB1,#SUB2) + #A-STU-IPA-EXTRA
*S** IF #A-STU-IPA < 0
*S** MOVE 0 TO #A-STU-IPA
*S** END-IF
*S** /*
*S** /* Student employment allowance
*S** IF WFFED23D.WF-FE-S-MAR = '2'
*S** IF WFFED23D.WF-FE-S-ST-INC > WFFED23D.WF-FE-S-SP-INC
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-SP-INC * .35
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-ST-INC * .35
*S** END-IF
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-EA = WFFED23D.WF-FE-S-ST-INC * .35
*S** END-IF
*S** IF #A-STU-EA < 0
*S** MOVE 0 TO #A-STU-EA
*S** END-IF
*S** IF #A-STU-EA > 4000
*S** MOVE 4000 TO #A-STU-EA
*S** END-IF
*S** /*
*S** /* Student total allowances
*S** IF #NAC-S-TAX-FILER
*S** ASSIGN #A-STU-TOTAL-ALLOW = WFFED23D.WF-FE-S-FED-TAX
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-TOTAL-ALLOW = #A-STU-TOTAL-ALLOW
*S** + #A-STU-STXR + #A-STU-SST
*S** + #A-STU-IPA + #A-STU-EA
*S** /*
*S** /* Student available income
*S** COMPUTE ROUNDED #A-STU-AI = #A-STU-TOTAL-INCOME - #A-STU-TOTAL-ALLOW
*S** /*
*S** /* Student contribution from available income
*S** ASSIGN #A-STU-TOT-CONT-AI = #A-STU-AI
*S** IF #A-STU-UNTAX-INC > 99999999
*S** MOVE 99999999 TO #A-STU-UNTAX-INC
*S** END-IF
*S** IF #A-STU-TOTAL-INCOME > 99999999
*S** MOVE 99999999 TO #A-STU-TOTAL-INCOME
*S** END-IF
*S** IF #A-STU-STX > 9999999
*S** MOVE 9999999 TO #A-STU-STX
*S** END-IF
*S** IF #A-STU-SST > 9999999
*S** MOVE 9999999 TO #A-STU-SST
*S** END-IF
*S** IF #A-STU-TOTAL-ALLOW > 9999999
*S** MOVE 9999999 TO #A-STU-TOTAL-ALLOW
*S** END-IF
*S** IF #A-STU-AI > 99999999
*S** MOVE 99999999 TO #A-STU-AI
*S** END-IF
*S** IF #A-STU-TOT-CONT-AI > 9999999
*S** MOVE 9999999 TO #A-STU-TOT-CONT-AI
*S** END-IF
*S**END-SUBROUTINE /* STUDENT-INCOME-WITH
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-ASSETS-REGULAR
*S*************************************************************************
*S** /*
*S** /* Student investment net worth
*S** IF WFFED23D.WF-FE-S-INV < 0
*S** ASSIGN WFFED23D.WF-FE-S-INV = 0
*S** END-IF
*S** /*
*S** /* Student business/farm net worth
*S** IF WFFED23D.WF-FE-S-BUS-FRM < 0
*S** ASSIGN WFFED23D.WF-FE-S-BUS-FRM = 0
*S** END-IF
*S** /*
*S** /* Student adjusted business/farm net worth
*S** IF WFFED23D.WF-FE-S-BUS-FRM LE 140000
*S** COMPUTE ROUNDED #A-STU-ADJ-NWBF = WFFED23D.WF-FE-S-BUS-FRM * .4
*S** ELSE
*S** IF WFFED23D.WF-FE-S-BUS-FRM LE 420000
*S** COMPUTE ROUNDED #A-STU-ADJ-NWBF =
*S** ((WFFED23D.WF-FE-S-BUS-FRM - 140000) *.5) + 56000
*S** ELSE
*S** IF WFFED23D.WF-FE-S-BUS-FRM LE 700000
*S** COMPUTE ROUNDED #A-STU-ADJ-NWBF =
*S** ((WFFED23D.WF-FE-S-BUS-FRM - 420000) *.6) + 196000
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-ADJ-NWBF =
*S** (WFFED23D.WF-FE-S-BUS-FRM - 700000) + 364000
*S** END-IF
*S** END-IF
*S** END-IF
*S** IF WFFED23D.WF-FE-S-BUS-FRM < 1
*S** MOVE 0 TO #A-STU-ADJ-NWBF
*S** END-IF
*S** /*
*S** /* Student net worth
*S** COMPUTE ROUNDED #A-STU-NET-WORTH = WFFED23D.WF-FE-S-CASH
*S** + WFFED23D.WF-FE-S-INV
*S** + #A-STU-ADJ-NWBF
*S** /*
*S** /* Student asset protection allowance
*S** IF #A-STU-AGE < 25
*S** MOVE 25 TO #A-STU-AGE
*S** END-IF
*S** IF #A-STU-AGE > 65
*S** MOVE 65 TO #A-STU-AGE
*S** END-IF
*S** FOR #SUB1 = 1 TO 41
*S** IF #TAB-APA (#SUB1,1) = #A-STU-AGE
*S** IF WFFED23D.WF-FE-S-MAR = '2'
*S** COMPUTE ROUNDED #A-STU-APA = #TAB-APA (#SUB1,2)
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-APA = #TAB-APA (#SUB1,3)
*S** END-IF
*S** END-IF
*S** END-FOR
*S** /*
*S** /* Student discretionary net worth
*S** COMPUTE ROUNDED #A-STU-DNW = #A-STU-NET-WORTH - #A-STU-APA
*S** /*
*S** /* Student contribution from assets
*S** IF #NAC-WITHOUT-DEP
*S** ASSIGN #S-ASSET-CONV-RATE = 20
*S** ELSE
*S** ASSIGN #S-ASSET-CONV-RATE = 07
*S** END-IF
*S** COMPUTE ROUNDED #A-STU-CONT-ASSETS =
*S** #A-STU-DNW * #S-ASSET-CONV-RATE / 100
*S** IF #A-STU-CONT-ASSETS < 0
*S** MOVE 0 TO #A-STU-CONT-ASSETS
*S** END-IF
*S** IF #A-STU-NET-WORTH > 99999999
*S** MOVE 99999999 TO #A-STU-NET-WORTH
*S** END-IF
*S** IF #A-STU-DNW > 99999999
*S** MOVE 99999999 TO #A-STU-DNW
*S** END-IF
*S** IF #A-STU-CONT-ASSETS > 9999999
*S** MOVE 9999999 TO #A-STU-CONT-ASSETS
*S** END-IF
*S**END-SUBROUTINE /* STUDENT-ASSETS-REGULAR
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-ASSETS-SIMPLE
*S*************************************************************************
*S** /*
*S** ASSIGN WFFED23D.WF-FE-S-CASH = 0
*S** ASSIGN WFFED23D.WF-FE-S-INV = 0
*S** ASSIGN WFFED23D.WF-FE-S-BUS-FRM = 0
*S**END-SUBROUTINE /* STUDENT-ASSETS-SIMPLE
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE STUDENT-CONTRIBUTIONS
*S*************************************************************************
*S** /*
*S** /* Student adjusted available income and contribution from AAI
*S** IF #NAC-WITHOUT-DEP
*S** COMPUTE ROUNDED #A-STU-AAI = #A-STU-AI
*S** COMPUTE #A-STU-TOT-CONT-AAI = #A-STU-TOT-CONT-AI
*S** + #A-STU-CONT-ASSETS
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-AAI = #A-STU-AI + #A-STU-CONT-ASSETS
*S** IF #A-STU-AAI LE -3410
*S** ASSIGN #A-STU-TOTAL-CONT-AAI = -750
*S** ELSE
*S** IF #A-STU-AAI LE 17500
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI = #A-STU-AAI * .22
*S** ELSE
*S** IF #A-STU-AAI LE 22000
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 17500) * .25) + 3850
*S** ELSE
*S** IF #A-STU-AAI LE 26500
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 22000) * .29) + 4975
*S** ELSE
*S** IF #A-STU-AAI LE 31000
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 26500) * .34) + 6280
*S** ELSE
*S** IF #A-STU-AAI LE 35500
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 31000) * .40) + 7810
*S** ELSE
*S** COMPUTE ROUNDED #A-STU-TOTAL-CONT-AAI =
*S** ((#A-STU-AAI - 35500) * .47) + 9610
*S** END-IF
*S** END-IF
*S** END-IF
*S** END-IF
*S** END-IF
*S** END-IF
*S** IF #A-STU-TOTAL-CONT-AAI < 0
*S** ASSIGN #A-STU-TOTAL-CONT-AAI = 0
*S** END-IF
*S** MOVE ROUNDED #A-STU-TOTAL-CONT-AAI TO #A-STU-TOT-CONT-AAI
*S** END-IF
*S** /*
*S** /* Student contribution
*S** COMPUTE ROUNDED #A-STUDENT-CONTRIBUTION =
*S** #A-STU-TOT-CONT-AAI / WFFED23D.WF-FE-S-FAM-COL
*S** IF #A-STUDENT-CONTRIBUTION < 0
*S** MOVE 0 TO #A-STUDENT-CONTRIBUTION
*S** END-IF
*S** /*
*S** /* FISAP income
*S** COMPUTE ROUNDED #A-FISAP-INCOME = #A-STU-TOTAL-INCOME
*S** IF #A-STU-AAI > 99999999
*S** MOVE 99999999 TO #A-STU-AAI
*S** END-IF
*S** IF #A-STU-TOT-CONT-AAI > 9999999
*S** MOVE 9999999 TO #A-STU-TOT-CONT-AAI
*S** END-IF
*S** IF #A-STUDENT-CONTRIBUTION > 9999999
*S** MOVE 9999999 TO #A-STUDENT-CONTRIBUTION
*S** END-IF
*S** IF #A-STUDENT-CONTRIBUTION < 0
*S** MOVE 0 TO #A-STUDENT-CONTRIBUTION
*S** END-IF
*S**END-SUBROUTINE /* STUDENT-CONTRIBUTIONS
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE POPULATE-F9-MCALCS
*S*************************************************************************
*S** /*
*S** IF #A-FISAP-INCOME > 99999999
*S** MOVE 99999999 TO #A-FISAP-INCOME
*S** END-IF
*S** /* General calculations
*S** MOVE 'I' TO WFMCA23D.WF-MC-F9-DEP
*S** MOVE #A-FISAP-INCOME TO WFMCA23D.WF-MC-F9-FISAP
*S** /*
*S** /* Autozero calculations
*S** IF #NAC-AUTOZERO
*S** RESET WFMCA23D.WF-MCALCS-F9-STUDENT
*S** MOVE 'B' TO WFMCA23D.WF-MC-F9-S-ANAL
*S** ELSE
*S** /*
*S** /* Regular/simple student calculations
*S** IF #NAC-FULL
*S** MOVE 'R' TO WFMCA23D.WF-MC-F9-S-ANAL
*S** ELSE
*S** MOVE 'S' TO WFMCA23D.WF-MC-F9-S-ANAL
*S** END-IF
*S** MOVE ROUNDED #A-STU-TAXABLE-INC TO WFMCA23D.WF-MC-F9-S-TI
*S** MOVE ROUNDED #A-STU-UNTAX-INC TO WFMCA23D.WF-MC-F9-S-UI
*S** MOVE #NAC-S-AFI-TOTAL TO WFMCA23D.WF-MC-F9-S-JI
*S** MOVE ROUNDED #A-STU-TOTAL-INCOME TO WFMCA23D.WF-MC-F9-S-IT
*S** MOVE WFFED23D.WF-FE-S-FED-TAX TO WFMCA23D.WF-MC-F9-S-FT
*S** MOVE ROUNDED #A-STU-STX TO WFMCA23D.WF-MC-F9-S-ST
*S** MOVE ROUNDED #A-STU-SST TO WFMCA23D.WF-MC-F9-S-FICA
*S** MOVE ROUNDED #A-STU-EA TO WFMCA23D.WF-MC-F9-S-EA
*S** MOVE ROUNDED #A-STU-IPA TO WFMCA23D.WF-MC-F9-S-IPA
*S** MOVE ROUNDED #A-STU-TOTAL-ALLOW TO WFMCA23D.WF-MC-F9-S-AT
*S** MOVE ROUNDED #A-STU-AI TO WFMCA23D.WF-MC-F9-S-AI
*S** MOVE ROUNDED #A-STU-TOT-CONT-AI TO WFMCA23D.WF-MC-F9-S-CAI
*S** MOVE WFFED23D.WF-FE-S-CASH TO WFMCA23D.WF-MC-F9-S-CASH
*S** MOVE WFFED23D.WF-FE-S-INV TO WFMCA23D.WF-MC-F9-S-IE
*S** MOVE WFFED23D.WF-FE-S-BUS-FRM TO WFMCA23D.WF-MC-F9-S-BFW
*S** MOVE ROUNDED #A-STU-NET-WORTH TO WFMCA23D.WF-MC-F9-S-NW
*S** MOVE ROUNDED #A-STU-APA TO WFMCA23D.WF-MC-F9-S-APA
*S** MOVE ROUNDED #A-STU-DNW TO WFMCA23D.WF-MC-F9-S-DNW
*S** MOVE #S-ASSET-CONV-RATE TO WFMCA23D.WF-MC-F9-S-CP
*S** MOVE ROUNDED #A-STU-CONT-ASSETS TO WFMCA23D.WF-MC-F9-S-IS
*S** MOVE ROUNDED #A-STU-AAI TO WFMCA23D.WF-MC-F9-S-AAI
*S** MOVE ROUNDED #A-STU-TOT-CONT-AAI TO WFMCA23D.WF-MC-F9-S-CT
*S** MOVE WFFED23D.WF-FE-S-FAM-COL TO WFMCA23D.WF-MC-F9-S-NC
*S** MOVE ROUNDED #A-STUDENT-CONTRIBUTION TO WFMCA23D.WF-MC-F9-S-CS
*S** END-IF
*S** /*
*S** /* Parent calculations
*S** RESET WFMCA23D.WF-MCALCS-F9-PARENT
*S**END-SUBROUTINE /* POPULATE-F9-MCALCS
*S***
*S*************************************************************************
*S**DEFINE SUBROUTINE POPULATE-FM-MCALCS
*S*************************************************************************
*S** /*
*S** MOVE BY POSITION WFMCA23D.WF-MCALCS-F9
*S** TO WFMCA23D.WF-MCALCS-FM
*S** MOVE BY POSITION WFMCA23D.WF-MCALCS-F9-STUDENT
*S** TO WFMCA23D.WF-MCALCS-FM-STUDENT
*S** MOVE BY POSITION WFMCA23D.WF-MCALCS-F9-PARENT
*S** TO WFMCA23D.WF-MCALCS-FM-PARENT
*S** /*
*S** /* If enrollment > 9 months, use 9-month EFC
*S** /* If enrollment < 9 months, pro-rate 9-month EFC
*S** IF NOT #NAC-AUTOZERO
*S** IF #NAC-ENR-DUR < 9
*S** COMPUTE ROUNDED #A-STUDENT-CONTRIBUTION =
*S** #A-STUDENT-CONTRIBUTION / 9
*S** COMPUTE ROUNDED #A-STUDENT-CONTRIBUTION =
*S** #A-STUDENT-CONTRIBUTION * #NAC-ENR-DUR
*S** MOVE ROUNDED #A-STUDENT-CONTRIBUTION TO WFMCA23D.WF-MC-FM-S-CS
*S** MOVE ROUNDED #A-STUDENT-CONTRIBUTION TO WFMCA23D.WF-MC-FM-S-CT
*S** END-IF
*S** END-IF
*S** IF WFMCA23D.WF-MC-FM-S-CS > 9999999
*S** MOVE 9999999 TO WFMCA23D.WF-MC-FM-S-CS
*S** END-IF
*S** IF WFMCA23D.WF-MC-FM-S-CT > 9999999
*S** MOVE 9999999 TO WFMCA23D.WF-MC-FM-S-CT
*S** END-IF
*S**END-SUBROUTINE /* POPULATE-FM-MCALCS
*S***
*S**MOVE BY POSITION WW-GDA TO WW-PDA
*S***
*S**END
*E
|