Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - theoretical

Pages: 1 ... 27 28 29 30 31 32 33 [34]
496
General Discussion / Re: Proposal for liquidation of short sales
« on: February 28, 2014, 08:19:59 am »

(reserved)

497
General Discussion / Re: Proposal for liquidation of short sales
« on: February 28, 2014, 08:19:09 am »

(reserved)

498
General Discussion / Re: Proposal for liquidation of short sales
« on: February 28, 2014, 08:18:58 am »

Now I will address the problem of short squeezes.  When the market price movements from block to block are small, the bid orders generated by forced liquidations of short positions are above the market, and relieve upward pressure on the price.  However, consider what happens when there is a large movement in the price, at least doubling from one block to the next -- perhaps caused by a single actor buying all the liquidity from the market.  A massive number of shorts will move into the red zone; their holders will be completely wiped out, and the high price will now be strongly supported -- any downward pressure will now have to break through all the bid orders generated by forced liquidations.

As a solution, I propose rate-limiting tracking price movements.  That is, compute TP_new = max(TP_prev * (1 + TP_maxdelta), (best_bid_prev + best_ask_prev) / 2).  I propose TP_maxdelta = 1 / 512.  Thus, large moves in the price (as represented by the best bid-ask average) will not result in immediate forced liquidation of most short positions.

As a side benefit to this rate-limiting, it becomes possible to compute the minimum number of blocks it will take for the tracking price to exceed a given threshold.

For example, let's suppose that some time ago, Alice shorted 1000 BitUSD at a price of 0.1 BTS/BitUSD.  The tracking price has since moved against Alice, and is now p0 = 0.13 BTS/BitUSD.  Alice currently has 35% equity.
She will be forced to liquidate when the tracking price reaches a value that results in her equity dropping to 25% or lower; the tracking price must be at least p1 = 0.15 BTS/BitUSD for Alice to be involuntarily liquidated.

Suppose the tracking price grows as fast as the rate limit allows:  Geometrically by a factor of (1 + TP_maxdelta) per block.  It cannot reach p1 until at least n blocks have passed, where

    n = ceil((log(p1) - log(p0)) / log(1 + TP_maxdelta))

In Alice's case, she's safe for at least 74 blocks, which is a little over six hours, assuming five minutes per block.

499
General Discussion / Re: Proposal for liquidation of short sales
« on: February 28, 2014, 08:18:35 am »
Now I will discuss my ideas for the detailed mechanics for liquidation of short sales.

(Green Zone)  A short position is said to be "In the Green Zone" if it has at least 25% equity.  Green Zone short positions are not subject to involuntary liquidation.

(Yellow Zone)  The Yellow Zone consists of short positions with non-zero equity, but less equity than the Green Zone.  Yellow Zone short positions are subject to involuntary liquidation.

(Red Zone)  The Red Zone consists of short positions with zero or negative equity.  Red Zone short positions are subject to involuntary liquidation.  (If using Wipeout Elbow, negative equity is impossible.)

Note, the zone a given position is in depends on the Tracking Price.  Suppose Alice's position is in the Green Zone in the current block, based on the current tracking price.  If the tracking price rises in a later block, Alice's position may move into the Yellow or Red Zone.

In "normal" market conditions, poorly capitalized positions move into the Yellow Zone and are liquidated before they move into the Red Zone.  However, large movements in the tracking price within the space of a single block may cause positions to jump directly from the Green Zone to the Red Zone without an intervening stop in the Yellow Zone.

Wipeout Elbow and Strong Linearization give the same results in the Yellow Zone conditions, only the Red Zone handling is different.

The sequence of steps for liquidating shorts are as follows:

(1) The best bid and ask price for the previous block are used to determine the tracking price.

(2) For every position in the Red and Yellow Zone, a limit bid order is placed.  The order quantity is the size of the short position.  The equity less fee (elf) is the proportion of the proceeds to which the short holder is entitled, less liqfee = 5%, and is given by:

    elf = max(0, equity - liqfee)

The limit bid order's price is given by (1 - elf) * pie / quantity.

(3) Suppose some fraction z of this limit order is fulfilled.  Then BTS moves from the pie to the short position holder and the seller fulfilling the bid order.  The short holder gets elf * pie * z, and (1-elf) * pie * z goes to the seller.  The remaining money, pie * (1-z), goes back into the pie.

500
General Discussion / Re: Proposal for liquidation of short sales
« on: February 28, 2014, 08:17:24 am »

Single Short Example:  Bob places a Bid on BitUSD, offering to buy 1000 BitUSD at a price of 0.1 BTS/BitUSD; there are no takers immediately, so Bob's offer will remain on the order books until it expires.  Several blocks later, but before Bob's order has expired, Alice places a market short order for 1000 BitUSD.  Alice's and Bob's orders are matched and a trade is performed.  Bob's account is debited 100 BTS; Alice's account is debited enough to meet the Margin Requirement.  For a 2x margin requirement, this means Alice contributes 100 BTS; for a 10x margin requirement, this means Alice contributes 900 BTS.

Let us assume a 2x margin requirement.  Then the pie contains 200 BTS; 100 BTS each from Alice and Bob.  Alice's equity is 100 BTS or fifty percent.  Now consider the function f which describes Alice's equity
as a function of the tracking price.  By the Capitalization Principle, f(0.1 BTS/BitUSD) = 100 BTS.  By the Total Win Principle, f(0 BTS/BitUSD) = 200 BTS.  By the Weak Linearity of Short Position, f is linear until it reaches zero,
which happens at f(0.2 BTS/BitUSD) = 0 BTS.  In general, f(x) = 200 - 1000*x for x <= 0.2 BTS/BitUSD.  What happens when x > 0.2 BTS/BitUSD has not yet been specified, and is what much of the controversy is about.

The Slope is -1000 and the Wipeout Price is 0.2 BTS/BitUSD.

(Strong Linearization)  The function f(x) should be linear for all x.  This is Bytemaster's proposal.  That is, f(x) = 200 - 1000*x.

Bytemaster proposes to achieve strong linearization through increasing the margin requirement, or allowing printing of BTS to enlarge the pie.

(Wipeout Elbow)  I believe that Strong Linearization is unnecessary.  I think that simply setting f(x) = 0 for all x greater than or equal to the wipeout price is perfectly okay.  I call this the Wipeout Elbow.

501
General Discussion / Re: Proposal for liquidation of short sales
« on: February 28, 2014, 08:16:35 am »

We'll deal with a single BitAsset, for convenience I will call it BitUSD, but this also applies to other BitAssets (e.g. BitGLD).  Each paragraph in the following is preceded by a term in parentheses; the goal of the paragraph is to define that term.

(Short Position)  Accounts can have positive or negative BitUSD balance.  A negative BitUSD balance is called a "short position."

(Short Sale)  A negative BitUSD balance can only be obtained through a short sale.  A "short sale" is a sale of BitUSD which results in a negative BitUSD balance in the seller's account.

(Market Price Lock)  A short sale can only occur by the fulfillment of a public Ask order (either market or limit order); thus, a short sale always occurs at the market price.  I call this the Market Price Lock.

(Collateral)  When a short sale occurs, "collateral" is set aside.  The collateral consists of the money the buyer used for the purchase (less fee), and some amount of the seller's money.

(Buyer Perspective Equivalence Principle)  From the buyer's point of view, there is no difference between buying from a short seller and buying from a long seller on the exchange.

(Pie)  The collateral is set aside into a container I'll call a Pie.  Each pie is tied to an account and a BitAsset.  So if Alice shorts BitUSD, and Charlie shorts BitUSD and BitGLD, there will be three pies:  Alice's BitUSD pie, Charlie's BitUSD pie, and Charlie's BitGLD pie.

(Margin Requirement)  The initial size of the pie divided by the buyer's contribution to the pie.  This is 2x in the BitShares whitepaper, but Bytemaster has proposed an increased margin requirement of 10x.

(Equity)  The piece of the pie that would be given to the attached account in a purely theoretical, "fair" unwinding of the short position.  Can be specified as either a percentage of the total pie, or a number.

(Total Win Principle)  When the Tracking Price of BitUSD is equal to zero, equity is one hundred percent.

(Weak Linearity of Short Position)  Equity decreases linearly as a function of Tracking Price, until reaching zero at the Wipeout Price.

(Tracking Price)  The price that is used to determine equity is called the Tracking Price.  I believe it is currently specified as the average of the best bid and the best ask, but am not 100% sure about that.

(Wipeout Price)  For a given pie, the Tracking Price at which equity becomes zero is called the Wipeout Price.

(Capitalization Principle)  When an account initiates a short position, its initial equity is equal to its contribution to the pie.

(Slope)  The Slope is the rate-of-change of equity position.  The Total Win Principle, the Weak Linearity of Short Position, and the Capitalization Principle combine to determine the Wipeout Price and Slope.

502
General Discussion / Proposal for liquidation of short sales
« on: February 28, 2014, 08:16:17 am »

This will be partly an explanation of my understanding of short sales, then I'll develop some detailed ideas for liquidation mechanics.  This is in response to the following threads:

https://bitsharestalk.org/index.php?topic=3015.0  (I am explaining the issue raised in this thread's OP)
https://bitsharestalk.org/index.php?topic=3130.0  (I propose anti-short-squeeze measure which will make Slingshot attack impractical)

I will reserve some posts at the beginning of the thread, because I'm long-winded and I want to logically break up what I have to say into multiple posts without later posts getting buried in replies.

If you find my explanation helpful, please send PTS to PZxpdC8RqWsdU3pVJeobZY7JFKVPfNpy5z

503
General Discussion / Re: BitShares X Status Update
« on: January 30, 2014, 09:31:57 pm »

Why is this necessary at all?  What's wrong with just having every node do its own proof-of-stake on the set of transactions it knows about?


All nodes must AGREE on the next block to make sure the block chain doesn't diverge.  Bitcoin uses the lowest hash to decide what to agree on.


What's wrong with arbitrating between two different forks by accepting the one with the "better" proof-of-stake (compare hash divided by target for all competing forks)?

As a result bitcoin is centralized one block at a time.

I see what you're trying to say, but only because I think (earlier in this thread, or maybe somewhere else) you said that a single miner can "dictate" a block.  This is true, but it's a strength, not a weakness.  If you have some transaction T that a censor wants the network to permanently reject [1] [2] , with UNL it suffices for the censor to control some fraction of the UNL (maybe a majority, maybe a supermajority, maybe less -- need a simulation or detailed mathematical analysis to say for sure).  With PoS, we can assume 50% of the PoS-power will accept T [3], so the probability that T is not included in any of the next n blocks is at most (1/2)^n, which of course rapidly goes to zero.  Why allow a transaction censorship attack to succeed by compromising the UNL, when we can force them to meet the much higher bar of a 51% attack?

Bitcoin is also centralized by 10 mining pools which approve 90% of the blocks and just 2 or 3 are required for 51% or more of the blocks. 

I thought that PoS is supposed to be resistant to this phenomenon, because it's much harder to accumulate a significant fraction of a cryptocoin in circulation than it is to pool mining hardware.

[1] For example, the censor is a democratic government who believes, through due process of law, including good evidence obtained by Constitutionally approved methods and presented to an impartial judge / grand jury, that this transaction should be suppressed because it will be used for some despicable criminal activity.

[2] For example, the censor is an oppressive government whose intelligence service wants to invade privacy on a global scale by data-mining every financial transaction performed by every person in the world, and believes that this transaction should be suppressed because it does not contain sufficiently detailed information for its data mining system to confidently identify the sender, recipient, and nature of the transaction.  NB, technology cannot distinguish this case from [1].

[3] If 51% of nodes reject the transaction the censor wants to be rejected, then the censor has successfully carried out a 51% attack.  Because a 51% attack on PoS system implies that 51% of the money agrees with the censor, I would say this situation is better described as "the network voluntarily complied with the censor's desired policy" than "the censor launched a successful attack".

504
General Discussion / Re: BitShares X Status Update
« on: January 30, 2014, 08:34:07 pm »


The UNL list is a set of keys, not IPs.

A hard fork is the market solution to a misbehaving UNL set.  Bitcoin would have to perform a hardfork if the government ever got enough control over miners to enforce tainted coins.  The difference is that any bitcoin fork would also have to adopt a new POW that the government does not control and thus mean a massive coding change to something along the lines of a UNL.


This is the most informative thing I've heard yet.  I was thinking of the UNL along the lines of "a hardcoded list of network addresses which facilitates bootstrapping peer connections for a distributed peer-to-peer network service."  Instead, it seems it's more like "a set of authoritative signing keys which valid blocks will require."

Your peers cannot find a block

I'd like to elaborate to make sure I understand.  What you're really trying to say is that the validation check for a block involves checking that the block is signed by the hardcoded UNL signing keys, and it is impossible [1] for a node not in possession of a UNL private key to reproduce such a signature.  The code UNL nodes use to put together a block will be published, but the private keys will not.  So, just like anyone can put together a Bitcoin block that's lacking enough leading zero bits in the hash and thus will fail to validate, anyone can put together a Byteshares block that's lacking the UNL signature and thus will fail to validate.

[1] Impossible for an attacker who can't break RSA or ECDSA or whatever signature algorithm you use.

505
General Discussion / Re: BitShares X Status Update
« on: January 30, 2014, 07:45:41 pm »

I buy that Bitcoin's de facto centralization is something to be avoided if possible.  But I also want to be sure that your cure isn't worse than the disease, hence the skeptical questions.

If I'm wasting your time with elementary questions, and there's documentation where this is already explained, please, feel free to point me to those resources instead.

Okay, so here are my next questions:

- How do nodes outside the UNL know what has been approved by the UNL?  Do UNL nodes have hardcoded keys as well as hardcoded network addresses?  Or is a connection to a UNL node necessary for a client to function?

- Say I'm a node outside the UNL.  One of my peers feeds me a block that has a parent I've accepted and passes proof-of-stake signature, transaction validation, etc., but contains some transaction the UNL has never heard of.  How do I establish that the UNL has never heard of it?  What do I do with the block -- accept it, discard it, hold it for a while and see if the UNL eventually decides to like the transactions it contains, or something else?

- It seems like you might need a condition along the lines of "Most of the regular nodes (outside UNL) have to have nearly identical UNL lists" in order to avoid a fork.  Is this true?  If it is true, doesn't that mean your argument that "players can change the UNL" should be amended to disclose "players can change their UNL, but risk causing a hard-fork"?

- Shouldn't we build some kind of simulator or run a bunch of instances on localhost or something to observe e.g. the nodes reaching consensus?

- With respect to step 6 ("Once all transactions in my published proposal have at least 70% of the weighted vote convergence is guaranteed...")  What precisely is meant by convergence, and how is convergence guaranteed?  Mathematical proof, empirical simulation, practical experience (Ripple?), gut feeling, something else?

506
General Discussion / Re: BitShares X Status Update
« on: January 30, 2014, 07:20:35 am »

So all transactions are broadcast by another process, this algorithm is used to try to determine a subset S of the transactions known to the current node, such that all transactions in S are known to a large fraction of other nodes.  And then using this S as the set of transactions in the next block.

Why is this necessary at all?  What's wrong with just having every node do its own proof-of-stake on the set of transactions it knows about?

Also, what exactly are UNL nodes?  What is the process to become a UNL node?  If it's easy to become a UNL node, doesn't that make UNL vulnerable to sibyls?  If it's hard to become a UNL node, doesn't that make the network too centralized?

507
General Discussion / Re: BitShares X Status Update
« on: January 30, 2014, 06:42:34 am »

1) Every node publishes their initial transaction set to all other nodes in the UNL
2) A node will then tally the votes each transaction got as a percentage of the maximum (a vote from every node)
3) A node will then calculate the average "consensus" of each proposal by every other node (the average of the values calculated in step 2 for each proposal.   This average will then be used as the weight given to that transactions in that nodes proposal.  The result is that proposals with higher average consensus get a higher weight than proposals with lower average consensus.  If nodes want their opinion to carry weight they need to increase their average consensus in their next proposal.
4) I then recalculate the proposal for the current node by tallying the weighted votes each transaction got based upon the proposals it was included in.
5) I then take all transactions in the top 25% by weighted vote and publish them as my new proposal to all other nodes.
6) Once all transactions in my published proposal have at least 70% of the weighted vote convergence is guaranteed and a block can be produced and the process starts over.


Let's say a transaction is "popular" if it's in a lot of nodes' proposals, "unpopular" if only exists in a few nodes' proposals.

Won't your algorithm make unpopularity stable over time?

In other words, let's say there's a transaction that only exists on one node.  Won't other nodes always choose not to include it in their proposals because it's unpopular?

Of course, in a real network, pretty much all transactions enter the network from a single node.  So this analysis means no transaction will ever be accepted by any node other than its originator, and the network will be totally useless!  This absurd result tells me my analysis is wrong -- but how is it wrong?

508
I still think dividends should be implemented.  Consider two subsets of users:

(a) Internet savvy crypto-anarchists and economics nerds

(b) Ordinary people who just want to buy and sell stuff online

Everything I've read about Bitshares suggests that, while (a) will be an important part of the userbase for Bitshares (or any new altcoin that launches in the near future), we want to eventually break into (b).  And, while some subset of the users in (a) may well care more about inflation honesty, the people in market (b) really get more excited by things like "earn better interest than any bank will pay!" and "a piece of the action for every transaction!"

An individual user might theoretically be interested in the purchasing power of their money.  But this depends on more than the total amount of coins that have been created -- it's a dynamic equilibrium affected by the velocity of money, hoarders that keep coins for long periods of time and/or don't trade on the markets you care about, and the total amount of goods and services being exchanged.  Unlike the total number of coins that have ever been minted, the purchasing power of money is not something that could be automatically computed by the network.

And besides, there's a BitAsset for that :)  -- users who care can just convert their money to BitUSD (or later we might have some asset that's pegged to a basket of goods or something).

509
I think that this idea doesn't reduce the implementation complexity; it merely moves the complexity to the part of the code that deals with short sales.

Traditional investment brokerages charge interest to people who short stocks.

I thought from reading the whitepaper that the BitShares equivalent is implemented by denying the dividends from collateral to short sellers.  And I also thought this was not an optional feature, but an important market mechanism to maintain price stability, since any downward price movement will cause existing short positions to want to buy, covering the short and taking the profit, and possibly (but not necessarily) enter a new short position with less collateral.

So with Dividends 2.0, what would fulfill this role?

To put it a different way, a simple UI change suffices when the dividends are being delivered "fairly" to everyone who owns BTS.  But it's not obvious what should happen with short sellers.

Also, if transaction fees are destroyed instead of uniformly distributed, won't that eventually interfere with divisibility?

Pages: 1 ... 27 28 29 30 31 32 33 [34]