MathStatement Element
A MathStatement is a predefined hybrid function that can be used during assignment processing for unit linked funds. The functions can find last known fund prices or the next exchange date fund price, when calculating valuation units and amounts. Existing functions include:
-
The ClassMembership function will return an array of ClassGUIDs for the member record in a data Intake file from an input array of ClassGroupGUIDs. The first ClassGUID in the output array would be the class for the record.
- The FindBillDetail creates an output array of BillDetail records based on the values of the input parameters. The array may then be used in the attached rule ‘CreateBill’ to create the aggregated AsBill record. FindBillDetail may be executed multiple times within the activity.
-
The FindBillDetail activity function identifies all pending bill detail records for the given input parameters and places then into an output array that may be passed into the GenerateBill APE rule. This function may be configured to run multiple times inside the same activity to create multiple arrays of bill detail records. StartDate and EndDate parameters define the date range for the pending Bill Detail records based on their Due date. The amount of the Bill Detail record must be between the BillMinimumAmountThreshold and BillMaximumAmountThreshold. The BillGroupGUID matches the BillGroupGUID for the Bill Detail records. The output arrays are; BillDetailPolicyGUIDArray listing all Policy related Bill Detail records, BillDetailClientGUIDArray listing all Client related BillDetailRecords, BillDetailSegmentGUIDArray listing all segment related Bill Detail records, and BillDetailArray listing all of the Bill Detail records.
- The
FindLastExchangeDatePricing
function returns the same exchange date outputs as theFindNextExchangeDatePricing
function. The values of the output parameters are based on the last known price date for each fund with no offsets applied.
- The
FindNextExchangeDatePricing
function allows the system to retrieve the last known prices and dates to be used in the calculations as currently calculated by the Math expression “Valuation:Policy:CashValue”. The input parameter ExchangeDateOffset is an integer value is used to calculate the appropriate Currency Exchange Dates. This value is applied to the Activity’s effective date using the Transaction plan’s marketmaker calendar to find the output parameters GuaranteedCurrencyExchangeDate, GainLossCurrencyExchangeDate, and the RateExists boolean.
- The GetBenefitSplit function will calculate the modal benefit amount for a given date based on a policy’s benefit fund allocation as well as return a collection of the parent funds and amounts used to make up the benefit. Benefit funds may also be explicitly excluded from the calculation in the case of Annual Benefit Leveling”
- The GetFundPositions function will retrieve a collection of parent fund GUIDs where a fund value exists and the fund has values. The Assignment will in turn, derive the correct child funds to use when writing the valuation records. This MathStatement can only be used in transaction Math when the Activity is configured to perform Valuation. Specific funds may be excluded from the positions calculation by including their fund GUID in the ExcludeFunds array.
- The
MathValuation
function will execute the policy valuation as of a specified date for use inside transaction math. All valuation will be executed using the plan configuration (Point-in-Time or from inception). The ValuationDate input parameter specifies the date for which valuation is calculated. The PolicyValues input parameter can be given a value of Yes or No to indicate whether the PolicyValues business rule will execute during the valuation process on each policy. The NearestPrice input parameter indicates whether the valuation is to be calculated with the exact prices as of the ValuationDate (No) or using the last known prices as of the ValuationDate (Yes). The optional ExactPriceDateUsed output parameter returns true or false to indicate whether the fund prices used to value the policy were as of the exact ValuationDates specified (true) or the nearest price dates (false). MathValuation may execute inside Policy level Transaction Math, user defined Functions or CopyBooks.
In order to process unit linked funds, assignment will require that one of these functions exist in Math.
TYPE=ClassMembership | |||
Element | Attribute | Element/Attribute Value and Description | Definition |
<MathStatement> | Opening element for math variable | ||
TYPE | ACIVITYFUNCTION | Required: Defines the math statement type | |
FUNCTIONNAME | ClassMembership | Required: Defines the function to run | |
<Parameters> | Required: Opening element of the parameters. | ||
<Parameter> | Required: Defines the parameters for the function | ||
NAME | ClassGroupArray | Required: Defines the parameter to assign the value. A math variable holding an array of ClassGroupGUIDs for the Data Intake record. | |
TYPE | INPUT | Required: Defines if the parameter is either input or output for the function. | |
<Parameter> | Required: Defines the parameters for the function | ||
NAME | ClassGUIDArray | Optional: Defines the parameter to assign the value. A math variable holding the an array of ClassGUIDs for the Data Intake record. | |
TYPE | OUTPUT | Optional: Defines if the parameter is either input or output for the function |
XML Schema
<MathStatement TYPE="ACTIVITYFUNCTION" FUNCTIONNAME="ClassMembership">
<Parameters>
<Parameter NAME="ClassGroupArray" TYPE="INPUT">[Array of Class GroupGUIDs]</Parameter>
<Parameter NAME="ClassGUIDArray" TYPE="OUTPUT">[MathVariable Array]</Parameter>
</Parameters>
</MathStatement>
TYPE=FindBillDetail | |||
Element | Attribute | Definition | Element/Attribute Value and Description |
<MathStatement> | Opening element for math variable | ||
TYPE | Required attribute:Defines the math statement type |
"ACTIVITYFUNCTION" |
|
FUNCTIONNAME |
Required attribute:Defines the function to run value |
"FINDBILLDETAIL" |
|
<Parameters> |
Opening element of the parameters | ||
<Parameter> |
|
Required attribute:Defines the parameter of the function |
A field or math variable containing a date |
NAME |
Required attribute:Defined input name. |
"StartDate" |
|
TYPE |
Required attribute:Defines if the parameter is either input or output for the function |
"INPUT" |
|
<Parameter> |
|
Defines the parameters for the function |
A field or math variable containing a date |
NAME |
Required attribute:Defines the parameter to assign the value. |
"EndDate" |
|
TYPE |
Required attribute:Predefined MathVariable Type. |
"INPUT" |
|
<Parameter> |
|
Defines the parameters for the function. |
|
NAME |
Required attribute: Defines the parameter to assign the value. |
A field or math variable containing a "BillGroupGUID" |
|
TYPE |
Required attribute:Defines if the parameter is either input or output for the function. |
"INPUT" |
|
<Parameter> |
|
Defines the parameters for the function. |
A field or math variable containing a currency amount |
NAME |
Required attribute:Defines the parameter to assign the value |
"BillMinimumAmountThreshold" |
|
TYPE |
Required attribute:Defines if the parameter is either input or output for the function |
"INPUT" |
|
<Parameter> |
|
Defines the parameters for the function |
A field or math variable containing a currency amount |
NAME |
Required attribute: Defines the parameter to assign the value. |
"BillMaximumAmountThreshold" |
|
TYPE |
Required attribute:Defines if the parameter is either input or output for the function. |
"INPUT" |
|
<Parameter> |
|
Defines the parameters for the function. |
A field or math variable containing a string array |
NAME |
Required attribute: Defines the parameter to assign the value. |
"BillDetailArray" |
|
TYPE |
Required attribute:Defines if the parameter is either input or output for the function. |
"OUTPUT" |
|
<Parameter> |
|
Optional: Defines the parameters for the function (output parameters are optional) |
A field or math variable containing a string array |
NAME |
Required attribute:Defines the parameter to assign the value | “BillDetailPolicyGUIDArray” | |
TYPE |
Optional attribute: Defines if the parameter is either input or output for the function |
“OUTPUT” | |
<Parameter> |
Optional:Defines the parameters for the function (output parameters are optional). |
A field or math variable containing a string array. |
|
NAME |
Required: Defines the parameter to assign the value. |
“BillDetailClientGUIDArray” |
|
TYPE |
Optional:Defines the parameters for the function (output parameters are optional). | “OUTPUT” | |
<Parameter> |
Optional:Defines the parameters for the function (output parameters are optional). |
A field or math variable containing a string array. |
|
NAME |
Required: Defines the parameter to assign the value. |
“BillDetailSegmentGUIDArray” |
|
TYPE |
Optional:Defines the parameters for the function (output parameters are optional). | “OUTPUT” |
XML Schema
<MathStatement TYPE="ACTIVITYFUNCTION" FUNCTIONNAME="FindBillDetail">
<Parameters>
<Parameter NAME="StartDate" TYPE="INPUT">[Date Field or MathVariable]</Parameter>
<Parameter NAME="EndDate" TYPE="INPUT">[Date Field or MathVariable]</Parameter>
<Parameter NAME="BillGroupGUID" TYPE="INPUT">[Text Field or MathVariable]</Parameter>
<Parameter NAME="BillMinimumAmountThreshhold" TYPE="INPUT">[Amount Field or MathVariable]</Parameter>
<Parameter NAME="BillMaximumAmountThreshhold" TYPE="INPUT">[Amount Field or MathVariable]</Parameter>
<Parameter NAME="BillDetailArray" TYPE="OUTPUT">[Array MathVariable]</Parameter>
<Parameter NAME="BillDetailPolicyGUIDArray" TYPE="OUTPUT">[Array MathVariable]</Parameter>
<Parameter NAME="BillDetailClientGUIDArray" TYPE="OUTPUT">[Array MathVariable]</Parameter>
<Parameter NAME="BillDetailSegmentGUIDArray" TYPE="OUTPUT">[Array MathVariable]</Parameter>
</Parameters>
</MathStatement>
XML Example
<MathStatement TYPE="ACTIVITYFUNCTION" FUNCTIONNAME="FindBillDetail">
<Parameters>
<Parameter NAME="StartDate" TYPE="INPUT">Activity:BillingStartDate</Parameter>
<Parameter NAME="EndDate" TYPE="INPUT">Activity:BillingEndDate</Parameter>
<Parameter NAME="BillGroupGUID" TYPE="INPUT">BillOwnerGUIDMV</Parameter>
<Parameter NAME="BillMinimumAmountThreshhold" TYPE="INPUT">Activity:ThreshholdMinimumAmount</Parameter>
<Parameter NAME="BillMaximumAmountThreshhold" TYPE="INPUT">Activity:ThreshholdMaximumAmount</Parameter>
<Parameter NAME="BillDetailArray" TYPE="OUTPUT">BillDetailArrayMV</Parameter>
<Parameter NAME="BillDetailPolicyGUIDArray" TYPE="OUTPUT">BillDetailPolicyGUIDArrayMV</Parameter>
<Parameter NAME="BillDetailClientGUIDArray" TYPE="OUTPUT">BillDetailClientGUIDArrayMV</Parameter>
<Parameter NAME="BillDetailSegmentGUIDArray" TYPE="OUTPUT">BillDetailSegmentGUIDArrayMV</Parameter>
</Parameters>
</MathStatement>
TYPE=FindLastExchangeDatePricing | |||
---|---|---|---|
Element | Attribute | Element/Attribute Value and Description | Definition |
<Math> | |||
<MathVariables> |
|||
<MathStatement> |
Math element executing predefined function code. | ||
TYPE |
ActivityFunction – Literal value only |
|
|
FUNCTIONNAME |
FindLastExchangeDatePricing Literal value only |
Name of Statement Function |
|
<Parameters> |
|||
<Parameter> |
|
Predefined MathVariable Name |
Date: Optional output of the guaranteed exchange date for use in activity math. |
NAME | GuaranteedExchangeDate - Literal value only |
Defined output name. |
|
TYPE | OUTPUT | Function parameter type: Input/Output | |
<Parameter> |
|
Predefined MathVariable Name |
Date: Optional output of the guaranteed gain/loss exchange date for use in activity math. |
NAME |
GainLossExchangeDate - Literal value only | Defined output name. | |
TYPE | OUTPUT | Function parameter type: Input/Output |
XML Schema
<MathStatement TYPE="ACTIVITYFUNCTION" FUNCTIONNAME="FindLastExchangeDatePricing">
<Parameters>
<Parameter NAME="GuaranteedExchangeDate" TYPE="OUTPUT">CurrencyExchangeDate</Parameter>
<Parameter NAME="GainLossExchangeDate" TYPE="OUTPUT">GainLossCurrencyExchangeDate</Parameter>
</Parameters>
</MathStatement>
TYPE=FindNextExchangeDatePricing | |||
---|---|---|---|
Element | Attribute | Element/Attribute Value and Description | Definition |
<Math> | |||
<MathVariables> |
|||
<MathStatement> |
Math element executing predefined function code. | ||
TYPE |
ActivityFunction – Literal value only |
|
|
FUNCTIONNAME |
FindNextExchangeDatePricing Literal value only |
Name of Statement Function |
|
<Parameters> |
|||
<Parameter> |
|
Predefined MathVariable Name |
Integer: Optional input of the offset. |
NAME |
ExchangeDateOffset - Literal value only |
Defined input name. |
|
TYPE |
INPUT |
Function parameter type: Input/Output |
|
<Parameter> |
|
Predefined MathVariable Name |
Date: Optional output of the guaranteed exchange date for use in activity math. |
NAME |
GuaranteedExchangeDate - Literal value only |
Defined output name. |
|
TYPE |
INPUT |
Function parameter type: Input/Output |
|
<Parameter> |
|
Predefined MathVariable Name |
Date: Optional output of the guaranteed gail/loss exchange date for use in activity math. |
NAME |
GainLossExchangeDate - Literal value only |
Defined output name. |
|
TYPE |
INPUT |
Function parameter type: Input/Output |
|
<Parameter> |
|
Predefined MathVariable Name |
Date: Optional output of the rates that exist. |
NAME |
RatesExist - Literal value only |
Defined output name. |
|
TYPE |
INPUT |
Function parameter type: Input/Output |
XML Schema
<MathStatement TYPE="ACTIVITYFUNCTION" FUNCTIONNAME="FindNextExchangeDatePricing">
<Parameters>
<Parameter NAME="ExchangeDateOffset" TYPE="INPUT">InputOffset</Parameter>
<Parameter NAME="GuaranteedExchangeDate" TYPE="OUTPUT">CurrencyExchangeDate</Parameter>
<Parameter NAME="GainLossExchangeDate" TYPE="OUTPUT">GainLossCurrencyExchangeDate</Parameter>
<Parameter NAME="RatesExist" TYPE="OUTPUT">RatesExist</Parameter>
</Parameters>
</MathStatement>
TYPE=GetBenefitSplit | |||
---|---|---|---|
Element | Attribute | Element/Attribute Value and Description | Definition |
<MathStatement> |
Opening element for the math variable. | ||
TYPE |
ACIVITYFUNCTION |
Required: Defines the math statement type. |
|
FUNCTIONNAME |
GetBenefitSplit |
Required:Defines the function to run | |
<Parameters> |
Required:Opening element of the parameters. | ||
<Parameter> |
|
Required: Defines the parameters for the function | |
NAME |
SegmentGUID | Required:Defines the parameter to assign the value. A math variable holding the related segment for the BenefitSplit record. | |
TYPE |
INPUT | Required: Defines if the parameter is either input or output for the function. | |
<Parameter> |
|
Optional: Defines the parameters for the function | |
NAME |
EffectiveDate | Required:Defines the parameter to assign the value. A math variable holding the valuation effective date for AsNetAssetValue records. | |
TYPE |
INPUT | Required:Defines if the parameter is either input or output for the function | |
<Parameter> |
|
Optional: Defines the parameters for the function | |
NAME |
BenefitSplitTypeCode | Required: Defines the parameter to assign the value. A math variable or literal value indicating the BenefitSplit type code to retrieve. | |
TYPE |
INPUT | Required:Defines if the parameter is either input or output for the function. | |
<Parameter> |
|
Optional: Defines the parameters for the function | |
NAME |
ABLIndicator | Required: Defines the parameter to assign the value. A math variable holding either Yes or No, indicates if ABL is in effect and variable benefit is to be suppressed. | |
TYPE |
INPUT | Required: Defines if the parameter is either input or output for the function | |
<Parameter> |
|
Optional: Defines the parameters for the function | |
|
NAME | ExcludeFunds | Required:Defines the parameter to assign the value. An array of none or more benefit fund GUIDs to exclude from the calculated output. |
|
TYPE | INPUT | Required:Defines if the parameter is either input or output for the function |
<Parameter> |
|
Optional: Defines the parameters for the function | |
|
NAME | BenefitAmount | Required: Defines the parameter to assign the value. Gross Benefit amount in Plan default currency |
|
TYPE | OUTPUT | Optional:Defines if the parameter is either input or output for the function |
<Parameter> |
|
Optional: Defines the parameters for the function | |
|
NAME | ParentFundAmountCollection | Required:Defines the parameter to assign the value. Collection of Parent Fund GUID and Benefit Allocation Amounts in decimal values (Highest level parent to the benefit fund). |
|
TYPE | OUTPUT | Optional:Defines if the parameter is either input or output for the function |
XML Schema
<MathStatement TYPE=”ACTIVITYFUNCTION” FUNCTIONNAME="[GetBenefitSplit]">
<Parameters>
<Parameter NAME=”SegmentGUID” TYPE="INPUT">[MathVariable SegmentGUID]</Parameter>
<Parameter NAME=”EffectiveDate” TYPE="INPUT">[Date]</Parameter>
<Parameter NAME=”BenefitSplitTypeCode” TYPE="INPUT">[MathVariable Type Code]</Parameter>
<Parameter NAME=”ABLIndicator” TYPE="INPUT">[Yes|No]</Parameter>
<Parameter NAME=”ExcludeFunds” TYPE="INPUT">[Fund GUID Array]</Parameter>
<Parameter NAME=”BenefitAmount” TYPE="OUTPUT”>[MathVariable Numeric]</Parameter>
<Parameter NAME=”ParentFundAmountCollection” TYPE="OUTPUT”>[MathVariable Collection]</Parameter>
<Parameters>
</MathStatement>
TYPE=GetFundPositions | |||
---|---|---|---|
Element | Attribute | Element/Attribute Value and Description | Definition |
<Math> | |||
<MathVariables> |
|||
<MathStatement> |
Math element executing predefined function code. | ||
TYPE |
Activity Function– Literal value only |
|
|
FUNCTIONNAME |
GetFundPositions Literal value only |
Retrieves a policy’s parent fund guid that have fund values |
|
<Parameters> |
|||
<Parameter> |
|
Predefined MathVariable Name |
Integer: Optional input of the offset. |
A math variable containing an array of valuation fund GUIDs. An empty array is acceptable. | Required. Defines the parameters for the function | ||
NAME |
ExcludeFunds - Literal value only |
Array of fund types that should not be included in the fund position determination |
|
TYPE |
INPUT |
Function parameter type: Input/Output |
|
<Parameter> |
|
Predefined MathVariable Name |
Date: Optional output of the guaranteed exchange date for use in activity math. |
NAME |
ParentFundCollectionAmount - Literal value only |
Collection of parent fund guids and values. |
|
TYPE |
OUTPUT |
Output Collection |
|
<Parameter> |
|
Predefined MathVariable Name |
Date: Optional output of the guaranteed gail/loss exchange date for use in activity math. |
NAME |
GainLossExchangeDate - Literal value only |
Defined output name. |
|
TYPE |
INPUT |
Function parameter type: Input/Output |
|
<Parameter> |
|
Predefined MathVariable Name |
Date: Optional output of the rates that exist. |
NAME |
RatesExist - Literal value only |
Defined output name. |
|
TYPE |
INPUT |
Function parameter type: Input/Output |
|
<Parameter>
|
|
A math variable defining a collection. The function output is a collection of Parent Fund GUIDs and related percentages. |
Optional: Defines the parameters for the function. |
NAME | “ParentFundPercentAmount ” | Required: Defines the parameter to assign the value. | |
TYPE | “OUTPUT” | Optional: Defines if the parameter is either input or output for the function |
XML Schema
<MathStatement TYPE=”ACTIVITYFUNCTION” FUNCTIONNAME="GetFundPositions">
<Parameters>
<Parameter NAME=”ExcludeFunds” TYPE="INPUT">[MathVariable Array]</Parameter>
<Parameter NAME=”ExcludeFunds” TYPE="INPUT">FundTypeArray</Parameter>
<Parameter NAME=”ParentFundAmountCollection” TYPE="OUTPUT”>OutputCollection</Parameter>
<Parameter NAME=”ParentFundPercentCollection” TYPE="OUTPUT">[MathVariable Collection]</Parameter>
<Parameters>
</MathStatement>
TYPE=MathValuation | |||
---|---|---|---|
Element | Attribute | Element/Attribute Value and Description | Definition |
<Math> | |||
<MathVariables> |
|||
<MathStatement> |
Math element executing predefined function code. |
||
TYPE |
ActivityFunction Literal value only. |
|
|
FUNCTIONNAME |
MathValuation |
Required: Name of Statement Function. |
|
<Parameters> |
|
||
<Parameter> |
A field or math variable containing a date. Must be a Date datatype. |
Required: Defines the date for valuation. |
|
NAME |
ValuationDate Literal value only. |
Required: Defines the valuation date. |
|
TYPE |
INPUT |
Required: Function parameter type: Input/Output. |
|
<Parameter> |
A literal or a field or math variable containing a "Yes" or "No" text string. |
Required: Specifies whether the PolicyValues business rule will execute during the valuation process on each policy. |
|
NAME |
PolicyValues Literal value only. |
Required: Defines the parameter to assign the value |
|
TYPE |
INPUT |
Required: Function parameter type: Input/Output. |
|
<Parameter> |
A literal or a field or math variable containing a "Yes" or "No" text string. |
Required: No: Indicates the valuation is to be calculated with the exact prices as of the ValuationDate. Yes: valuation is to be calculated using the last known prices as of the ValuationDate. If this value is set to No and there are no prices for the specified valuation date, a business error is thrown indicating fund prices do not exist for the specified valuation date. |
|
NAME |
NearestPrice Literal value only. |
Required: Defines the parameter to assign the value |
|
TYPE |
INPUT |
Required: Function parameter type: Input/Output. |
|
<Parameter> |
A field or math variable containing a text value of "true" or "false". |
Optional: The ExactPriceDateUsed output parameter returns true or false to indicate whether the fund prices used to value the policy were as of the exact ValuationDates specified (true) or the nearest price dates (false). The NearestPrice parameter must be set to "Yes" to use this output. If NearestPrice is set to “No” the output value will always be ‘true’ when the activity processes. |
|
NAME |
ExactPriceDateUsed Literal value only. |
Required: A math variable to hold the function output. |
|
TYPE |
OUTPUT |
Optional:Function parameter type: Input/Output. |
|
<Parameter> |
Yes: Financial entry calculations and math will need to be executed in PolicyValues BR. IsValueFinancialEntry context value will be assigned a value as Yes. No: No financial entry calculation in PolicyValues IsValueFinancialEntry will have value No . Default Value ="No" |
Optional: Defines the parameter to assign value. | |
NAME | ValueFinancialEntry | Required: Assign Values for Parameter Literal Value or Field Value or MathVaraible. | |
TYPE | INPUT | Required: Function parameter type. |
XML Schema
<MathStatement TYPE=”ACTIVITYFUNCTION” FUNCTIONNAME="MathValuation">
<Parameters>
<Parameter NAME=”ValuationDate” TYPE="INPUT">MyValuationDate</Parameter>
<Parameter NAME=”PolicyValues” TYPE="INPUT">Yes</Parameter>
<Parameter NAME=”NearestPrice” TYPE="INPUT">Yes</Parameter>
<Parameter NAME=”ExactPriceDateUsed” TYPE="OUTPUT">ExactPriceDateUsedMV</Parameter>
<Parameter NAME=”ValueFinancialEntry” TYPE="INPUT">Yes|No| OR MathVariable or Field with Values(Yes|No)</Parameter></Parameters>
</MathStatement>