Transfer Pricing Algorithm

From Wiki Algonomia
Jump to navigation Jump to search

Introduction

Context

Welcome to the OpenSource Transfer Pricing Algorithm with Tax Impact Computation wiki page! This platform serves as a comprehensive resource for understanding and implementing a pioneering open-source algorithm specifically designed to calculate and analyze transfer pricing and its subsequent tax implications.

Transfer pricing is a pivotal aspect of international trade and finance, playing a crucial role in determining the value at which transactions occur between associated enterprises. It significantly influences the allocation of income, expenses, and consequently, tax liabilities among different tax jurisdictions. The meticulous computation of tax impact is imperative for businesses to ensure compliance, optimize tax obligations, and foster fiscal transparency.

Objectives

The objective of this algorithm is to perform transfer pricing computations on a dataset from a company, produce the transfer prices and/or make adjustments to the transfer pricing, and, if configured, calculate the subsequent tax impact. This includes both National taxation and bilateral taxation, addressing complex Withholding tax treatments that may arise. Additionally, the algorithm's output can include suggestions for algorithmically improved margin rates that could reduce the overall tax burden.

Feature Overview

The algorithm will present the following features:

General logic of the algorithm

Development Program

The Transfer Pricing Algorithm presented in this page is an ongoing work and its documentation on this wiki is also a work in progress. It is by no means complete and definitive, and changes will occur in the upcoming weeks and months.

Both GitHub and MediaWiki are amazing tools to manage collaborative work and track the progress and modifications that happen with time.

The detailed to-do list is presented Transfer Pricing Algorithm Development Program.

Data structure

Structure overview

Algonomia API Framework

The Transfer Pricing Algorithm uses Algonomia API Framework to receive input data and send output data for the computations. In the following sections, it is assumed that data has been transferred to the Transfer Pricing Algorithm using this framework.

Input

The input data follows the usual division required by the Algonomia API Framework : Data, Rules, Other.

Data

The following tables presents the data points allowed as "Data" :

Input Data Points
Role Label Definition Typing Multiplicity behavior Mandatory
Matching ATP Declaring Entity segmentation Allows to define the segmentation of the data input that corresponds to the base aggregation level for the Transfer Pricing Computation (PLIs will be aggregated at this level of segmentation) Couple (String; Integer) Several Values can be defined as "ATP Declaring Entity segmentation", but the Integer has to be unique among the set Yes
Matching ATP Tax Payer Allows to define the segmentation of the data input that corresponds to the aggregation level for the Tax computation, it is necessarily a subset of the ATP Declaring Entity segmentation defined Boolean Completes the definition of the ATP Declaring Entity segmentation with a boolean (String; Integer; Boolean) No, if absent no tax computation are performed
Matching ATP Counterpart Entity segmenfation Allows to define the segmentation of the data input that corresponds to the base aggregation level for the Transfer Pricing Computation (PLIs will be aggregated at this level of segmentation), if it is not defined or null for certain data entries the Counterpart entities will be sourced from the associated Rules Couple (String; Integer) Several Values can be defined as "ATP Counterpart Entity segmentation", but the Integer has to be unique among the set No, if absent the Counterpart entity may be automatically defined using the Rules file
Financials ATP Assets Represents the assets employed by the entity, which are considered in the transfer pricing computation Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Financials ATP Capital Employed Refers to the total capital (both equity and debt) used by the entity in its operations Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Financials ATP Sales Denotes the total revenue generated by the entity from sales of goods or services Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Financials ATP OG Sales Stands for Out of Group Sales, representing the total revenue generated by the entity from sales of goods or services to parties that are not part of the same group or entity, hence outside of the related or affiliated entities Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Financials ATP COGS Stands for Cost of Goods Sold, indicating the direct costs attributable to the production of the goods sold by the entity Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Financials ATP Royalty paid Represents the amounts paid by the entity for the use of intellectual property or other assets owned by related parties Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Financials ATP Management fee received Indicates the fees received by the entity for providing management services to related parties Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Financials ATP Operating Expenses Denotes the daily operational costs of an entity, distinct from other expenses such as COGS and management fees Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Financials ATP Profit Indicator A measure or indicator used to assess the profitability of the entity in the context of transfer pricing Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Taxation ATP PBT Refers to Profit Before Tax, indicating the entity’s profit before the deduction of taxes Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Taxation ATP Tax losses carryforward N Represents the tax losses incurred in the current year (N), where "N" denotes the present or most recent tax year. These losses can be carried forward to offset future taxable profits, subject to applicable laws and regulations Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Taxation ATP Tax losses carryforward N-1 Represents the tax losses from the previous year (N-1), where "N-1" refers to the year immediately preceding the current year (N). These losses can be carried forward to offset profits in subsequent years, according to the relevant tax laws. Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Taxation ATP Tax expenses Indicates the total tax expenses incurred by the entity Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Transfer Pricing ATP Firm Creation Date Refers to the date on which the entity was established or created Couple (Decimal;ISO 3 Currency Code) Not allowed No
Transfer Pricing ATP Base for Royalty Represents the basis or calculation used for determining the royalty payments made or received by the entity Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, assumed to be 0
Transfer Pricing ATP Cost Base for Management fee Indicates the cost structure or basis used to calculate the management fees charged or received by the entity Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, related TPA =0
Transfer Pricing ATP Consumption Base for Management fee Denotes the consumption or usage basis used for determining management fees charged to the entity Decimal or Couple (Decimal;ISO 3 Currency Code) If multiple defined, are aggregated for computation No, if absent and required by computation, related TPA =0

Rules

The following tables presents the data points allowed as "Rules" :

Input Rules data points
Role Label Definition Typing Multiplicity behavior Mandatory
Matching ATP Rule segmentation Allows to define the segmentation level of the Rule component to be retrieved Couple (String; Integer) Several Values can be defined as "ATP Rule segmentation", but the Integer has to be unique among the set Yes
Matching ATP Counterpart Entity segmentation Allows to define the segmentation that defines the Counterpart Entity, it is recommended to use the same definition as the Declaring Entity segmentation to allow for smooth computations for the counterpart entities and their tax impacts Couple (String; Integer) Several Values can be defined as "ATP Counterpart entity segmentation", but the Integer has to be unique among the set No, if absent from the data as well, no TP computations are possible
Transfer Pricing ATP TP method Identifies the specific transfer pricing method the algorithm will employ to establish and assess arm’s length prices between associated entities Single choice Enum : {TNMM ; ROA; TNMM ROCE; TNMM ROS; TNMM ROOGS; TNMM ROCOGS; TNMM ROOE / Berry ratio; TNMM ROC; Royalty ; Management fee} Only one value is acceptable for a given segment of the analysis, see Rule mapping Yes
Transfer Pricing ATP Benchmark fisrt quartile Represents the lower quartile in a distribution of comparable data, establishing the benchmark's lower boundary for the algorithm's transfer pricing analysis percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, computation is aborted
Transfer Pricing ATP Benchmark third quartile Denotes the upper quartile in a distribution of comparable data, setting the benchmark's upper boundary for the algorithm’s transfer pricing considerations percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, computation is aborted
Transfer Pricing ATP Benchmark target below Represents the target value of the KPI if the initial value computed is below the ATP Benchmark first quartile percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, computation is aborted
Transfer Pricing ATP Benchmark target in Represents the target value of the KPI if the initial value computed is between the ATP Benchmark first and third quartile percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, computation is aborted
Transfer Pricing ATP Benchmark target above Represents the target value of the KPI if the initial value computed is above the ATP Benchmark third quartile percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, computation is aborted
Transfer Pricing ATP in scope Flags whether a given transaction is considered relevant for the considered entities Boolean Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if absent is considered True
Transfer Pricing ATP Date inferior Represents the earliest creation date for which Entities are considered relevant and included in the algorithm's transfer pricing analysis Date Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if absent or null, no constraints on the creation date
Transfer Pricing ATP Date superior Represents the latest termination date for which Entities are considered relevant and included in the algorithm's transfer pricing analysis Date Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if absent or null, no constraints on the termination date
Transfer Pricing ATP Rule application modulation Defines the different conditions under which the Transfer Computation will be launched Multiple Choice Enum : {if below; if within; if above} Only one value is acceptable for a given segment of the analysis, see Rule mapping Yes
Transfer Pricing ATP accounting Impact for Declaring entity Defines the accounting implications on the Declaring Entity resulting from the transfer pricing transaction as processed by the algorithm Single Choice Enum : {Only Profit indicator; Operating expenses; Sales; COGS} Only one value is acceptable for a given segment of the analysis, see Rule mapping Yes
Transfer Pricing ATP accounting Impact for Counterpart entity Defines the accounting implications on the Counterpart Entity resulting from the transfer pricing transaction as processed by the algorithm Single Choice Enum : {Only Profit indicator; Operating expenses; Sales; COGS} Only one value is acceptable for a given segment of the analysis, see Rule mapping Yes
National taxation ATP National tax rate Input of the applicable national tax rate affecting the entity's income as considered by the algorithm in its transfer pricing computation percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, National tax computation is aborted
National taxation ATP Tax losses carryforward depreciation Defines the depreciation applied to tax losses that are carried forward, impacting the entity's future taxable income in the algorithm percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if absent or null =0
National taxation ATP Tax loss carryforward ceiling for use Denotes the maximum amount of the tax loss from previous years that the algorithm allows to be utilized to offset current taxable income, before the application of the ATP Share of Tax losses carryforward percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if absent or null, no ceiling
National taxation ATP Share of Tax losses carryfoward Determines the proportion of previous years’ tax losses, above the ATP Tax loss carryforward ceiling for use that the algorithm allows the entity to carry forward and offset against future profits percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if absent or null =0
Withholding Taxes ATP WHT Determines which or whether specific Withholding tax parameters will be applied Single Choice Enum : {Royalty; Mgt fees; Other transactions; None} Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, WHT computation is aborted (=None)
Withholding Taxes ATP WHT Rates - Royalties Specifies the applicable withholding tax basis on royalties used by the algorithm to determine tax liability on royalty income in the source jurisdiction. percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, National tax computation is aborted
Withholding Taxes ATP WHT Base - Royalties Defines the income base to which the withholding tax rate on royalties is applied by the algorithm percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =1
Withholding Taxes ATP WHT Deductibility - Royalties Determines the extent to which withholding tax on royalties is deductible in the source jurisdiction, impacting the overall tax obligation as calculated by the algorithm percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =1
Withholding Taxes ATP specific rate - Royalties Refers to the specified tax rate applied to royalties that the algorithm uses to calculate the tax on royalty income in the target jurisdiction percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, National tax computation is aborted
Withholding Taxes ATP Rate of exemption - Royalties Denotes the rate at which withholding taxes from royalties are exempt from taxation in the target jurisdiction, as utilized by the algorithm in its computations. The exempted share does not generate tax credits percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =0
Withholding Taxes ATP Tax credits - Royalties Represents the rate at which tax credits are available in the target jurisdiction against the non exempted shared of withholding tax on royalties, as factored into the algorithm's calculations percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =0
Withholding Taxes ATP WHT Rates - Mgt fees Specifies the applicable withholding tax rates on Mgt fees used by the algorithm to determine tax liability on royalty income in the source jurisdiction. percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, National tax computation is aborted
Withholding Taxes ATP WHT Base - Mgt fees Defines the income base to which the withholding tax rate on Mgt fees is applied by the algorithm percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =1
Withholding Taxes ATP WHT Deductibility - Mgt fees Determines the extent to which withholding tax on Mgt fees is deductible in the source jurisdiction, impacting the overall tax obligation as calculated by the algorithm percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =1
Withholding Taxes ATP specific rate - Mgt fees Refers to the specified tax rate applied to Mgt fees that the algorithm uses to calculate the tax on royalty income in the target jurisdiction percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, National tax computation is aborted
Withholding Taxes ATP Rate of exemption - Mgt fees Denotes the rate at which withholding taxes from Mgt fees are exempt from taxation in the target jurisdiction, as utilized by the algorithm in its computations. The exempted share does not generate tax credits percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =0
Withholding Taxes ATP Tax credits - Mgt fees Represents the rate at which tax credits are available in the target jurisdiction against the non exempted shared of withholding tax on Mgt fees, as factored into the algorithm's calculations percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =0
Withholding Taxes ATP WHT Rates - Other transactions Specifies the applicable withholding tax rates on Other transactions used by the algorithm to determine tax liability on royalty income in the source jurisdiction. percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, National tax computation is aborted
Withholding Taxes ATP WHT Base - Other transactions Defines the income base to which the withholding tax rate on Other transactions is applied by the algorithm percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =1
Withholding Taxes ATP WHT Deductibility - Other transactions Determines the extent to which withholding tax on Other transactions is deductible in the source jurisdiction, impacting the overall tax obligation as calculated by the algorithm percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =1
Withholding Taxes ATP specific rate - Other transactions Refers to the specified tax rate applied to Other transactions that the algorithm uses to calculate the tax on royalty income in the target jurisdiction percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, National tax computation is aborted
Withholding Taxes ATP Rate of exemption - Other transactions Denotes the rate at which withholding taxes from Other transactions are exempt from taxation in the target jurisdiction, as utilized by the algorithm in its computations. The exempted share does not generate tax credits percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =0
Withholding Taxes ATP Tax credits - Other transactions Represents the rate at which tax credits are available in the target jurisdiction against the non exempted shared of withholding tax on Other transactions, as factored into the algorithm's calculations percentage Only one value is acceptable for a given segment of the analysis, see Rule mapping No, if required but absent, =0

Other

Output

Serie of files

A series of structured files corresponds to the selection of a sequence of structured files whose data and rules can be processed in a coordinated manner in the dashboard or the calculations of the algorithm.

The selected structured files must form a sequence where their temporal referencing perimeters follow each other in a disjointed and adjacent manner (e.g., a succession of months, quarters, years).

Impact of series on Financial data

Initially, these relative temporal reference values are sought within the same structured file, and then in the preceding structured file that corresponds to the correct relative reference in the matching file within the sequence.

Only one single value works this way for TP computation : ATP Tax losses carry-forward N-1.

Impact of rules

The optimization calculation will be further impacted as transfer pricing rules can cover a reference period exceeding a single structured file. The optimization calculation will then treat the rule file variable as a shared variable.

Computational steps

Data received by the algorithm are processed using the standardized Rule matching methodology. At this stage every single entry contains both the financial data and the rules to be applied for both Transfer Pricing Computation and Tax impact computation.

Transfer pricing computation

The transfer pricing computation is segmented into the following steps :

  • Core TP computation step : during which the Transfer Pricing margin will be computed based on the TP rule,
  • Impact on other accounts and Profit level indicators : at this stage, the different accounts need to be updated based on the TP amounts and/or adjustments computed,
  • Convergence mechanisms : as some of the accounts updated at the previous stage can be the base of other TP computations, both previous steps need to be recomputed iteratively to ensure that TP amounts do not change anymore,

Core TP computation step

The transfer pricing calculation is broken down into two parts:

  • The TPA issued by the declarant as the tested party
  • The TPA received by the counterparty as the non-tested party

They will be respectively denoted as TPA_d and TPA_c, and the net TPA will then be formed by the sum of these two components.

TPA issued – TPA_d

The TPA is calculated by determining the amount that sets the ratio corresponding to the chosen KPI to its target value based on its value and the applicable rule. Let's denote the target value of this ratio as Target_ratio, and we then have the following table to calculate the TPA_d in the different cases.

TP method KPI Name KPI Formula TPA Formula par ATP accounting impact
Only PBT Operating expenses Sales
TNMM ROA Return on Asset ROA = ATP Profit Indicator / ATP Assets TPA_d = Target_ratio x ATP Assets – ATP Profit Indicator
TNMM ROCE Return on Capital Employed ROCE = ATP Profit Indicator / ATP Capital Employed TPA_d = Target_ratio x ATP Capital Employed – ATP Profit Indicator
TNMM ROS Return on Sales ROS = ATP Profit Indicator / ATP Sales TPA_d = Target_ratio x ATP Sales – ATP Profit Indicator TPA_d = (Target_ratio x ATP Sales – ATP Profit Indicator)/(1 – Target_ratio )
TNMM ROOGS Return on Out of Group Sales ROOGS = ATP Profit Indicator / ATP OG Sales TPA_d = Target_ratio x ATP OG Sales – ATP Profit Indicator
TNMM ROCOGS Return on Costs of Goods Solds ROCOGS = ATP Profit Indicator / ATP COGS TPA_d = Target_ratio x ATP COGS – ATP Profit Indicator
TNMM ROOE / Berry ratio Return on Operating Expenses / Berry Ratio ROOE = ATP Profit Indicator / ATP Operating Expenses TPA_d = Target_ratio x ATP ROOE – ATP Profit Indicator
TNMM ROC Return on Costs ROC = ATP Profit Indicator / (ATP Sales – ATP Profit Indicator) TPA_d = Target_ratio/(1 + Target_ratio ) x ATP Sales – ATP Profit Indicator TPA_d = Target_ratio x ATP Sales – ATP Profit Indicator x (1 + Target_ratio )
Royalty Royalty rate Royalty Rate = ATP Royalty Paid / ATP Base for Royalty TPA_d = (-1) x (Target_ratio x ATP Base for Royalty – ATP Royalty Paid )*
Management fee Management fee rate Management fee rate = ATP Management fee received / ATP Cost Base for Management fees TPA_d = Target_ratio x ATP Cost Base for Management fees – ATP Management fee received

*The TPA remains primarily a delta of the Profit Indicator.

TPA received – TPA_c

In most cases, the TPA_c simply corresponds to the sum of the TPA_d results from calculations for which the studied entity is the counterparty, multiplied by (-1).

Indeed, this reflects that the non-tested parties are impacted in the opposite way by the TPA.

The only exception to this rule concerns the TPA_c stemming from TPA_d whose TP method is "Management fees."

In this case, the value ATP Cost Base for Management fees_total_d should be formed, which corresponds to the sum of the ATP Cost Base for Management fees from all the counterparty entities for the "Management fee" method relating to the concerned declaring entity.

Let's take a declaring entity d1.

We then have the contribution to TPA_c from the TPA with d1 written as: TPA_c_d1 = TPA_dx ATP Cost Base for Management fees / ATP Cost Base for Management fees_total_d1.

Impact on other accounts and Profit level indicators

Whether it's the declaring entities or the counterparties, transfer pricing calculations can have consequences on other data based on the company's accounting choices. We will detail these impacts from the most general to the most specific cases, for both declaring entities and counterparties. It is important to note that tax calculation is not done at this stage.

Unaffected Financials

None of the values outside those tagged as "financials" are affected. Moreover, ATP Assets, ATP Capital Employed, and ATP OG Sales are never affected.

Values impacted in a fixed manner

We always have for ATP Profit Indicator: ATP Profit Indicator = ++TPA = ++(TPA_d+TPA_c)

Values impacted in a fixed manner depending on the method choice

ATP TP method = Royalty fee :

ATP Royalty paid = --TPA_d (since TPA_d is the impact on profit) ATP Royalty received = ++TPA_c (filtered on transactions for which the entity is the counterparty of a royalty flow)

ATP method = Management fee ATP Management fee received =++TPA_d ATP Management fee received = --TPA_c (filtered on transactions for which the entity is the counterparty of a management fee flow)

Values impacted according to the accounting mode

The impact modalities on ATP Sales, ATP COGS, and ATP Operating Expenses are determined by the rule and are applied for each individual flow. As TPA_d is positively signed in relation to the Profit indicator, we generally have the following sign management implications:

  • ATP Sales =++(TPA_d - TPA_c) (having only kept the elements impacting Sales for declaring or counterpart)
  • ATP COGS= --(TPA_d + TPA_c) (having only kept the elements impacting COGS for declaring or counterpart)
  • ATP Operating Expenses = --(TPA_d + TPA_c) (having only kept the elements impacting COGS for declaring or counterpart)

Convergence mechanism

The calculations in the two first steps aim to bring each of the KPIs closer to their target ratio. Since some values updated are included in the calculation of these KPIs, it is necessary to iterate multiple times, calculating successive TPA values. The returned values will then be for the TPA: the sum of the TPA from each step and for each indicator, its converged value.

However, it should be noted that "cycles" are likely to be formed with feedback loops between the different financial indicators.

Moreover, the assertion that each node has only one unique successor is no longer true due to the distribution mechanics of the management fees step.

To track this convergence, we propose the following methodology:

  1. Retain the TPA values of each declarant for each calculation step.
  2. Convergence is achieved when the sum of the absolute values of the TPA falls below an arbitrary value (to be defined).
  3. Assuming that this value starts to grow again after a period of decline, after an arbitrarily set number of iterations between 10 and 1% of the number of declarants, an arbitrary number of additional iterations will be carried out (again between 10 and 1% of the number of declarants) before returning all the "converged" values and returning an error for all other "cycles".
  4. The process stops after 20 iterations (to be studied),
  5. Sum all the TPA values compute throughout the iterations to generate the total TPA.

Tax impact computation

Tax computation will be divided into 3 stages:

  • A flow by flow computation of Withholding taxes effects
  • A Tax payer level computation of the consumption or creation of Tax losses
  • A Tax payer level computation of the final taxation level

Withholding taxes initial computation

The WHT is treated as an additional expense on the side of the entity paying the related flow.

This means that it is potentially deductible in whole or in part.

Furthermore, upon its arrival in the jurisdiction of the receiving entity, to avoid double taxation, the concerned payment can:

  • Be exempted at a given rate (thus, the corresponding portion needs to be removed from the recipient's tax base)
  • Be taxed at a specific rate to be specified (specific rate, set equal to the national tax rate if the same), on the non-exempted portion
  • Generate a tax credit at a set rate on the non-exempted portion, applicable only to the tax for the year.

Delta WHT TP due (thus paid by others) =

  • Delta WHT Royalty due = Sum for all declaring entities of (WHT rate x WHT Base x TPA_c )
  • Delta WHT Management fee due = …

Delta WHT paid (settled for others) =

  • Delta WHT Royalty paid = - WHT rate x WHT Base x TPA_d
  • Delta WHT Management fee paid = …

Possible WHT Tax credits =

  • Additional Tax credit royalty due = (-1) x Sum for all declaring entities of (WHT rate x WHT Base x TPA_c x Tax credits x (1-rate of exemption))
  • Additional Tax credit management fees due = …

Delta PBT WHT due =

  • Delta PBT WHT Royalty due = (-1) x Sum for all declaring entities of (WHT Base x WHT Rate x TPA_c x rate of exemption)
  • Delta PBT WHT Management fee due =

Delta PBT WHT paid =

  • Delta PBT WHT Royalty paid = WHT Rate x WHT Base x TPA_d x WHT Deductibility
  • Delta PBT WHT Management fee paid = …

Tax losses treatments

Within the framework of the loss carry-forward computation, we start with the following simplifications:

  • Not knowing the application modalities before calculation, these are recalculated in a simplified manner to retain uncaptured effects (see "Unexplained").
  • The losses are added to a simplified common basket, which will be taxed at an average rate of the taxpayer.
  • The mechanisms at the boundaries of tax groups are ignored.

From this point forward all values are aggregated at Tax payer level.

TLCF_consumed_init = max(0; (TLCF_N-1 x (1-TLCF_depreciation) – TLCF_N))

Unexplained_Consumed_TLCF = TLCF_consumed_init - min(TLCF_N-1 x (1-TLCF_depreciation); MAX(0; min(TLCF_ceiling; ATP PBT)) + Share_TLCF x max(0; ATP PBT - TLCF_ceiling))

TLCF_created_init = - min(0; (TLCF_N-1 x (1-TLCF_depreciation) – TLCF_N)

Unexplained_Created_TLCF = TLCF_created_init + min(0; ATP PBT)

Delta_PBT = TPA

New_ATP_PBT = ATP PBT + Delta_PBT + Delta PBT WHT (paid + due)

TLCF_created_new = max(0; -min(0; New_ATP_PBT) + Unexplained_Created_TLCF)

TLCF_consumed_new = max(0; min(TLCF_N-1 x (1-TLCF_depreciation); min(TLCF_ceiling; New_ATP_PBT) + Share_TLCF x max(0; New_ATP_PBT - TLCF_ceiling) + Unexplained_consumed_TLCF)

New_TLCF_N = TLCF_N-1 x (1-TLCF_depreciation) + TLCF_created_new + TLCF_consumed_new

Final tax computation

Delta Tax init = Sum of National tax rate x TPA - Sum((National rate – Specific rate) x TPA_c _royalty received)

We must ensure that any possible blank counterpart line correctly matches with tax rules.

Average taxpayer tax rate = Delta Tax init/Delta PBT

Delta_Tax_bis = Max(-max(0; tax expense); Delta Tax init - Average taxpayer tax rate x (TLCF_consumed_new - TLCF_consumed_init + TLCF_created_new – TLCF_created_init))

Consumable tax credit = Max(0; Tax expenses + Delta_Tax_bis - Possible WHT Tax credits)

Tax_final = Delta_Tax_bis - Consumable WHT Tax credits + WHT TP due

Tax performance analysis

Operation of the calculation algorithm in an optimization context:

Description of the optimization problem

Optimization under constraints:

Objective function: Sum of the input ATP Tax expenses and the output ATP Delta Tax at the exit the Final tax computation for the entire group, and/or the entire file series.

Constraints defined by the ATP Benchmark tags from the rule files, considering for each unique rule:

  • ATP Benchmark first quartile as the lower bound,
  • ATP Benchmark third quartile as the upper bound,
  • ATP Benchmark target below/in/above as the input variables.

If several structured files are configured with the same rule file, they can either be configured as separate variables or as single unique variable across the different structured files.

The goal is to find a local minimum of the objective function while respecting the constraints mentioned above.

Resolution with genetic algorithm

Recommended algorithm: CMA-ES

http://www.cmap.polytechnique.fr/~nikolaus.hansen/javadoc/fr/inria/optimization/cmaes/package-summary.html

https://github.com/CMA-ES/libcmaes

https://pypi.org/project/cmaes/

Tax impact reallocation

The allocation keys for the various tax outputs are as follows:

  • ATP PBT -> linear
  • ATP Delta Tax: pro rata to (Delta PBT + Delta PBT WHT (paid + due)) within the tax payer's bounds
  • ATP Tax losses carry forward N pro rata to (Delta PBT + Delta PBT WHT (paid + due)) within the tax payer's bounds
  • ATP Taxes losses generated/consumed: pro rata to (Delta PBT + Delta PBT WHT (paid + due)) within the tax payer's bounds
  • ATP WHT paid -> linear