Where did the program come from that makes bitcoins? How can it just be answers to mathematical problems?

423 views

Where did the program come from that makes bitcoins? How can it just be answers to mathematical problems?

In: Technology

4 Answers

Anonymous 0 Comments

First of all, there’s no such thing as “making” a bitcoin. Bitcoin mining is actually the process that keeps the transaction history secure, and by participating in it, you can be rewarded with Bitcoin added to your balance (out of nowhere). You aren’t actually working to create a Bitcoin, you’re working to keep the history secure, and by doing that, you get Bitcoin.

So how do we keep it secure? First, we have to talk hash functions. A hash function takes some input of any length, and produced a fixed length output. One important trait of hash functions is that you cannot do them in reverse. If you have the hash, you can’t get the original data back. One other important function is that a small change in the input data results in a large change in the hash output, so you can’t “navigate” your way in the hash values.

Now let’s talk about how we keep Bitcoin transactions secure with hashing. Every 10 minutes or so, the Bitcoin transaction history needs to be “sealed”. This transaction history has any number of transactions in it, the hash value of the previous sealed block, as well as something called a *nonce*. The nonce is a field that anyone can write any value in, but its purpose is to manipulate the value of the hash function on that transaction block.

In order to seal the block, you need to find a nonce value that results in a hash with a specific trait. Specifically, we look for a hash that ends in **n** 0’s, where n can be adjusted to make it harder or easier. Since we can’t calculate the hash backwards, we just need to guess a random nonce, run the hash, and if it works, we submit it. If it doesn’t, we throw it away and try again.

Importantly, this takes a significant amount of computer resources to do all these hashing calculations. If you get too much computing power and the hashes calculate too fast, you just increase the number of 0’s you need on the hash.

If someone wants to rewrite the history, they need enough computing power to redo the entire chain. Since every block has the hash of the previous block in it, if you want to go back and edit the block 5 prior, you need to hash that block, which changes the hash of the next block, and the next, and the next, and the next.

You are viewing 1 out of 4 answers, click here to view all answers.