Skip to content

The synthesis function synth_cnot_count_full_pmh returns invalid circuits for certain section_size values #12106

@alexanderivrii

Description

@alexanderivrii

Environment

  • Qiskit version: 1.0
  • Python version: 3.10
  • Operating system: Windows

What is happening?

The following code

from qiskit.synthesis import synth_cnot_count_full_pmh
from qiskit.synthesis.linear import random_invertible_binary_matrix

mat = random_invertible_binary_matrix(5, seed=1234)
qc = synth_cnot_count_full_pmh(mat, section_size=6)

produces an empty circuit.

How can we reproduce the issue?

Run the code above.

What should happen?

Setting section_size to a large number would probably produce suboptimal results, however it should still produce a valid (non-empty) circuit.

Any suggestions?

I believe that something wrong is going on when section size is larger than the size of the matrix, for instance in the above example setting section_size to a number 5 or lower does work correctly.

Metadata

Metadata

Labels

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions