Author

Topic: Multisig Derivatives (Read 1303 times)

full member
Activity: 132
Merit: 100
willmathforcrypto.com
December 25, 2015, 02:41:09 PM
#8
I'm still working on a pdf, but I've now found a way to present things simply in terms of simulated buying and selling. Here's a medium article I just published that has an example and a general definition of a "contract" associated with a multisig pool.

https://medium.com/@trentrussell/contracts-simulating-crypto-fiat-exchanges-6f9421ea520c

If there's something in this writeup that is unclear, please let me know.
sr. member
Activity: 266
Merit: 250
December 18, 2015, 05:32:09 PM
#7
This is really interesting. Thank you and I will be waiting for your new paper.
Can you tell me how did you learn this kind of things?

I'm a mathematician with an interest in cryptocurrency and economics. The mathematics involved financial derivatives is deep (and not my field). It occurred to me earlier this year that simple financial derivatives could be simulated using multisig pools and some basic algebra.


Thank you for your good works and this kind of stuff always seems to fun. Please notify me when you done your new paper.
full member
Activity: 132
Merit: 100
willmathforcrypto.com
December 18, 2015, 05:03:12 PM
#6
This is really interesting. Thank you and I will be waiting for your new paper.
Can you tell me how did you learn this kind of things?

I'm a mathematician with an interest in cryptocurrency and economics. The mathematics involved financial derivatives is deep (and not my field). It occurred to me earlier this year that simple financial derivatives could be simulated using multisig pools and some basic algebra.
sr. member
Activity: 266
Merit: 250
December 18, 2015, 04:44:00 PM
#5
I've been thinking about this idea again and had some new insights.

In the paper above I used a function f(p) of the price p to determine how much of the pool should be paid to Alice and how much should be paid to Bob. If Alice wanted the value to remain stable, as long as the price p remained above s, then f(p) = s(1/p). In Section 5 I briefly described how the same idea could be used to "short" the price by taking f(p) = s(1+d)(1/p) - d for some positive "d value."

This "d value" seemed a little mysterious to me. By reformulating things, I think the situation can be described in a clearer way.

Suppose Alice has a coins, and each coin is currently worth c dollars. The payout function can be

f(p) = (a0 + a1/p)/(a+b)

where a0 and a1 are chosen such that a0 + a1/c = a. The value b is the number of coins Bob (the counterparty) contributes to the multisig pool.

The idea here is clear: Alice wants to simulate have a0 coins and a1 dollars, where the total current value is ac.

Choosing a0 to be 0 corresponds to simulating holding all of the value in dollars. This is the main case discussed in the paper.

Choosing a0 < 0 corresponds to shorting, as it simulates having a negative number of coins.

Choosing a0 > a corresponds to going long, as it simulates having extra coins.

I'll try to write a new paper using this point of view.

This is really interesting. Thank you and I will be waiting for your new paper.
Can you tell me how did you learn this kind of things?
full member
Activity: 132
Merit: 100
willmathforcrypto.com
December 18, 2015, 04:37:50 PM
#4
I've been thinking about this idea again and had some new insights.

In the paper above I used a function f(p) of the price p to determine how much of the pool should be paid to Alice and how much should be paid to Bob. If Alice wanted the value to remain stable, as long as the price p remained above s, then f(p) = s(1/p). In Section 5 I briefly described how the same idea could be used to "short" the price by taking f(p) = s(1+d)(1/p) - d for some positive "d value."

This "d value" seemed a little mysterious to me. By reformulating things, I think the situation can be described in a clearer way.

Suppose Alice has a coins, and each coin is currently worth c dollars. The payout function can be

f(p) = (a0 + a1/p)/(a+b)

where a0 and a1 are chosen such that a0 + a1/c = a. The value b is the number of coins Bob (the counterparty) contributes to the multisig pool.

The idea here is clear: Alice wants to simulate have a0 coins and a1 dollars, where the total current value is ac.

Choosing a0 to be 0 corresponds to simulating holding all of the value in dollars. This is the main case discussed in the paper.

Choosing a0 < 0 corresponds to shorting, as it simulates having a negative number of coins.

Choosing a0 > a corresponds to going long, as it simulates having extra coins.

I'll try to write a new paper using this point of view.
full member
Activity: 132
Merit: 100
willmathforcrypto.com
June 28, 2015, 06:07:46 AM
#3
Thanks! I updated the links to point to clamsight.
hero member
Activity: 784
Merit: 1002
CLAM Developer
June 27, 2015, 07:58:58 PM
#2
Recently I started thinking about how parties could form a kind of derivative contract by pooling some cryptocurrency at a multisig address. I posted about it earlier this month here:
https://bitcointalksearch.org/topic/m.11515522
Since then I've done a few examples by hand to demonstrate the idea. I did them using clams instead of bitcoin since clams has a "clamSpeech" part of a transaction. This let me write out the details of the contract in a way that is readable and must be cryptographically signed by the parties. The same thing could be done with OP_RETURN in bitcoin, it just wouldn't be as nicely visible on explorer websites.
I also worked out the relevant algebra and wrote it up, with the examples, as a short paper:
http://willmathforcrypto.com/multisigderivs.pdf
If you want to get a quick idea for how it works, here is one the examples with links to a clam explorer showing the transaction details.
Alice and Bob had some clams on June 23, 2015. Clams were trading at $1.60 at the time. They pooled some of their clams together into a 2-of-2 multisig address. Alice put in about $1.59 worth and Bob put in about $1.30 worth. The signed agreement is that the next day Alice gets $1.59 worth of clams out of the pool and Bob gets the rest. The "value" is based on the price at 10AM on June 24, 2015.
Here's the transaction making the contract and funding the multisig address:
http://khashier.com/tx/f84f28e813118b78d7d03c535042bc94fa1f32de3d8a599854d45866f481783e
The price of clams at 10AM on June 24 turned out to be $1.73, so Alice got approximately $1.59 worth of clams out of the pool and Bob got the rest which were worth $1.53. Essentially Alice sold her volatility risk to Bob and as a result Bob realized a gain of over 17% when the price went up 8%.
Here's the transaction settling the contract.
http://khashier.com/tx/b0a0312c7724c1b130300b9c5ae9db23148ed6194985d4b4879dca17fb889a0a
The actual transactions have a little extra clams in them to take care of mining fees and a "security deposit," as explained in the paper.
There's also an example showing how Alice shorted the price of clams.
I suspect this idea is already out there, and is possibly already in use. If so, I'll be happy if someone points it out. In general, feedback on the idea is welcome.

An interesting and well written paper.

You should link the transaction at the clamsight.com explorer, as the khashier.com explorer still has some issues.

ex. http://clamsight.com/tx/b0a0312c7724c1b130300b9c5ae9db23148ed6194985d4b4879dca17fb889a0a
full member
Activity: 132
Merit: 100
willmathforcrypto.com
June 27, 2015, 03:36:48 PM
#1
Recently I started thinking about how parties could form a kind of derivative contract by pooling some cryptocurrency at a multisig address. I posted about it earlier this month here:

https://bitcointalksearch.org/topic/m.11515522

Since then I've done a few examples by hand to demonstrate the idea. I did them using clams instead of bitcoin since clams has a "clamSpeech" part of a transaction. This let me write out the details of the contract in a way that is readable and must be cryptographically signed by the parties. The same thing could be done with OP_RETURN in bitcoin, it just wouldn't be as nicely visible on explorer websites.

I also worked out the relevant algebra and wrote it up, with the examples, as a short paper:

http://willmathforcrypto.com/multisigderivs.pdf

If you want to get a quick idea for how it works, here is one the examples with links to a clam explorer showing the transaction details.

Alice and Bob had some clams on June 23, 2015. Clams were trading at $1.60 at the time. They pooled some of their clams together into a 2-of-2 multisig address. Alice put in about $1.59 worth and Bob put in about $1.30 worth. The signed agreement is that the next day Alice gets $1.59 worth of clams out of the pool and Bob gets the rest. The "value" is based on the price at 10AM on June 24, 2015.

Here's the transaction making the contract and funding the multisig address:

http://clamsight.com/tx/f84f28e813118b78d7d03c535042bc94fa1f32de3d8a599854d45866f481783e

The price of clams at 10AM on June 24 turned out to be $1.73, so Alice got approximately $1.59 worth of clams out of the pool and Bob got the rest which were worth $1.53. Essentially Alice sold her volatility risk to Bob and as a result Bob realized a gain of over 17% when the price went up 8%.

Here's the transaction settling the contract.

http://clamsight.com/tx/b0a0312c7724c1b130300b9c5ae9db23148ed6194985d4b4879dca17fb889a0a

The actual transactions have a little extra clams in them to take care of mining fees and a "security deposit," as explained in the paper.

There's also an example showing how Alice shorted the price of clams.

I suspect this idea is already out there, and is possibly already in use. If so, I'll be happy if someone points it out. In general, feedback on the idea is welcome.
Jump to: