Why Qtum is Better for Building DeFi

Qtum
Qtum
Published in
6 min readAug 17, 2020

--

Overnight, it seems that everyone is talking about DeFi (Decentralized Finance). The combination of traditional finance and decentralized blockchain networks are creating a wonderful revolution. However, at this time of rapid development, the entire DeFi ecosystem still faces various constraints and challenges. One of the most important challenges is that the existing blockchain infrastructure cannot support complex DeFi applications. Whether it is virtual machines, TPS, fees, or on-chain governance, there are many limitations.

Qtum launched with its mainnet in September 2017. It is the industry’s first smart contract platform based on the same UTXO model as Bitcoin. After 3 years of technological iteration, Qtum has gradually developed a variety of unique technical and environmental characteristics, which are entirely suitable for building DeFi projects. This article will discuss this in detail.

01 — Compatibility with Smart Contract Ecosystem

Qtum has always maintained compatibility with the mainstream ecosystem of the blockchain, which has created a good technical foundation for the migration and integration of existing DeFi applications.

EVM Compatible

Ethereum is currently the most popular DeFi infrastructure, and most DeFi projects are developed based on the Ethereum Virtual Machine (EVM). By introducing the AAL (Account Abstraction Layer), Qtum achieves full compatibility with EVM on top of Bitcoin’s UTXO model and makes timely EVM upgrades. The DeFi smart contracts deployed on Ethereum can theoretically be seamlessly migrated and deployed on the Qtum Chain and run in the Qtum version of the EVM. Developers do not need to support additional development and migration costs.

Corresponding to smart contract development tools, Qtum has also made a lot of adaptations, such as Truffle, MetaMask, etc., to ensure that developers and users get an experience consistent with Ethereum.

Neutron Middleware Compatibility for Multiple Virtual Machines

EVM is a virtual machine specially designed for smart contracts, but its capability is not very powerful, and it is not compatible with mainstream programming languages and programming paradigms. EVM is not the only smart contract virtual machine in the industry. WASM, RISC-V, and the x86 virtual machine being developed by Qtum all have their own unique advantages in the future development of DeFi.

Qtum is developing a virtual machine middleware protocol called Neutron, which can simultaneously support multiple virtual machines including EVM, Qtum x86, WASM, etc. on top of the Qtum blockchain. In the future, the development of DeFi smart contracts will not be limited to EVM. But no matter which virtual machine is used, Qtum can be compatible with it, so that the entire DeFi ecosystem can be further integrated on the Qtum platform. Developers can use different programming languages and operating environments on Qtum as needed to create more complex DeFi applications.

02 — Technical Features More Suitable for DeFi

In addition to its good compatibility with the existing smart contract ecosystem, Qtum also has technical features that are urgently needed for existing DeFi applications.

Higher TPS & Lower Fees

The relatively low TPS on Ethereum and the rising fees due to network congestion have been torturing DeFi users. Although EOS and other projects have higher TPS and low fees, the degree of centralization of the network is contrary to the fundamental character of DeFi: decentralization.

Qtum adopts a decentralized Proof-of-Stake consensus mechanism with thousands of independent full nodes around the world. It is one of the largest distributed networks except for Bitcoin and Ethereum. While ensuring decentralization, Qtum’s current TPS is 10 times that of Bitcoin, and several times faster than Ethereum. Also, the same smart contract consumes less gas and fees on Qtum compared to Ethereum. This is more friendly to high-frequency applications such as DeFi.

Decentralized On-Chain Governance

Some people may question if Qtum’s current low transaction fees and gas are largely because the Qtum network is not congested, and the price of QTUM is currently low. With the increase of popular DeFi applications in the Qtum ecosystem and the fluctuation of token prices, the cost of using DeFi applications on Qtum will likely increase. Moreover, a TPS of around 70 still cannot satisfy the more complex DeFi applications in the future.

In response to this issue, Qtum released a decentralized on-chain governance mechanism called DGP (Decentralized Governance Protocol) at launch. Through DGP, Qtum blockchain participants (including development teams, currency holders, DApp developers, and other roles) can conduct decentralized on-chain governance of the basic parameters of the Qtum blockchain. The basic parameters of the network, including block size, gas schedule (price for various operations), gas price, and gas block limit can be adjusted in real-time through DGP without requiring a hard fork.

Through this mechanism, block participants can further increase or decrease TPS by adjusting block size according to network conditions. It is also possible to further reduce or increase the use cost of DeFi applications by adjusting the gas price and gas consumption. In short, the optimal combination of TPS and gas fees can be realized according to the current network conditions, and be adapted to different stages of DeFi ecosystem development.

Proxy Payment Mechanism

For existing DeFi applications on Ethereum, each on-chain smart contract call needs to consume a certain amount of ETH for gas. This means that users first need to hold a certain amount of ETH to use DeFi applications. This undoubtedly raises the barriers to entry of DeFi, and will restrict DeFi application scenarios to some extent.

The Qtum 2.0 version update in 2019 provided a new OP_SENDER opcode, adding a proxy payment mechanism to the base-layer script protocol. Through OP_SENDER, users can call smart contracts without holding any QTUM tokens, and their fees can be paid by a third party. This built-in, on-chain capability is attractive in applications such as a decentralized exchange DEX. Users only need to care about whether the QRC20 tokens they hold can be traded or swapped into another token, without having to consider how to obtain QTUM for the transaction fee and gas. Service providers can pay fees for their users, and charge service fees, etc. This means that users can completely ignore constraints of the underlying tokens and focus on using the DeFi application itself.

Parallel Contract Calls Based on UTXOs

Because Qtum uses the UTXO model that is consistent with Bitcoin, each transaction can have multiple inputs and multiple outputs. Combined with the OP_SENDER opcode mentioned above, multiple contracts can be called in parallel for a single transaction, and the caller of each output can be different. This is completely impossible to achieve in Ethereum.

With this feature, users can interact with multiple DeFi contracts more efficiently in the same block. And service providers, such as decentralized exchanges and market makers, can simultaneously operate on multiple accounts through a single transaction, realizing DeFi application transactions that are far more complex than Ethereum.

Privacy Protocol Support

On-chain privacy is a relatively lacking but a crucial feature for the current DeFi ecosystem. Existing DeFi applications, including various stablecoins, are open and transparent. However, in actual application scenarios, users often do not want to disclose transaction details, which requires the introduction of privacy technology.

The Phantom Protocol is a zk-SNARKs-based on-chain privacy protocol developed by Qtum. With Phantom Protocol, users and developers can convert existing QRC20 tokens (same as ERC20) into private assets, so that the addresses and transaction amounts for both parties can be hidden in subsequent transactions. Compared with similar protocols on Ethereum, the Phantom Protocol has made many optimizations in Merkle trees, hashing algorithms, etc., to achieve complete privacy, ensuring the balance between the efficiency of proof generation and the cost of users. The combination of Phantom Protocol and DeFi applications will have great potential. For example, privacy stablecoins are an important advancement in DeFi.

03 — Ecosystem Advantages of Qtum DeFi

RMB Stablecoin QCash

Stablecoins are the cornerstone for the rapid development of DeFi. The recent outbreak of DeFi on Ethereum has benefited from the transfer of a large number of USDT from the Bitcoin Omni Layer Protocol to Ethereum’s ERC20 tokens.

At present, most stablecoins on the market are pegged to the US dollar, and the stablecoin QCash, which is pegged to RMB and has the largest circulation, was developed based on Qtum. Qtum is one of the best platforms for developing DeFi applications, and Qtum also supports the access of other stable coins.

DeFi Ecosystem Reward Program

In addition to the technical and existing ecological advantages, the Qtum Chain Foundation is about to launch a DeFi ecosystem reward program to encourage more developers to relocate and develop DeFi applications on Qtum. DeFi developers will also receive financial support while using Qtum’s advanced technology.

04 — In Conclusion

Although DeFi has received a lot of attention, it still faces many problems before real large-scale implementation. This article explains the unique advantages of Qtum as a basic DeFi platform considering compatibility, technological innovation, and ecosystem support. We hope that more developers can join the development of Qtum DeFi and create more and better DeFi applications with true long-term value.

For more information, please contact email: defi@qtum.info

--

--