Introduction to Blockchain
This article is for everyone who is curious about this new cutting edge technology but has no idea of what it is. Don’t forget to check out the links given in between the content to get a better understanding.
What is Blockchain?
Blockchain comprises of two words, Block and Chain. To understand these terms let's consider a simple example of money transferring. Let's say you want to transfer some funds to your friends. Now before you make the transaction, you make sure that this information is recorded somewhere. In our case, it can be a bank or a register.
Now a transaction information may contain the following:
- Sender's Account Number
- Recipient's Account Number
- The Amount
- Date of transaction
And maybe some other information too…
Creating a record on a blockchain results in the following benefits :
- Greater Transparency : Everyone has the copy of the data.
- Enhanced Security : Transactions must be validated by everyone in the network before they are recorded.
- Improved traceability: As data in a blockchain in immutable (will will be discussed later) data once recorded remains on the chain forever.
What does a "Block" mean ?
In terms of Blockchain, these transaction information are collectively known as a block. A block contains all the information about any transaction. A block also has a unique Hash to identify itself on a network.
Hash usually looks like the following :
You can check out the following link and create a hash of your own ;)
A Block usually contains the following data:
1) Block’s Hash
4) Block Number.
The block Hash is calculated from the data and the nonce.
Here’s what a block looks like : Block Structure
These blocks are linked to each other to form the chain. Each block is dependent on the previous block.
Consider that we have 3 blocks B1, B2 and B3. Every block contain a group of transactions. .Each of these blocks have their own unique Hashes. Now to form a chain, the hash of the first block B1 is mentioned in the second block B2. Similarly, the hash of the second block B2 is mentioned in the third block B3. All the blocks validate each other through this hash value.
How information is secured?
There's something interesting that happens when you try to change some value in any of the block. The unique Hash that is used to identify each block is created using the following:
"Block Hash = Hash of Data + Nonce"
Notice the term "Nonce".
Nonce is nothing but a unique number that is added to the hash of the data. Now on changing the values of the block, the hash of the block changes too and the remain blocks get invalidated. That means that if a person tries to alter one block the rest of the blocks get altered and thus information remains encrypted for the rest of the blocks. I am sure that you want to try it for yourself? Right? Here’s a link : The Chain
Notice The hash values at the bottom of the blocks. Looks familiar right?.
Now try changing the value of one block.
Voila!! The rest of the blocks gets invalid.
Who are miners?
Miners are high performance computers that uses hit and trial method to find this nonce. This process is called Mining. Now for mining blocks in a blockchain, a lot of resources are used like electricity, powerful computers, High power GPUs etc.
For the immense hard work of the miners to mine the blocks, the network pays a fee to the miners. This fee is usually called Cryptocurrencies.
Cryptocurrencies are not real money but they use decentralized control as opposed to centralized digital currency and central banking system.