TransWikia.com

How to optimize my HHL algorithm on qiskit?

Quantum Computing Asked on April 29, 2021

I am following this HHL tutorial to solve the $Ax=b$ problem and have been using the general (inefficient) approach with the BasicAer simulator that they describe in section 4a. I would now like to run on the actual IBMQ machines but I am finding that my circuit depth and CNOT counts are quite high. To solve this issue, I would like to optimize my circuit. In section 4b of the tutorial they outline a method of optimizing their specific problem which substantially reduces the qubit count, circuit depth, and CNOT count. The problem I am having is figuring out how to extend this to larger matrices $A$ than the $2$x$2$ that they use. Is there a general approach to optimizing an HHL circuit?

One Answer

There isn't any specific method to optimise HHL other than using the PassManager from Qiskit, but this is a more general circuit optimisation. With the newest devices it might be possible to run larger circuits due to the reduced error, otherwise you will have to manually find circuit reductions.

In the last page of https://arxiv.org/abs/2009.04484 you can find the circuits for the example mentioned in the textbook and for the case of a $4times 4$ matrix, maybe this helps to run your circuit.

Correct answer by user96233 on April 29, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP