Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix dep_credit phaseout logic #2205

Merged
merged 1 commit into from
Jan 23, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
12 changes: 5 additions & 7 deletions taxcalc/calcfunctions.py
Original file line number Diff line number Diff line change
Expand Up @@ -1247,13 +1247,11 @@ def ChildDepTaxCredit(n24, MARS, c00100, exact,
dep_credit = (DependentCredit_Child_c * n24 +
DependentCredit_Nonchild_c * max(0, XTOT - n24 - num) +
FilerCredit_c[MARS - 1])
if dep_credit > 0. and CTC_prt > 0.:
thresh = CTC_ps[MARS - 1] + base_ctc / CTC_prt
if modAGI > thresh:
excess = modAGI - thresh
if exact == 1: # exact calculation as on tax forms
excess = 1000. * math.ceil(excess / 1000.)
dep_credit = max(0., dep_credit - CTC_prt * excess)
if dep_credit > 0. and modAGI > CTC_ps[MARS - 1]:
excess = modAGI - CTC_ps[MARS - 1]
if exact == 1: # exact calculation as on tax forms
excess = 1000. * math.ceil(excess / 1000.)
dep_credit = max(0., dep_credit - CTC_prt * excess)
return (prectc, dep_credit)


Expand Down
4 changes: 2 additions & 2 deletions taxcalc/policy_current_law.json
Original file line number Diff line number Diff line change
Expand Up @@ -5148,7 +5148,7 @@

"_DependentCredit_Child_c": {
"long_name": "Nonrefundable credit for child dependents on top of the child tax credit",
"description": "This nonrefundable credit is applied to child dependents and begins phasing out after the CTC phaseout ends.",
"description": "This nonrefundable credit is applied to child dependents and phases out exactly like the CTC amount.",
"section_1": "Nonrefundable Credits",
"section_2": "Child Tax Credit",
"irs_ref": "",
Expand Down Expand Up @@ -5198,7 +5198,7 @@

"_DependentCredit_Nonchild_c": {
"long_name": "Nonrefundable credit for non-child dependents on top of the child tax credit",
"description": "This nonrefundable credit is applied to non-child dependents and begins phasing out after the CTC phaseout ends.",
"description": "This nonrefundable credit is applied to non-child dependents and phases out exactly like the CTC amount.",
"section_1": "Nonrefundable Credits",
"section_2": "Child Tax Credit",
"irs_ref": "",
Expand Down
4 changes: 2 additions & 2 deletions taxcalc/tests/reforms.json
Original file line number Diff line number Diff line change
Expand Up @@ -555,7 +555,7 @@
"baseline": "2017_law.json",
"start_year": 2017,
"value": {"_DependentCredit_Child_c": [500]},
"name": "Set Dependend Credit for Children at $500",
"name": "Set Dependent Credit for Children at $500",
"output_type": "iitax",
"compare_with": {}
},
Expand All @@ -565,7 +565,7 @@
"start_year": 2017,
"value": {"_DependentCredit_before_CTC": [true],
"_DependentCredit_Child_c": [500]},
"name": "Set Dependend Credit for Children at $500 AND stack dependent credit before CTC",
"name": "Set Dependent Credit for Children at $500 AND stack dependent credit before CTC",
"output_type": "iitax",
"compare_with": {}
},
Expand Down
4 changes: 2 additions & 2 deletions taxcalc/tests/reforms_expect.csv
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ rid,res1,res2,res3,res4
53,-107.5,-109.0,-112.3,-115.9
54,28.7,31.2,33.0,32.3
55,85.4,89.8,95.8,101.9
56,-11.7,-11.7,-11.6,-11.5
57,-16.8,-16.8,-16.7,-16.6
56,-8.8,-8.5,-8.2,-8.0
57,-13.9,-13.6,-13.3,-13.1
58,0.0,-30.3,-33.2,-38.2
59,-14.5,-16.0,-16.6,-16.1
60,-16.0,-17.6,-18.3,-17.8
Expand Down