The Essentials of Bitcoin Mining: How It Works and Why It Matters.