Introduction to zPIV and zPIV staking in PIVX 3.1

One of the most exciting new features in PIVX 3.1 is the ability to privately stake zPIV, in addition to PIV. The term used by the project for zPIV staking is zPoS—which means “zPIV Proof of Stake”.

For existing PIVX users upgrading to 3.1 (currently at “build version” 3.1.0.2), perhaps the most common question will be, “How do I switch to zPIV staking?” This article attempt to answer that. We’ll begin with a refresher of some basics, though, and then get to earning rewards through staking!

Is zPIV a “coin” that’s different than PIV?

PIV is the coin/token/currency of the PIVX network. zPIV is also a token supported by the network, and in that regard, we’ll use the term “coin” in this article. Technically, it’s a “state” of the PIV coin, but since that can be a little hard to imagine, the PIVX project encourages people to think of zPIV conceptually as “casino chips”, i.e. something anonymous you switch into and out of from PIV, on a one-to-one basis.

(And for an essay on why that privacy capability is important, have a read of this.)

Can I transact in zPIV?

Absolutely, that’s the whole point — you can send and receive zPIV anonymously! Keep in mind, though, that although you may send someone zPIV, the recipient always receives and equivalent amount of PIV, not zPIV. On the blockchain, these received PIV appear as if they were just created. They have no history, and no information about the sender is revealed.

For me personally, I like to think of my PIV holdings as my PIVX “Checking Account”, and my zPIV holdings as my PIVX “Private Savings Account”.

What exactly is staking?

In a “Proof of Stake” network like PIVX, transaction blocks produced by the network are validated by the wallets of everyday users like you and I. For that reason, your staking wallet needs to be continually running, and connected to the internet!

When the network needs a new block validated, it randomly chooses a wallet for the job, and then awards some PIV to that wallet for its work. That’s how you earn PIV through staking! This is more energy efficient, and results in wider distribution, than miners in a “Proof of Work” network like Bitcoin.

Is staking safe, if I have to leave my wallet open?

Leaving your wallet open for staking is safe, as long as you have enabled “wallet encryption”. When your wallet is encrypted, any attempt to initiate a transaction will require the encryption password.

To unlock your wallet for staking, do “Settings” → “Unlock Wallet…” and before entering your wallet password, enable the “For anonymization and staking only” setting.

Why should I stake zPIV instead of PIV?

There are two main reasons:

  • Privacy — Like casino tokens, zPIV coins are completely anonymous, due to the “zerocoin protocol” on which they are based. Staking zPIV coins is likewise anonymous.

  • Higher earnings — While PIV staking remains an option, zPIV staking results in higher rewards, as 3 PIVs are awarded to zPIV stakers per validated block, as opposed to 2 for PIV stakers.

How much can I earn?

Staking wallets are chosen for block validation and rewards randomly, but weighted by the amount of coins being staked, and the time during which they have been staking. This incentivizes people to stake more, and stake consistently.

In general, though, it’s estimated that over the course of year, zPIV stakers will earn roughly 6.5%, while PIV stakers will earn 5.0%.

Can I stake both?

Yes! While staking is enabled in your wallet, both your PIV and zPIV balances will be earning rewards.

If I’m staking zPIV, do I receive zPIV as a reward?

Yes, the rewards are paid anonymously in zPIV.

How do I convert my PIV to zPIV

To stake zPIV, you need to convert your exiting PIV.

  • Manually — You can convert your current balance of PIV to zPIV manually by doing clicking the “Mint Zerocoin” button within the “Privacy” tab.

  • Automatically — You can make sure future received PIV are converted automatically to zPIV by enabling this setting. This includes both PIV sent to you by others, and PIV you earn through staking. If you wish to always retain a balance of some PIV, you can set the percentage you want automatically converted.

If you’ve currently been staking PIV, you might have configured the old wallet to disable zPIV creation with the enableautomint=0 setting in the pivx.conf file. If you’ve done that, don’t forget to remove that line and restart the wallet!

What is the option for the “preferred denominations” about?

Unlike PIV, which can exist as very small fractions, like 0.054, zPIV coins can only exist in certain whole denominations, like 1, 5, 10, etc. In the PIVX wallet settings, you can specify the smallest denomination you want to hold in your wallet, and this setting will influence the staking rewards you receive.

A larger denomination has a slightly higher probability of being chosen for a staking reward than a smaller denomination. However, once an “input” has been chosen for a staking reward, it doesn’t become available again for 220 blocks. The reward amount is fixed, however, regardless of the staking size. So even a 1 zPIV input, if chosen, would receive the same reward as a 5k zPIV input.

Imagine you held 5,000 PIV, and were thinking through your options for this setting. If you chose “5000” (and ignoring that there are some fees involved in the conversion process), you’d end up with one 5k input available for staking. That input would have the highest possible probability of being selected, but once selected, you’d have to wait 220 blocks to be eligible again.

If you set the auto mint denomination to 1k, then you’d have five available inputs for staking, each of which would have a slightly lower probability of selection than a single 5k input. However, when one of your inputs gets selected for reward, you still have four available for reward while the original one is waiting 220 blocks for its availability again.

I can’t find any analysis that has been done to determine the optimal strategy. In my case, I’m going to set the denomination amount to 1,000 and see what happens. I may play around with the setting from month to month, to try to determine how it affects the rewards.

For most people, though, the “Any” option should be just fine. In any case, this setting isn’t anything to stress about. 🙂

Go download 3.1 and get started!

And with that, we bring this article to a close. Be sure to download PIVX 3.1 now, and get to earning rewards through zPIV staking today! And if you have any questions, there’s a friendly team waiting for you in the #support channel of the PIVX Discord.

5 thoughts on “Introduction to zPIV and zPIV staking in PIVX 3.1”

  1. Hello.
    Thank You for this well written article.

    If I may, I’d like to point out a couple of things:

    1) It might be better to direct people to pivx.org/wallets rather than saying the last version. If you say the last version, you automatically outdate this article (now for ex. it’s v3.1.0.2 not v3.1).
    2) To avoid criticism, I’d avoid saying that Zerocoin is unique to PIVX. It’s not but it’s adaptation is and currently it seems to be the best one (ie. faster, efficient, I think it got higher den etc.).
    3) From your article it seems that one can stake with a non-encrypted wallet. One cannot. The wallet must be encrypted and, as you said, decrypted for staking only. Thus, staking is safe by all means because if the wallet is not encrypted, one cannot stake in the first place.

    Otherwise, great.
    Gio

    1. Hi Gio, thanks for the great feedback. Here’s a response to your points:

      1. I’ve updated the download link to the URL you suggested. (For some reason, when I click it, I get a Japanese page. Go figure…) I do think the release should be referred to in *communications* as 3.1, just as in OS X High Sierra it’s 10.13. So in the future, I’d hope we’d say that 3.1 is the zPoS release.

      2. I’ve removed the statement about being unique.

      3. I installed a wallet and did not encrypt it, and after some time it reported that it was staking. Are you sure what you wrote is correct?

  2. Re #3, Gabriel, you are correct. A fully unlocked (which is always the case for non-encrypted wallets) can stake just fine. In fact, with a non-encrypted wallet, the only way to disable staking is to put staking=0 in the pivx.conf file. If not, it will always try to stake whatever coins it has available. The obvious reason for recommending to encrypt and just unlock for staking only is to provide 1 extra layer of protection (requiring to enter a pass phrase) in case someone somehow gets remote access to your computer and tries to make a transaction with your PIV. (to steal)

  3. Hi,
    it would also be complete of you to mention that conversion from PIV into zPIV comes at a cost.

    From the ‘whitepaper’ (at https://pivx.org/zpiv/ ): “Converting 7 PIV into 7 zPIV will involve minting 3 denominations of 1,1,5 zPIV. So this will cost 0.03 PIV in fees.”

    It’d be interesting to explore what the total conversion cost is, and whether the increase in ROI covers/doesn’t cover it.

    1. 0.03 PIV on a 7 PIV total mint is about 0.4%. In theory the staking rewards for zPIV should be higher than PIV, and should be enough to cover the fee drag. In practice, as we’ve seen, there’s a problem in that it takes the wallet so long to calculate the zero-knowledge proofs involved in zPIV staking rewards, that many blocks get out-timed by PIV staking (which is why you see so many orphans.) That’s the reason I’ve gone back to masternode running, rather than staking.

Leave a Reply to Gio Cancel reply

Your email address will not be published. Required fields are marked *