{"ref":{"kind":"component","id":"lbo_credit_covenants","key":"sha256:c458c68585beb55e2cf17dbd03002e631118f3ba0636fa60d1838e6e1fda7fe8"},"label":"Credit covenants","description":"Select the leverage basis, test enabled covenants, and retain decision availability.","inputs":[{"label":"Annualized EBITDA","name":"annual_ebitda","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"$"}},{"label":"Cash Cost","name":"cash_cost","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"$"}},{"label":"Covenant End Month","name":"covenant_end_month","valueType":{"axes":[],"dtype":"f64","unit":"mo"}},{"label":"Covenant Method","name":"covenant_method","valueType":{"axes":[],"dtype":"str","unit":"text"}},{"label":"Covenant Start Month","name":"covenant_start_month","valueType":{"axes":[],"dtype":"f64","unit":"mo"}},{"label":"DSCR","name":"dscr","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"x"}},{"label":"Minimum DSCR","name":"dscr_min","valueType":{"axes":[],"dtype":"f64","unit":"x"}},{"label":"Fixed Charge Coverage","name":"fixed_charge_coverage","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"x"}},{"label":"Fixed Charge Coverage Min","name":"fixed_charge_coverage_min","valueType":{"axes":[],"dtype":"f64","unit":"x"}},{"label":"Interest Coverage","name":"interest_coverage","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"x"}},{"label":"Interest Coverage Min","name":"interest_coverage_min","valueType":{"axes":[],"dtype":"f64","unit":"x"}},{"label":"Minimum Covenant Headroom","name":"minimum_covenant_headroom","valueType":{"axes":[],"dtype":"f64","unit":"x"}},{"label":"Net Debt","name":"net_debt","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"$"}},{"label":"Net Leverage Max","name":"net_leverage_max","valueType":{"axes":[],"dtype":"f64","unit":"x"}},{"label":"Scheduled Service","name":"scheduled_service","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"$"}},{"label":"Senior Leverage","name":"senior_leverage","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"x"}},{"label":"Senior Leverage Max","name":"senior_leverage_max","valueType":{"axes":[],"dtype":"f64","unit":"x"}},{"label":"Total Debt","name":"total_debt","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"$"}},{"label":"Total Leverage Max","name":"total_leverage_max","valueType":{"axes":[],"dtype":"f64","unit":"x"}}],"outputs":[{"label":"Breach Flag","name":"breach_flag","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"flag"}},{"label":"Covenant Active","name":"covenant_active","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"flag"}},{"label":"Covenant Cushion","name":"covenant_cushion","valueType":{"axes":[],"dtype":"f64","unit":"x"}},{"label":"Covenant Cushion Available","name":"covenant_cushion_available","valueType":{"axes":[],"dtype":"f64","unit":"flag"}},{"label":"Minimum Headroom","name":"minimum_headroom","valueType":{"axes":[],"dtype":"f64","unit":"x"}},{"label":"Selected Debt","name":"selected_debt","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"$"}},{"label":"Selected Headroom","name":"selected_headroom","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"x"}},{"label":"Selected Leverage","name":"selected_leverage","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"x"}},{"label":"Selected Leverage Headroom","name":"selected_leverage_headroom","valueType":{"axes":[{"extent":121,"name":"month","variable":true}],"dtype":"f64","unit":"x"}},{"label":"Selected Threshold","name":"selected_threshold","valueType":{"axes":[],"dtype":"f64","unit":"x"}}],"dependencies":[{"id":"lbo_credit_window","key":"sha256:4105bfeff5aaf29e09ba42b36b2f73fc309a87f739d52ecdf5af14e9ae6e7d5f","kind":"component"}],"libraries":["lbo_credit"],"notes":{"conventions":["Nonpositive thresholds disable their tests. Active zero headroom remains binding.","Method selection trims and lowercases text; decision availability retains the original exact sponsor comparison.","Enabled ratios require positive denominators for a covenant decision to be available."]},"calculation":{"nodes":[{"id":"input-annual_ebitda","label":"Annualized EBITDA","kind":"input"},{"id":"input-cash_cost","label":"Cash Cost","kind":"input"},{"id":"input-covenant_end_month","label":"Covenant End Month","kind":"input"},{"id":"input-covenant_method","label":"Covenant Method","kind":"input"},{"id":"input-covenant_start_month","label":"Covenant Start Month","kind":"input"},{"id":"input-dscr","label":"DSCR","kind":"input"},{"id":"input-dscr_min","label":"Minimum DSCR","kind":"input"},{"id":"input-fixed_charge_coverage","label":"Fixed Charge Coverage","kind":"input"},{"id":"input-fixed_charge_coverage_min","label":"Fixed Charge Coverage Min","kind":"input"},{"id":"input-interest_coverage","label":"Interest Coverage","kind":"input"},{"id":"input-interest_coverage_min","label":"Interest Coverage Min","kind":"input"},{"id":"input-minimum_covenant_headroom","label":"Minimum Covenant Headroom","kind":"input"},{"id":"input-net_debt","label":"Net Debt","kind":"input"},{"id":"input-net_leverage_max","label":"Net Leverage Max","kind":"input"},{"id":"input-scheduled_service","label":"Scheduled Service","kind":"input"},{"id":"input-senior_leverage","label":"Senior Leverage","kind":"input"},{"id":"input-senior_leverage_max","label":"Senior Leverage Max","kind":"input"},{"id":"input-total_debt","label":"Total Debt","kind":"input"},{"id":"input-total_leverage_max","label":"Total Leverage Max","kind":"input"},{"id":"step-sponsor_method","label":"Sponsor method","kind":"step","rule":"(Normalize text(Text = Covenant Method) = “sponsor”)","sources":[{"node":"input-covenant_method"}],"calls":[{"function":"normalize_text","label":"Normalize text","bindings":[{"name":"text","label":"Text","value":"Covenant Method"}],"purpose":"Trim surrounding whitespace and convert the text to lowercase."}]},{"id":"step-window","label":"Window","kind":"step","rule":"Result of Covenant window","sources":[{"node":"input-covenant_end_month"},{"node":"input-annual_ebitda"},{"node":"input-covenant_start_month"}],"calls":[{"component":"lbo_credit_window","purpose":"Select the inclusive covenant interval using exact half-month boundaries.","label":"Covenant window","bindings":[{"name":"end","label":"End","value":"Covenant End Month"},{"name":"periods","label":"Periods","value":"Positions in series(Annualized EBITDA)"},{"name":"start","label":"Start","value":"Covenant Start Month"}]}]},{"id":"step-dscr_headroom","label":"DSCR headroom","kind":"step","rule":"(DSCR − Minimum DSCR)","sources":[{"node":"input-dscr"},{"node":"input-dscr_min"}]},{"id":"step-fixed_charge_headroom","label":"Fixed charge headroom","kind":"step","rule":"(Fixed Charge Coverage − Fixed Charge Coverage Min)","sources":[{"node":"input-fixed_charge_coverage"},{"node":"input-fixed_charge_coverage_min"}]},{"id":"step-interest_headroom","label":"Interest headroom","kind":"step","rule":"(Interest Coverage − Interest Coverage Min)","sources":[{"node":"input-interest_coverage"},{"node":"input-interest_coverage_min"}]},{"id":"step-senior_headroom","label":"Senior headroom","kind":"step","rule":"(Senior Leverage Max − Senior Leverage)","sources":[{"node":"input-senior_leverage_max"},{"node":"input-senior_leverage"}]},{"id":"step-selected_debt","label":"Selected Debt","kind":"step","rule":"if Sponsor method, then Net Debt, otherwise Total Debt","sources":[{"node":"step-sponsor_method"},{"node":"input-net_debt"},{"node":"input-total_debt"}]},{"id":"step-selected_threshold","label":"Selected Threshold","kind":"step","rule":"if Sponsor method, then Net Leverage Max, otherwise Total Leverage Max","sources":[{"node":"step-sponsor_method"},{"node":"input-net_leverage_max"},{"node":"input-total_leverage_max"}]},{"id":"step-selected_leverage","label":"Selected Leverage","kind":"step","rule":"(Selected Debt ÷ Annualized EBITDA, or 0 when the divisor is 0)","sources":[{"node":"input-annual_ebitda"},{"node":"step-selected_debt"}],"calls":[{"function":"lbo_credit_multiple","label":"LBO credit multiple","bindings":[{"name":"denominator","label":"Denominator","value":"Annualized EBITDA"},{"name":"numerator","label":"Numerator","value":"Selected Debt"}],"rule":"(Selected Debt ÷ Annualized EBITDA, or 0 when the divisor is 0)"}]},{"id":"output-selected_debt","kind":"output","label":"Selected Debt","rule":"Selected Debt","sources":[{"node":"step-selected_debt"}]},{"id":"step-covenant_active","label":"Covenant Active","kind":"step","rule":"if if (Window > 0), then if (Higher of Higher of Higher of Higher of Senior Leverage Max and Selected Threshold and Interest Coverage Min and Fixed Charge Coverage Min and Minimum DSCR > 0), then true, otherwise false, otherwise false, then 1, otherwise 0","sources":[{"node":"step-window"},{"node":"input-senior_leverage_max"},{"node":"step-selected_threshold"},{"node":"input-interest_coverage_min"},{"node":"input-fixed_charge_coverage_min"},{"node":"input-dscr_min"}]},{"id":"output-selected_threshold","kind":"output","label":"Selected Threshold","rule":"Selected Threshold","sources":[{"node":"step-selected_threshold"}]},{"id":"step-leverage_headroom","label":"Leverage headroom","kind":"step","rule":"(Selected Threshold − Selected Leverage)","sources":[{"node":"step-selected_threshold"},{"node":"step-selected_leverage"}]},{"id":"output-selected_leverage","kind":"output","label":"Selected Leverage","rule":"Selected Leverage","sources":[{"node":"step-selected_leverage"}]},{"id":"step-value0","label":"Conditional result using Covenant Active","kind":"step","rule":"if (Sum(Covenant Active) > 0), then if (Lowest value(if (Covenant Active ≤ 0), then true, otherwise if if if if (Higher of Senior Leverage Max and if (Covenant Method = “sponsor”), then Net Leverage Max, otherwise Total Leverage Max ≤ 0), then true, otherwise if (Annualized EBITDA > 0), then true, otherwise false, then if if (Interest Coverage Min ≤ 0), then true, otherwise if (Cash Cost > 0), then true, otherwise false, then true, otherwise false, otherwise false, then if if (Higher of Fixed Charge Coverage Min and Minimum DSCR ≤ 0), then true, otherwise if (Scheduled Service > 0), then true, otherwise false, then true, otherwise false, otherwise false, then true, otherwise false) > 0), then true, otherwise false, otherwise false","sources":[{"node":"step-covenant_active"},{"node":"input-senior_leverage_max"},{"node":"input-covenant_method"},{"node":"input-net_leverage_max"},{"node":"input-total_leverage_max"},{"node":"input-annual_ebitda"},{"node":"input-interest_coverage_min"},{"node":"input-cash_cost"},{"node":"input-fixed_charge_coverage_min"},{"node":"input-dscr_min"},{"node":"input-scheduled_service"}]},{"id":"output-covenant_active","kind":"output","label":"Covenant Active","rule":"Covenant Active","sources":[{"node":"step-covenant_active"}]},{"id":"step-disabled_headroom","label":"Disabled headroom","kind":"step","rule":"Higher of Higher of Higher of Higher of Senior headroom and Leverage headroom and Interest headroom and Fixed charge headroom and DSCR headroom","sources":[{"node":"step-senior_headroom"},{"node":"step-leverage_headroom"},{"node":"step-interest_headroom"},{"node":"step-fixed_charge_headroom"},{"node":"step-dscr_headroom"}]},{"id":"output-selected_leverage_headroom","kind":"output","label":"Selected Leverage Headroom","rule":"if if (Selected Threshold > 0), then if (Window > 0), then true, otherwise false, otherwise false, then Leverage headroom, otherwise 0","sources":[{"node":"step-selected_threshold"},{"node":"step-window"},{"node":"step-leverage_headroom"}]},{"id":"output-covenant_cushion_available","kind":"output","label":"Covenant Cushion Available","rule":"if Conditional result using Covenant Active, then 1, otherwise 0","sources":[{"node":"step-value0"}]},{"id":"step-selected_headroom","label":"Selected Headroom","kind":"step","rule":"if Covenant Active, then Lower of Lower of Lower of Lower of if (Senior Leverage Max > 0), then Senior headroom, otherwise Disabled headroom and if (Selected Threshold > 0), then Leverage headroom, otherwise Disabled headroom and if (Interest Coverage Min > 0), then Interest headroom, otherwise Disabled headroom and if (Fixed Charge Coverage Min > 0), then Fixed charge headroom, otherwise Disabled headroom and if (Minimum DSCR > 0), then DSCR headroom, otherwise Disabled headroom, otherwise 0","sources":[{"node":"step-covenant_active"},{"node":"input-senior_leverage_max"},{"node":"step-senior_headroom"},{"node":"step-disabled_headroom"},{"node":"step-selected_threshold"},{"node":"step-leverage_headroom"},{"node":"input-interest_coverage_min"},{"node":"step-interest_headroom"},{"node":"input-fixed_charge_coverage_min"},{"node":"step-fixed_charge_headroom"},{"node":"input-dscr_min"},{"node":"step-dscr_headroom"}]},{"id":"step-value1","label":"Reduce min using Covenant Active","kind":"step","rule":"Lowest value(if Covenant Active, then Selected Headroom, otherwise (Lowest value((Selected Headroom × -1)) × -1))","sources":[{"node":"step-covenant_active"},{"node":"step-selected_headroom"}]},{"id":"output-breach_flag","kind":"output","label":"Breach Flag","rule":"if if (Covenant Active > 0), then if (Selected Headroom < 0), then true, otherwise false, otherwise false, then 1, otherwise 0","sources":[{"node":"step-covenant_active"},{"node":"step-selected_headroom"}]},{"id":"output-selected_headroom","kind":"output","label":"Selected Headroom","rule":"Selected Headroom","sources":[{"node":"step-selected_headroom"}]},{"id":"output-covenant_cushion","kind":"output","label":"Covenant Cushion","rule":"if Conditional result using Covenant Active, then (Reduce min using Covenant Active − Minimum Covenant Headroom), otherwise 0","sources":[{"node":"step-value0"},{"node":"step-value1"},{"node":"input-minimum_covenant_headroom"}]},{"id":"output-minimum_headroom","kind":"output","label":"Minimum Headroom","rule":"if Conditional result using Covenant Active, then Reduce min using Covenant Active, otherwise 0","sources":[{"node":"step-value0"},{"node":"step-value1"}]}],"topics":[{"label":"Credit covenants","results":["output-breach_flag","output-covenant_active","output-covenant_cushion","output-covenant_cushion_available","output-minimum_headroom","output-selected_debt","output-selected_headroom","output-selected_leverage","output-selected_leverage_headroom","output-selected_threshold"]}]},"usedBy":[{"kind":"recipe","id":"lbo","key":"sha256:6c9502c2e1a240aaed8179c2349c4bfb3748ca35116e53755e0146d818a0638f"}]}
