The blockchain

The technology behind bitcoin and the seed of every other cryptocurrency

Clarification

The term blockchain can refer to two different concepts:

From this point we'll capitalize the word "blockchain" when it refers to blockchain as technology and leave it lowercased if it refers to blockchain as record.

Introduction

We've already stated that the blockchain is the whole set of blocks and also the contents of a block: transactions. But let us start at the beginning: before we can understand how transactions work we need to clarify two key aspects: bitcoin addresses and coin splitting.

Bitcoin addresses

A bitcoin address is in some way like a bank account, but a lot simpler. It consists of a public key and a private key. The public key is what is actually known as "bitcoin address" because it can only be used to send bitcoins to that address and can be confidently shared with anyone, which its name implies, while the private key can be used to spend these bitcoins and is kept by the address owner. Read this article to find some general details about bitcoin addresses and a more conceptual picture of what they are.

Coin splitting

Imagine for a moment that bitcoin is a physical metal. Each transaction received would give you a piece of bitcoin. If you were to spend a part of that piece, you would have to split it into two parts so you can give one and keep the other. Well, that's how it actually works; let's say you receive 5 BTC and want to spend 1. Your transaction will consist of 1 input (the transaction where you received 5 BTC) and 2 outputs (1 output of 1 BTC for the person you spend the bitcoin with and 1 output of 4 BTC to an address owned by yourself, also known as change address).

Transactions

This is the final purpose of the Blockchain: it allows us to make transactions to other participants of the network. Before we dig into how they take place, let's clarify a key aspect: A transaction is a combination of inputs and outputs, meaning that the source of the funds to be transfered can come from one or more transactions* and can be sent to one or more addresses.

* The logic would say that money is transfered from one address to another, and that's actually happening. Even so we are saying that funds can come from one or more transactions, not addresses. This is because the inputs of a transaction are also transactions or, in other words, every transaction must come from a previous valid transaction. It means that, in order to spend all the funds contained in a bitcoin address that received funds from multiple transactions, the new transaction must include all the individual, previously received transactions.

Here's what happens when a transaction is made:

  1. Composing: all the information involved in the transaction (recipients, amount for each recipient, etc.) is packaged, forming an unsigned transaction.
  2. Signing: The unsigned transaction is signed using all the private keys of the bitcoin addresses involved in the inputs. The public key of the bitcoin address serves to verify that the signed transaction was actually signed by the private key. As a result, every node of the network is able to determine if any transaction is valid or not.
  3. Broadcasting: once the transaction is signed, it is broadcasted to the network. All other nodes that receive it and verify it's valid will keep broadcasting it over the network until it reaches all participants.

Block after block

The routine of the network is to validate and broadcast the transactions of all participants, thus allowing the circulation of money. We've already stated that transactions' information is stored in blocks, which in conjunction form the blockchain. A new block is created every 10 minutes on average and it contains all the transactions that took place while the block was being mined. Bitcoin mining is the process used to create new blocks and issue new bitcoins. Because of its complexity it deserves its own article which you can find here.

Related links

Do you like our content?
Let us know by giving us a follow
We'll respond! If we reach 2.000 we'll cover
even more specific content through a blog!