Quantum Computing Experimentation with Amazon Braket: Explore Amazon Braket quantum computing to solve combinatorial optimization problems
- Length: 422 pages
- Edition: 1
- Language: English
- Publisher: Packt Publishing
- Publication Date: 2022-07-29
- ISBN-10: 1800565267
- ISBN-13: 9781800565265
- Sales Rank: #1362527 (See Top 100 Books)
Augment your quantum computing journey using Amazon Braket with in-depth details of how to use Braket devices, build quantum circuits, leverage quantum annealing and solve optimization problems
Key Features
- Learn about various quantum devices and their use in solving combinatorial optimization problems
- Prepare your business to leverage the benefits of the future quantum speedup
- Implement quantum computing concepts through real-world optimization use cases
Book Description
Amazon Braket is a cloud-based pay-per-use platform for executing quantum algorithms on cutting-edge quantum computers and simulators. It is ideal for developing robust apps with the latest quantum devices.
With this book, you’ll take a hands-on approach to learning how to take real-world problems and run them on quantum devices. You’ll begin with an introduction to the Amazon Braket platform and learn about the devices currently available on the platform, their benefits, and their purpose. Then, you’ll review key quantum concepts and algorithms critical to converting real-world problems into a quantum circuit or binary quadratic model based on the appropriate device and its capability. The book also covers various optimization use cases, along with an explanation of the code. Finally, you’ll work with a framework using code examples that will help to solve your use cases with quantum and quantum-inspired technologies. Later chapters cover custom-built functions and include almost 200 figures and diagrams to visualize key concepts. You’ll be able to scan the capabilities provided by Amazon Braket and explore the functions to adapt them for specific use cases.
By the end of this book, you’ll have the tools to integrate your current business apps and AWS data with Amazon Braket to solve constrained and multi-objective optimization problems.
What you will learn
- Explore the features and uses of the Amazon Braket console and components
- Discover the benefits of quantum computing devices available on Amazon Braket, including gate quantum computers, the annealer, and simulators
- Recognize which type of quantum device is the best fit for specific use cases and scaling
- Develop your own code from a basic set of use cases dealing with real-world optimization problems
- Understand the capabilities and limitations of current quantum computing technologies
- Explore the advanced features and API functions in Amazon Braket
Who this book is for
This book is for IT practitioners, architects, and developers looking to bring the power of quantum computing to their organizations. If you are a VP of IT, CIO, VP of architecture, chief architect, solution architect, actuarial fellow, or a developer already working on other AWS services such as AWS Lambda and EC2, you’ll find this book useful in exploring how to leverage Amazon Braket for real-world use cases and to move your organization towards this emerging technology. Familiarity with the basics of quantum computing and Python is required.
Quantum Computing Experimentation with Amazon Braket Foreword Reviews Contributors About the author About the reviewers Preface Reasons to get into Amazon Braket Who this book is for What this book covers To get the most out of this book What should you know before starting this book? Download the example code files Download the color images Conventions used Get in touch Share Your Thoughts Introduction Section 1: Getting Started with Amazon Braket Chapter 1: Setting Up Amazon Braket Technical requirements The overall Amazon Braket landscape Creating an AWS account Starting the Amazon Braket service Configuring the AWS S3 service Working with the notebook service Starting the notebook service in Braket Using notebooks and examples in Braket Shutting down the notebook service in Braket Remote access to Amazon Braket using Boto3 Validating if SDK installation is working Signing in to the AWS account Summary Further reading Chapter 2: Braket Devices Explained Annealing-based quantum devices Introducing D-Wave quantum devices Gate-based quantum devices An overview of IonQ's quantum device Introducing Rigetti quantum devices Oxford Quantum Circuits Amazon Braket simulators Simulators executing on a local device Simulators executing on Amazon resources Summary Further reading Chapter 3: User Setup, Tasks, and Understanding Device Costs Technical requirements Setting up user groups and users Creating a user group Setting up users Creating a policy for users Running test code Finding your tasks and results Understanding device costs and billing QPU versus simulator devices Viewing your charges Summary Further reading Chapter 4: Writing Your First Amazon Braket Code Sample Technical requirements Finding active devices Assigning a device Using the local simulator Using Amazon simulators or quantum devices Estimating the cost of the device Creating a simple quantum circuit Putting together a simple quantum circuit example Representing a binary value using a quantum circuit Running a circuit on the Amazon simulator Actual cost of using the Amazon simulator Summary Further reading Concluding Section 1 Section 2: Building Blocks for Real-World Use Cases Chapter 5: Using a Quantum Annealer – Developing a QUBO Function and Applying Constraints Technical requirement Solving optimization problems Simulated annealing Quantum annealing Quadratic Unconstrained Binary Optimization (QUBO) problems A simple conceptual model for D-Wave A QUBO example using three variables and ExactSolver() Running the three-variable problem on D-Wave annealer A party optimization example A team selection example A simple process for solving problems using D-Wave Reviewing data Representing the problem in graph form Summarizing the problem The traditional formulation A tool to visualize the energy landscape A simple penalty function to implement the constraint Running the problem on classical and quantum solvers Summary Further reading Chapter 6: Using Gate-Based Quantum Computers – Qubits and Quantum Circuits Technical requirements What is a quantum circuit? Understanding the basics of a qubit Using matrix mathematics Using matrix mathematics to represent single-qubit gates Using quantum gates in a quantum circuit Single-qubit gate rotation example – the Bloch Clock Representing the hour of the day using θ Representing the minutes and seconds using φ Building multiple qubit quantum circuits Three-qubit circuit example Example inspired by the Google Supremacy experiment The actual Google experiment Circuit implementation on Amazon Braket Execution results for a single 7x2 circuit Summary Further reading Chapter 7: Using Gate Quantum Computers – Basic Quantum Algorithms Technical requirements What is a quantum Oracle? Observing the effect of amplitude amplification Grover's operator using unitary matrices Grover's search algorithm using quantum circuits Repetitions of the Grover diffuser operator Using Grover's algorithm in searches Working with phases Translating between the Computational basis and the Fourier basis Adding phase information to a qubit How the phase adder circuit is used in quantum circuits Using Quantum Fourier Transform and its inverse Adding numbers using the phase adder Summary Further reading Chapter 8: Using Hybrid Algorithms – Optimization Using Gate-Based Quantum Computers Technical requirements Representing a binary quadratic function using a phase adder Introduction to QAOA concepts Experimentally validating QAOA concepts Fine-tuning parameters for QAOA Implementing QAOA for optimization Summary Further reading Chapter 9: Running QAOA on Simulators and Amazon Braket Devices Technical requirements Further QAOA considerations Full QAOA hybrid algorithm using a classical parameter optimizer Multiple-step parameter optimization in QAOA Benchmarking QAOA on Amazon Braket devices Optimizing an 11x11 matrix Optimizing a 34x34 matrix Optimizing a 38x38 sparse matrix Summary of results Summary Further reading Concluding section 2 Section 3: Real-World Use Cases Chapter 10: Amazon Braket Hybrid Jobs, PennyLane, and other Braket Features Technical requirement Utilizing Amazon Braket Hybrid Jobs Permissions Using Amazon Braket Hybrid Jobs A QAOA example using Amazon Braket Hybrid Jobs Job Control Code Job Source Module Xanadu PennyLane Calling Amazon Braket devices from PennyLane Using PennyLane within Amazon Braket Hybrid Jobs Xanadu Borealis IBM Qiskit Other Amazon Braket Hybrid Jobs features Controlling the region of the environment Hardware configuration Multiple parallel device execution Debugging failed jobs Containers Summary Further reading Chapter 11: Single-Objective Optimization Use Case Technical requirements Introduction to the knapsack problem Visualizing the knapsack problem QUBO formulation for the knapsack problem Implementing the knapsack QUBO in code Stitching the QUBO matrices together Getting results from different QUBO samplers Using the probabilistic sampler Running the knapsack problem on a D-Wave device Running the knapsack problem on Amazon Braket simulator SV1 Running the knapsack optimization problem on a Rigetti Aspen 11 device Running on a Rigetti Aspen M-1 device A process for solving constrained optimization problems Summary Further reading Chapter 12: Multi-Objective Optimization Use Case Technical requirements Looking into a mock inventory management problem Setting up the multi-objective problem Evaluating the best product mix based on scenario A Determining the conflict based on the opposing objectives Evaluating the results with the probabilistic solver Evaluating the optimal values using the D-Wave annealer Determining a better global solution Evaluating with the classical probabilistic solver Evaluating the best solution using D-Wave Summary Further reading Concluding section 3 Appendix – Knapsack BQM Derivation Getting started with the derivation Creating the required matrices Conclusion Why subscribe? Other Books You May Enjoy Packt is searching for authors like you
Donate to keep this site alive
How to download source code?
1. Go to: https://github.com/PacktPublishing
2. In the Find a repository… box, search the book title: Quantum Computing Experimentation with Amazon Braket: Explore Amazon Braket quantum computing to solve combinatorial optimization problems
, sometime you may not get the results, please search the main title.
3. Click the book title in the search results.
3. Click Code to download.
1. Disable the AdBlock plugin. Otherwise, you may not get any links.
2. Solve the CAPTCHA.
3. Click download link.
4. Lead to download server to download.