Simulating when a crypto PONZI will fail (and when to take profits)

If you’re DEFI space you may already heard a lot about ponzi schemes especially if you’re using BSC regularly.

Usually a ponzi rise very fast at the beginning when speculators get very “hyped” (especially in the blockchain), but when the hype ends, early investors take profit and withdraw their funds leaving the token price to a sharp downfall.

The question is :

Can we predict when such a Ponzi will crash ? When this is the best moment to withdraw before the crash ? Or even if I should invest in this scheme.

In this post we will take the example of crypto-nodes projects. The promise of such a project was simple:

  1. Buy my scam $Token of X BNB. (let’s say 0.1 BNB = 1 $Token)
  2. Buy a node for Y $Token (let’s say 10).
  3. Once you have bought your “node”, you’ll get Z $Token per day (let’s say 1 $token per day.) for life .
  4. You have to claim your rewards every day to get the 1 $Token.

This means that you can get back your “investment” in 10 days, double it in 20 days and have an APY of 3650%!

Sounds like easy money right?

As you may think there is are a catch, can you guess where the 1 $token comes from?
The answer is from holders who bought the node before (for 10 $tokens)

These tokens are placed in what’s called a “reward pool”, which will be used to pay the “daily” tokens for everyone (1 $token).

This means that your rewards are not produced by a created value but by others money, this is the definition of a ponzi scheme.

At first the price of the token will rise because a lot of people are buying nodes (moreover the tokens are not sold, there exchanged for nodes, therefore the are place in the reward pool.), but once there are to many nodes which yield 1 $token per day, people will prefer to sell them and the price will go downwards faster and faster as there are more and more nodes.

The goal will be to calculate when this is the best moment to withdraw our tokens.

2. A good simulation

Let’s say that (at t = 0) :

  • 1 people buy 1 node per hour for 10 tokens. (by buying 10tokens)
  • 1 node get 1 token per 12 hours.
  • In the liquidity pool there is 10BNB (Binance coin) and 1000 tokens. (thus the price starts at 0.01BNB/token.)

(Let’s ignore the DEX fees now.)

Now let’s define the following functions/variables.

  • i variable means the number of hours has elapsed since the start of the ponzi.
  • LPb(t) means the number of BNBs in the liquidity pool.
  • get_LPt(i) = 10000/LPb[i] (it returns the number of tokens in the pool.)
  • get_price(i) = LPb[i]/get_LPt(i). (it returns the price a time i)

Here is the full code of the simulation.

import matplotlib.pyplot as pltLPb = [10]
k = 10000
prices = []
def get_LPt(i):
return 10000/LPb[i]
def get_price(i):
return LPb[i]/get_LPt(i)
for i in range(0,480): # I do the simulation for 20 days
prices.append(get_price(i)) # I append the prices each times to
# put the on the graph
LPb.append(10000/(get_LPt(i) - 10 + (i // 12)))
plt.plot(prices)
plt.savefig("test.png")

(pip install matplotlib) If you want to graph the results as i did.

And Here are the results

I’ve made the simulation with python and the first week (first 168 hours) the project will thrive going to 0.01BNB/token to 0.08 BNB/token

But the next week, it will dip to 0.05BNB/token (as there are more and more sellers)

After that the tendency will stay the same, the price will go to the “cave”.

It’s still a simple simulation, but it can show how much time can live a “ponzi scheme” and what may happen if we still want to bet on the shitcoin.

The next time I’ll make a more realistic simulation (with some randomness, adding influencers…) :)

Conclusion

Don’t invest in shitcoin and pyramid scams you have way more probability of selling when the shitcoin is already down than at the ATH.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
TrustChain

Smart contract Auditor & Cybersecurity engineer, follow me on Twitter to get more value: https://twitter.com/TrustChain_DEFI