[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master 9b46a92 08/15: Assume genacct and loan rates
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master 9b46a92 08/15: Assume genacct and loan rates are always needed [312] |
Date: |
Sun, 14 Feb 2021 18:24:53 -0500 (EST) |
branch: master
commit 9b46a92129ad926cda0de1f246c09a50bd390f42
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>
Assume genacct and loan rates are always needed [312]
US states generally require policy to include a loan provision, so
loans are always needed. Loaned funds are usually held in the general
account, so a general account is always needed, even if only for loans.
Other types of interest rates are needed only conditionally, and some
cost is saved by not calculating them when they're not needed; but these
two categories are always needed.
---
interest_rates.cpp | 17 -----------------
interest_rates.hpp | 2 --
2 files changed, 19 deletions(-)
diff --git a/interest_rates.cpp b/interest_rates.cpp
index 8bacde1..7f00555 100644
--- a/interest_rates.cpp
+++ b/interest_rates.cpp
@@ -302,8 +302,6 @@ InterestRates::InterestRates(BasicValues const& v)
,SepAcctSpreadMethod_{v.database().query<mcenum_spread_method>(DB_SepAcctSpreadMethod)}
,AmortLoad_ {Zero_}
,ExtraSepAcctCharge_ {Zero_}
-// ,NeedLoanRates_ {need_loan_rates(v.yare_input_)}
- ,NeedLoanRates_ {true} // DEPRECATED
,LoanRateType_ {v.yare_input_.LoanRateType}
,NeedPrefLoanRates_ {v.database().query<bool>(DB_AllowPrefLoan)}
,NeedHoneymoonRates_ {v.yare_input_.HoneymoonEndorsement}
@@ -659,21 +657,6 @@ void InterestRates::InitializeSeparateAccountRates()
void InterestRates::InitializeLoanRates()
{
- if(!NeedLoanRates_)
- {
- for(int i = mce_annual_rate; i < mc_n_rate_periods; ++i)
- {
- for(int j = mce_gen_curr; j < mc_n_gen_bases; ++j)
- {
- RegLnCredRate_[i][j] = Zero_;
- RegLnDueRate_ [i][j] = Zero_;
- PrfLnCredRate_[i][j] = Zero_;
- PrfLnDueRate_ [i][j] = Zero_;
- }
- }
- return;
- }
-
// Historically, lmi has charged a singular published rate on all
// loans, which necessarily differs for fixed vs. variable loans,
// but was the same for both regular and preferred. In 2015, it
diff --git a/interest_rates.hpp b/interest_rates.hpp
index 3753da5..bb59094 100644
--- a/interest_rates.hpp
+++ b/interest_rates.hpp
@@ -226,7 +226,6 @@ class InterestRates
std::vector<double> Zero_;
// General account interest rates.
-// bool NeedGenAcctRates_; // TODO ?? Would this be useful?
bool NeedMidpointRates_;
mcenum_gen_acct_rate_type GenAcctRateType_;
std::vector<double> GenAcctGrossRate_
@@ -258,7 +257,6 @@ class InterestRates
std::vector<double> MAndERate_[mc_n_gen_bases];
// Loan interest rates.
- bool NeedLoanRates_;
mcenum_loan_rate_type LoanRateType_;
std::vector<double> PublishedLoanRate_;
std::vector<double> PrefLoanRateDecr_;
- [lmi-commits] [lmi] master updated (50d271d -> 3143a30), Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master 4405433 01/15: Expunge disused stable-value calculations [320], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master dd991f3 05/15: Resolve a marked defect [315], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master f74f14c 06/15: Avoid non-const reference arguments, Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master 48caef4 07/15: Resolve a marked defect [313], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master 9b46a92 08/15: Assume genacct and loan rates are always needed [312],
Greg Chicares <=
- [lmi-commits] [lmi] master a7bf1d0 04/15: Remove a duplicative defect marker [316], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master d58eb9b 12/15: Remove assertions that provably cannot fire, Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master bc8e2d9 13/15: Remove a defunct defect marker [307], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master dbac503 14/15: Demote a marked defect [306], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master 791ccce 02/15: Expunge disused stable-value fund charge from database, Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master 9f4e2a2 09/15: Expunge an unused member function [311], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master 387eeaa 10/15: Prepare to resolve some marked defects, Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master cb5e424 11/15: Resolve several marked defects [308], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master 4912e96 03/15: Simplify [317], Greg Chicares, 2021/02/14
- [lmi-commits] [lmi] master 3143a30 15/15: Simplify using expression templates [305], Greg Chicares, 2021/02/14