Advantages of Abelian’s Difficulty Smoothing Algorithm (DSA)

DSA quickly adapts to hashrate fluctuations and stabilizes the average block time.

Abelian Foundation
5 min readMay 30, 2024

Since the creation of the genesis block of the Abelian network in April 2022, the Proof-of-Work (PoW) difficulty adjustment algorithm has remained unchanged. This algorithm operates on a cycle of 4,000 blocks, which is also referred to as an epoch. At the conclusion of each epoch — specifically at block heights 4,000, 8,000, 12,000, and so on — each Abelian node calculates the time taken to complete that epoch. The goal is to regulate the average block time to 256 seconds, aiming to complete an epoch roughly every 12 days.

In other words, the Abelian network is trying to produce one epoch for about every 12 days. If the time taken in the just-finished epoch is shorter than 12 days, the algorithm increases the mining difficulty for the next epoch, causing GPU cards to take longer to mine each block, thereby increasing the average block time. On the contrary, if the epoch completion time is longer than 12 days, the algorithm decreases the mining difficulty, allowing GPU cards to mine blocks more quickly and reducing the average block time.

The impact of network hashrate fluctuations is that a surge in GPU cards boosts the network’s computational power, reducing the time required to mine blocks; and a significant drop in GPU cards lowers the network’s hashrate, increasing the block mining time.

In recent months, the Abelian network has experienced significant fluctuations in average block times. During some epochs, average block times have been as low as 80 seconds, while in others, they have exceeded 800 seconds. Such volatility is expected in a young PoW project but poses challenges:

High Miner Influx: When many miners join, block times shorten, increasing network throughput. However, nodes with poor connections may struggle to synchronize, causing frequent soft forks and wasting computational power, although miners benefit from increased rewards.
High Miner Exodus: Conversely, if many miners leave — often due to unfavorable token prices — the network hashrate drops sharply, increasing block times. For instance, during the epoch from block height 276,000 to 280,000, average block time soared from 245 seconds to 1,000 seconds, extending the epoch duration from the intended 12 days to a month. This delay severely impacts transaction times and network usability.

Cyclic Miner Behavior:

A noticeable pattern has emerged where miners join the network during low-difficulty epochs and leave during high-difficulty ones. This results in alternating epochs of high and low difficulty, causing block times to oscillate in a similar see-saw pattern. Miners optimize their profits by switching between Abelian and other GPU-minable cryptocurrencies based on difficulty levels.

To address these issues, the project established a taskforce early this year to improve the mining difficulty algorithm. The revised algorithm aims to quickly adapt to hashrate fluctuations, stabilizing the average block time to the designed 256 seconds. This adjustment will enhance network stability and ensure smoother transaction processing for users.

Introducing the Difficulty Smoothing Algorithm (DSA)

We are excited to announce a new mining difficulty adjustment algorithm called the Difficulty Smoothing Algorithm (DSA). This innovative algorithm improves upon the previous method by grouping consecutive blocks into smaller slots of 200 blocks each, allowing for more frequent and precise adjustments.

How DSA Works:

1. Slot-Based Adjustment: The DSA operates by grouping blocks into slots of 200 blocks. Every 200 blocks, it reviews the previous 20 slots, which collectively comprise 4,000 blocks.

2. Weighted Average Calculation: Instead of simply averaging the time taken for the last 4,000 blocks, DSA calculates the average time for each of the previous 20 slots. It then computes a weighted average, giving more recent slots a higher weight and older slots a lower weight.

3. Adjustment Criteria:
• If the weighted average slot time is shorter than 51,200 seconds (200 blocks x 256 seconds per block), the mining difficulty increases for the next slot.
• If the weighted average slot time is longer than 51,200 seconds, the mining difficulty decreases.

Advantages of DSA:

Frequent Adjustments: By adjusting the difficulty every 200 blocks instead of 4,000 blocks, the DSA provides 20 times more frequent adjustments, allowing for quicker responses to changes in network hashrate.

Enhanced Responsiveness: The use of a weighted average that prioritizes recent slots over older ones ensures that the algorithm adapts more effectively to rapid fluctuations in network activity.

Improved Stability: Simulations have demonstrated that DSA converges more quickly and stabilizes the network around the target average block time of 256 seconds.

The new DSA will be implemented at block height 284,000. Currently, all mining pools, exchanges, and major individual Abelian nodes are completing the upgrade process.

Abelian Node Operators: If you are running an Abelian node or using an older version of the desktop wallet, please download the latest versions from the official Abelian Download page and upgrade.

Mobile Wallet Users: No action is required if you are using the Abelian Pro mobile wallet.

Mining Pool Participants: No action is needed if you are mining through a pool.

Solo Miners: If you are solo mining and running your own Abelian node (i.e., abec), please ensure that you upgrade to the latest version (v0.13.0).

By implementing the DSA, we aim to enhance the stability and efficiency of the Abelian network, providing a more reliable environment for all users and miners.

For more information, please contact: general@abelian.info

About Abelian

Abelian is a quantum-resistant blockchain infrastructure which enables digital gold 2.0 and empowers the post-quantum crypto ecosystem. Learn more about the quantum-safe Abelian blockchain & $ABEL Tokenomics at our documentation page.

The Abelian Foundation welcomes all feedback regarding tech developments and upcoming changes. To join the conversation, please visit us on our various social media and community channels linked below 👇
Twitter | Telegram | Discord | YouTube | LinkedIn

--

--

Abelian Foundation

abelian.info | linktr.ee/abelianfoundation | Post-Quantum Blockchain | Layer 1 | Multi-Level Privacy-Preserving | Quantum-Safe Crypto Ecosystem