---
description: It's all about fairness
---

# Payout Curve

Derivio uses a dynamic long-short ratio-based payout curve to ensure fairness between traders and balance the risk for the LPs. By recording the percentage of long positions at each block, this price discovery approach allows us to adjust the payouts more accurately according to the market condition.

On top of the basic long-short ratio calculation, we have put measures to mitigate the impacts of potentially harmful circumstances. The long-short percentage will be capped at 80%/20 % respectively, in order to prevent a sudden extreme jump in the long-short ratio at the beginning or when liquidity is low. This can also stop potential payout manipulation, effectively encouraging more balanced trading activity.

A regularization constant is introduced into long percentage calculation, aiming to adjust payout in a more reasonable way that faithfully reflects the market impact of users. This method works by introducing an initial fixed amount on both sides of the trade, which reduces the effect of outliers and creates a more stable payout structure.

For calculation we have:

$$
\textit{(Time Weighted) Long OI} = \sum_{\text{long positions}} \frac{\text{position open interest }}{\text{position duration} }
$$

$$
\textit{(Time Weighted) Short OI} = \sum_{\text{short positions}} \frac{\text{position open interest }}{\text{position duration} }
$$

$$
\textit{(Real-time) Long %} = \frac{\text{Long OI} + \text{Reg const. } }{\text{Long OI + Short OI } + 2 * \text{Reg const. }}
$$

$$
\textit{Final long \%} = \int_0^{\text{settle}} \frac{ \max(\text{Long \%}, 20 \%)}{\text{settlement period length}} \text{ dt}  = \sum_{blocks} \frac{ \max(\text{Long \%}, 20 \%)}{\text{settlement period length}}
$$

$$
\textit{Final short \%} = \int_0^{\text{settle}} \frac{\max(\text{1 - Long \%}, 20 \%)}{\text{settlement period length}} \text{ dt}  = \sum_{blocks} \frac{ \max(\text{1 - Long \%}, 20 \%)}{\text{settlement period length}}
$$

$$
\textbf{Final long payout} = \frac{(1-c_b) * \textbf{Final short \%}}{\textbf{Final long \%}}
$$

$$
\textbf{Final short payout} = \frac{(1-c_b) * \textbf{Final long \%}}{\textbf{Final short \%}}
$$

Where $$c_b$$ is a balancing constant to control the long-short ratio between pools.

The real-time long/short payout on the page is calculated as follows:

$$
\textbf{Real-time long payout} = \frac{(1 - c_b) * \max(\text{1 - Real-time Long \%}, 20 \%)}{\max(\text{Real-time Long \%}, 20 \%)}
$$

$$
\textbf{Real-time short payout} = \frac{(1 - c_b) * \max(\text{Real-time Long \%}, 20 \%)}{\max(\text{1 - Real-time Long \%}, 20 \%)}
$$

Once a position is opened, traders can also directly monitor their projected payout, which is given by assuming that the current long-short ratio will be kept until the settlement time, and the result is in favor of the trader.

$$
\textit{future long predictions} =  \max(\text{Real-time Long \%}, 20 \%) * (\frac{\text{settlement - now}}{\text{settlement}})
$$

$$
\textbf{Projected long \%} = \int_0^{\text{now}} \frac{\max(\text{Long \%}, 20 \%)}{\text{settlement}} \text{ dt } + \textit{future long predictions}
$$

And similar for shorts, by replacing Long% by 1 - Long% in the formula, respectively.

$$
\textbf{Projected long payout} = \frac{(1 - c_b) * \textbf{Projected short \%}}{\textbf{Projected long \%}}
$$



And similar for shorts, by replacing Long% by 1 - Long% in the formula respectively.

{% embed url="https://www.desmos.com/calculator/n04e26gtjg" %}
Vanilla Static LSR - Profit Curve
{% endembed %}

Plot: [https://www.desmos.com/calculator/n04e26gtjg](https://www.desmos.com/calculator/n04e26gtjg)



#### Current Parameters

<table><thead><tr><th width="187">Paramater</th><th>Value</th></tr></thead><tbody><tr><td><span class="math">Reg.\ const</span></td><td>$21,600/hr</td></tr><tr><td>Fee</td><td>3%</td></tr><tr><td><span class="math">c_b</span></td><td>12% for ETH, BTC; 9.28% for all other markets</td></tr><tr><td>Keeper</td><td>3% (if pool wins)</td></tr></tbody></table>

