<p>Old question, but I wanted to work this out myself.</p>

<p>The exchange will liquidate your account as soon as it becomes insolvent. There are exchange dependent parameters fees, interest and maybe a threshhold to take into account. I don't know bitfinex values for these.</p>

<p>Ignoring them for now, the general equation works out like:</p>

<p>p(t) = btcusd at time t</p>

<p>p(0) = 1000</p>

<p>leverage = m = 2</p>

<p>initial usd = d0 = 10000</p>

<p>assets(t) = d0*m/p0*p(t)</p>

<p>liabilities(t) = d0 - m<em>d0 = d0</em>(1-m)</p>

<p>Liquidated when assets(t) + liabilities(t) = 0, i.e. when d0*m/p0*p(t) + d0*(1-m) = 0</p>

<p>=> p(t) = -(1-m)*p0/m</p>

<p>=> p(t)/p0 = (m-1)/m</p>

<p>For p0=1000, m=2, you liquidate when p(t) drops to 1/2 of 1000 = 500</p>

<p>If anyone has the exchange-dependent data for bitfinex, I'll try to incorporate into the equation.</p>

CC BY-SA 4.0
2019-08-06T01:16:36.723Z
2019-08-06T01:16:36.723Z
harrym
<p>The following variables are given:</p>

<p>Exchange: Bitfinex</p>

<p>Funds: $10,000 USD
BTC Price: $1000
Use Leverage of: 2x = $20,000 USD</p>

<p>Say I wanted to go long Bitcoin thinking it would be above $1000 in the next 6 months. I buy 20k USD worth of BTC (20 btc) at the $1000 price. </p>

<ul>
<li>What does the price of btc have to drop before I lose my initial investment of $10,000?</li>
<li>What is the formula for something like this when using Bitfinex exchange?</li>
</ul>

<trading><bitfinex><margin>
What's the exact formula where I can calculate my liquidation price on Bitfinex for a leveraged position?
Patoshi パトシ
# What's the exact formula where I can calculate my liquidation price on Bitfinex for a leveraged position?

(Asked by: username_0 on 2018-12-22)

The following variables are given:

Exchange: Bitfinex

Funds: $10,000 USD
BTC Price: $1000
Use Leverage of: 2x = $20,000 USD

Say I wanted to go long Bitcoin thinking it would be above $1000 in the next 6 months. I buy 20k USD worth of BTC (20 btc) at the $1000 price.

* What does the price of btc have to drop before I lose my initial investment of $10,000?
* What is the formula for something like this when using Bitfinex exchange?

**Tags:** trading, bitfinex, margin


---

## 1 answers

### Answer by username_1 on 2019-08-06. Score: 0 | Accepted answer

Old question, but I wanted to work this out myself.

The exchange will liquidate your account as soon as it becomes insolvent. There are exchange dependent parameters fees, interest and maybe a threshhold to take into account. I don't know bitfinex values for these.

Ignoring them for now, the general equation works out like:

p(t) = btcusd at time t

p(0) = 1000

leverage = m = 2

initial usd = d0 = 10000

assets(t) = d0\*m/p0\*p(t)

liabilities(t) = d0 - m*d0 = d0*(1-m)

Liquidated when assets(t) + liabilities(t) = 0, i.e. when d0\*m/p0\*p(t) + d0\*(1-m) = 0

=> p(t) = -(1-m)\*p0/m

=> p(t)/p0 = (m-1)/m

For p0=1000, m=2, you liquidate when p(t) drops to 1/2 of 1000 = 500

If anyone has the exchange-dependent data for bitfinex, I'll try to incorporate into the equation.


---

