IAC 2024 - IA Fast Track to Search Focused AI Solutions
Blockchain technology for the grid
1. /SLAC
Executive Ed:
Blockchain Technology For the Grid
Mayank Malik
Chief Data Officer, Blockchain Lead
SLAC National Accelerator Laboratory
Stanford University
May 8, 2019
2. /SLACStanford
Introductions
Mayank Malik
• Working at the intersection of Big Data and Renewable Energy
• Prior experience working in investment banking and wholesale finance
• Masters in Computer Science from State University of New York at Buffalo
Chief Data Officer and Blockchain Lead
Grid Integration Systems and Mobility Group
SLAC National Accelerator Laboratory
Blockchain and Cloud Computing Instructor
Bits and Watts
Stanford University
3. /SLACStanford
Our goal today
• Walk-through fundamentals of Blockchain
• Introduction to Smart Contracts
• Ecosystem of Blockchain-based Startups,
Applications, and Platforms
• Blockchains in the Energy Industry
4. /SLACStanford
Agenda
8:00am - 10:00am Fundamentals
- Definitions
- Digital wallet deep dive (setup, transact)
- Understanding transactions from a user’s perspective
10:00am - 10:15am BREAK
10:15am – 11:30am Look under the hood
- How do blockchains work?
- Detailed examination of a transaction
- Ethereum network and Smart Contracts
11:30am – 11:50am Blockchain in the Energy Industry
- Evolution of electricity grid
- How can blockchain help
- Ecosystem of players, products, and platforms
- Challenges and benefits of implementing blockchain in the energy
industry
11:50am – 12:00pm Concluding Remarks and Session Adjourns
5. /SLACStanford
What is Blockchain?
Blockchain is an incorruptible digital ledger of
economic transactions that can be programmed
to record not just financial transactions but
virtually anything of value.
- Don Tapscott, The Tapscott Group
6. /SLACStanford
Part I: Fundamentals
• What’s in a wallet?
• What’s a wallet?
• What are the different types of wallets?
• How to set one up?
• There is no “one blockchain”
7. /SLACStanford
What’s in a wallet?
● Your Private Key
● One or more Public Key(s)
CRYPTO-WALLETS DO NOT CONTAIN COINS
CRYPTO-CURRENCY IS NOT STORED ANYWHERE
ONLY YOUR CLAIM ON THE CURRENCY IS STORED ON BLOCKCHAIN
8. /SLACStanford
Types of Wallet
Based upon where your keys are stored, there are
a few different types of wallets:
• Desktop
• Mobile
• Web
• Hardware
• Paper
9. /SLACStanford
Desktop Wallets
● Electrum (Intimidating UI, Secure, advanced features like address tagging,
fee adjustments, wallet encryption, signed messages, SPV or API option)
● Exodus (Pretty UI, excellent starter wallet, SPV wallet, Altcoin support)
● Bitcoin Core (Full Node wallet, Independent Verification)
● Copay (Multi-Signature / multisig wallet, extra security against theft, good
option if you can’t afford a hardware wallet)
● Armory (Secure, Features a variety of encryption and cold-storage options)
● Jaxx (Easy to use, excellent starter wallet, Altcoin support)
10. /SLACStanford
Mobile Wallets
● Electrum (Android only, Bitcoin only, Watch only option)
● Mycelium (Tried and tested security, >100,000 users, iOS and Android,
linked debit-card support)
● Mobi (Support for over 100 fiat currencies, instant cross-border payments,
bitcoin only)
● Coinbase (>8M users, multisig support, Easy UI, Simple to setup and use)
● Blockchain.info (14M users, Minimalist design and options)
16. /SLACStanford
There is no “one blockchain”
Public Private Consortium
Access Permission-less, open access Permissioned, authorized
participants only
Share-Permissioned, authorized
participants only
Identity Protection Identity obfuscated Identity traceable Identity traceable
Device Authentication Not required Required Conditional
Block Generation Decentralized through use of
resources such as compute
Centralized Implementation dependent;
centralized and/or decentralized
Consensus Mechanism Proof of Work
Proof of Stake
Proof of Stake
Proof of Authority
Proof of Work, Proof of Stake, Proof
of Authority
Manipulability Difficult, resource intensive Intervention by Central
Authority possible
Implementation dependent
Transaction Speed Slow Fast Fast than Public with upper limit of
Private; Implementation dependent
Energy Consumption High Low Low to Medium
Operating Cost Low Medium to High Low to Medium
17. /SLACStanford
Consensus
• Popular blockchains like Bitcoin and Ethereum
are permission-less
• Anyone can participate in transactions on
Bitcoin and Ethereum Blockchains
• But how does everyone agree on validity of
transactions?
–consensus mechanism (aka proof mechanism)
18. /SLACStanford
Proof-of-Work
”I have worked to validate a block of transactions.
Anyone can check that my work is correct. I have
validated the transaction faster than anyone else,
therefore, I get paid for providing the validation
service.
Why would I validate a manipulated block? Then I
would not earn anything for my work. “
19. /SLACStanford
Proof-of-Stake
“I have invested a great deal in this blockchain.
It’s continuity and functionality are important to
me, so you can trust me. I’ll build you a new block
and use the assets invested in this blockchain to
vouch for it’s validity. If the block is invalid or has
been manipulated, I’ll lose my investment.”
22. /SLACStanford
Central Promise of Blockchain
• Data Integrity
• Disintermediation
(unless, the intermediary ‘owns’ the blockchain)
• Automated Execution
23. /SLACStanford
Part II: Look under the hood
• How do blockchains work?
– What is mining and how does it work?
– Transaction Workflow
– Introduction to Distributed Consensus
• Introduction to Ethereum
• Examination of how Ethereum network works
– Interfacing with Ethereum Networks
– Intro to Metamask
– Understanding Ethereum Accounts
25. /SLACStanford
Where do Bitcoins come from?
Fiat Currency Cryptocurrencies
Controlled by Central Authority (Governments) No Central Authority
Printed when Government decides to print
more
Miners (human) use special software to solve math
problems are issued new bitcoins in exchange
The special software is called Miner (software)
This special software can be run on specialized
hardware to speed up mining and generate more
bitcoins.
This specialized hardware is called Miner (hardware)
26. /SLACStanford
Mining in early days
● Math problems were simple enough
● Anyone with a computer and miner (software)
could mine bitcoins
● Bitcoins mined at this time are sometimes
referred to as ‘CPU-mined bitcoins’
27. /SLACStanford
Mining in early years
● Gamers figured out that mining
with GPUs was faster
● GPU mining took-off
● But, GPUs consumed more
electricity and produced more
heat
28. /SLACStanford
Mining in mid years
● Companies started building
Application-Specific Integrated
Circuit (ASIC) to perform mining
operations.
● ASIC hardware is faster and more
energy efficient than GPUs
29. /SLACStanford
Mining today
● Contribute your hardware to
solving math problems in concert
with others
● Purchase into a specialized
datacenter specifically designed
for mining
● Share profits in proportion to
your contribution
31. /SLACStanford
Why are Miners rewarded?
Miners are required to validate bitcoin
transactions on the network, thereby providing a
critical service to the network.
If 51% of the network approved the validity of a
transaction, it is cleared (added to the blockchain)
32. /SLACStanford
Functions of mining
• Book-keeping: The bitcoin miner client downloads and syncs in real time
the entire blockchain of the bitcoin network
• Network guardians: Miners safeguard the network against hacks and
validate each transaction
• Settlement and Clearing: Blocks validated by miners are added to the
blockchain without dependence on a trusted 3rd party
• Creation of new bitcoins: Miners are rewarded with bitcoins for
contributing processing power and keeping the network safe
34. /SLACStanford
What is a transaction?
Transaction is a digitally signed declaration by one party of it’s intent to
transfer some bitcoins they posses to another party
35. /SLACStanford
Transaction Workflow
BTC LEDGER (State of the Network / Account of all Coins)
Ashley 10
Berk 12
David 13
Emre 50
Karen 26
Marie-Louise 70
Nani 123
● Everybody can see the ledger
● This is what a network looks like
except...
36. /SLACStanford
Transaction Workflow
● Everybody can see the ledger
● No one knows your name
● Your identity is represented by your
public key / verification key
● This is what a network looks like,
except...
BTC LEDGER (State of the Network / Account of all Coins)
MIIBOQIBAAJAT+qwrlMhJOkn3VSQQK... 10
FsPkKavfDcE19SFZnuJ4HHA0XMn3xD... 12
TtWttB/pfSh5FT/Wr6B3bRoM7nzWpeq... 13
AiEAnnIGwnywSjvpsecRrp9RTpVqgirn... 50
DesPyX5YO5eXSieI8cV5xs+nDsz6KwIh... 26
WdqKfiE5+YcBAiBP0aaBTe8xk5TNW0h…. 70
wi4V/2ZlZnl6kn+QgtKx+hQC8ZWKvBcb... 123
37. /SLACStanford
Transaction Workflow
● Everybody can see the ledger
● No one knows your name
● Your identity is represented by your
public key / verification key
● No one knows who you are unless
they transact with you in person
Governments and Financial Institutions do
not like this.
BTC LEDGER (State of the Network / Account of all Coins)
MIIBOQIBAAJAT+qwrlMhJOkn3VSQQK... 10
FsPkKavfDcE19SFZnuJ4HHA0XMn3xD... 12
TtWttB/pfSh5FT/Wr6B3bRoM7nzWpeq... 13
AiEAnnIGwnywSjvpsecRrp9RTpVqgirn... 50
DesPyX5YO5eXSieI8cV5xs+nDsz6KwIh... 26
WdqKfiE5+YcBAiBP0aaBTe8xk5TNW0h…. 70
wi4V/2ZlZnl6kn+QgtKx+hQC8ZWKvBcb... 123
38. /SLACStanford
Transaction Workflow
BTC LEDGER (State of the Network / Account of all Coins)
MIIBOQIBAAJAT+qwrlMhJOkn3VSQQK... 10
FsPkKavfDcE19SFZnuJ4HHA0XMn3xD... 12
TtWttB/pfSh5FT/Wr6B3bRoM7nzWpeq... 13
AiEAnnIGwnywSjvpsecRrp9RTpVqgirn... 50
DesPyX5YO5eXSieI8cV5xs+nDsz6KwIh... 26
WdqKfiE5+YcBAiBP0aaBTe8xk5TNW0h…. 70
wi4V/2ZlZnl6kn+QgtKx+hQC8ZWKvBcb... 123
Node with public key , digitally signs a
declaration announcing to the network, it’s
intent to transfer 10 bitcoins they possess
to node with public key .
Network’s job is to verify that node with
public key , does possess 10 or more
bitcoins.
10
39. /SLACStanford
Transaction Workflow
BTC LEDGER (State of the Network / Account of all Coins)
MIIBOQIBAAJAT+qwrlMhJOkn3VSQQK... 10
FsPkKavfDcE19SFZnuJ4HHA0XMn3xD... 12
TtWttB/pfSh5FT/Wr6B3bRoM7nzWpeq... 13
AiEAnnIGwnywSjvpsecRrp9RTpVqgirn... 50
DesPyX5YO5eXSieI8cV5xs+nDsz6KwIh... 26
WdqKfiE5+YcBAiBP0aaBTe8xk5TNW0h…. 70
wi4V/2ZlZnl6kn+QgtKx+hQC8ZWKvBcb... 123
At any given time, there are multiple
declarations of transactions being
proposed to the network.
Several of these proposed transactions are
combined to form a Block.
10
40. /SLACStanford
Transaction Workflow
BTC LEDGER (State of the Network / Account of all Coins)
MIIBOQIBAAJAT+qwrlMhJOkn3VSQQK... 10
FsPkKavfDcE19SFZnuJ4HHA0XMn3xD... 22
TtWttB/pfSh5FT/Wr6B3bRoM7nzWpeq... 13
AiEAnnIGwnywSjvpsecRrp9RTpVqgirn... 50
DesPyX5YO5eXSieI8cV5xs+nDsz6KwIh... 26
WdqKfiE5+YcBAiBP0aaBTe8xk5TNW0h…. 70
wi4V/2ZlZnl6kn+QgtKx+hQC8ZWKvBcb... 113
Transaction, once verified, will change the
ledger state to below.
10
42. /SLACStanford
Bitcoin vs. Ethereum
Bitcoin Ethereum
Cap 21 million; ~17 million mined Cap unknown; ~100 million mined
Issuance ~ 75 / hour ~ 720 / hour
Block Creation New block every 10 min New block every 15 seconds
Hash SHA-256 KECCAK-256
Smart Contracts Limited scripting support Turing complete language
Transaction Costs Based on size of transaction Based on gas, a token used to measure cost
of every operation and storage on the chain
Accounts User accounts User accounts and Smart Contracts (which
have their own account)
Distributed Consensus Proof-of-Work Proof-of-Stake **
43. /SLACStanford
Smart Contracts: Benefits & Challenges
Benefits:
● Security - if someone wants to modify a contract, everyone gets a warning
● Self-executing
● Distributed/Decentralized
● Machine-to-Machine (M2M)
Challenges:
● Scalability of the chain
● Difficult for legal contracts, which need human interpretation
● Computation power
● Difficult to update a smart contract
52. /SLACStanford
Blockchain offers compelling solutions when…
q Data which should be stored collectively is
fragmented at source
q Multiple producers of data exist
q There is absence of trust
q There is lack of security
53. /SLACStanford
Issues that blockchain can solve
q Multiple databases referencing the same set of
objects
q Significant reconciliation activity
q Operational efficiencies due to manual
processes
54. /SLACStanford
Blockchain adoption could yield the following
benefits:
q Reconciliation elimination
q Standardization and harmonization
q Automation; ‘code as law’ (smart contracts)
q Reduce systemic risk
56. /SLACStanford
Use Cases
• Certificates of origin
• Congestion management in electricity distribution grids (e-
mobility)
• Registration of installations in an asset registry
• Landlord-to-tenant electricity supply
• P2P trading between customers of an electricity supplier
• Electricity wholesale trading (OTC)
58. /SLACStanford
Energy Web Foundation
• Open-source, scalable platform designed for
energy sector’s regulatory, operational, and
market needs
• 3 Core technologies:
– EWF Tobaloba Network (Proof-of-Authority)
– EW Origin App for Renewable Energy Certification
– D3A Decentralized Autonomous Area Agent
61. /SLACStanford
Mobility Open Blockchain Initiative
Mission: non-profit organization working with forward thinking companies,
governments, and NGOs to make mobility services more efficient, affordable,
greener, safer, and less congested by promoting standards and accelerating
adoption of blockchain, distributed ledger, and related technologies
Critical Use Cases:
● Vehicle ID + history
● Autonomous machine payments
● Driving data markets
● Car & ride sharing
63. /SLACStanford
Share&Charge
• Vehicle to Grid (V2G) services use electric vehicles as an energy storage
solution, while they are parked, which is on average 80% of the time.
• Such services all EV owners to make money by storing and selling
electricity back to the grid.
• For E.g. Share&Charge allows blockchain-based tracking and billing of
electricity purchased for EVs. In addition, it allows participants to make
their private charging stations available to others. Payment and billing are
handles automatically using smart contracts.
• Share&Charge was a collaboration between Innogy and Slock.it and is
now run by MotionWerk.
64. /SLACStanford
Share&Charge
• Share&Charge has 1000 registered users in
Germany, with around 1300 active charging
stations.
• Share&Charge has partnered with
eMotorWorks to offer their platform in
California.
65. /SLACStanford
eCharge
● Places fully managed charging
stations at hotels
● Travelers and hotel guests are
allowed to use the charging
station.
● With the growing demand for e-
vehicles, the charging stations will
get a “necessity” status in the
hotels, just like Wi-Fi has evolved
from being a luxury to a must-
have service.
● Can provide DR services to grid.
68. /SLACStanford
Renewable Energy Certificates (RECs)
• RECs are tradable, non-tangible energy
commodities in the US that represent
proof that 1MWh of electricity was
generated from an eligible renewable
energy resource and fed into the shared
system of power lines which transport
energy.
• Blockchain is being used to track issuance
and transactions of RECs.
• Similar solutions are being deployed in
France, Germany, UAE.
• In general, blockchain has tremendous
promise in the area of certification.
70. /SLACStanford
Tokenizing and trading energy (E.g. Power Ledger)
• Power Ledger ties
together municipal and
commercial, solar,
storage, EV charging, and
water treatment with
blockchain approaches,
then use analytics to
optimize the mix
• $8 million AUD project
for blockchain-enabled
electricity and water
utilities in Fremantle
71. /SLACStanford
Microgrids
• A microgrid is a group of interconnected loads
and distributed energy resources (DERs) with
clearly defined electrical boundary that acts as
a single controllable entity with respect to the
grid.
• Blockchain is being used to perform aggregate
energy transactions between virtual electrical
islands of loads and DERs.
72. /SLACStanford
Proof-of-Control
• Scarcity is key to assign value to blockchain-
managed assets, typically tokens.
• Scarcity is also inherent in an energy system.
• Control devices can provide a valuable service
to the grid by alleviating scarcity through better
redistribution of resources.
74. /SLACStanford
Questions for the group
● What blockchain use cases are you/your companies working on?
● What use cases are most appropriate for a coin or token-based
applications in energy?
● What blockchain hardware/software considerations should be prioritized
for energy systems?
● How could a blockchain-based data marketplace potentially facilitate
greater integration of renewables?