§
    º³ÙgÚñ  ã                  ó–  — d Z ddlmZ ddlZddlZddlZddlm	Z	 ddl
mZmZmZmZmZmZmZmZmZmZmZmZ ddlmZ ddlmZmZmZmZmZmZ ddl m!Z!m"Z"m#Z# dd	l$m%Z% dd
l&m'Z'm(Z(m)Z) ddl*m+Z+m,Z, ddl-m.Z.m/Z/m0Z0m1Z1m2Z2m3Z3 ddl4m5Z5m6Z6 ddl7m8Z8m9Z9m:Z:m;Z;m<Z< ddl=m>Z> ddl?m@Z@ ddlAmBZB  G d„ deB¦  «        ZC G d„ deB¦  «        ZD G d„ deB¦  «        ZE G d„ deB¦  «        ZF G d„ deB¦  «        ZG G d„ deB¦  «        ZH G d„ d eB¦  «        ZI G d!„ d"eB¦  «        ZJ G d#„ d$eB¦  «        ZK G d%„ d&eB¦  «        ZL G d'„ d(eB¦  «        ZM G d)„ d*eB¦  «        ZN G d+„ d,eB¦  «        ZO G d-„ d.eB¦  «        ZP G d/„ d0eB¦  «        ZQ G d1„ d2eB¦  «        ZR G d3„ d4eB¦  «        ZS G d5„ d6eB¦  «        ZT G d7„ d8eB¦  «        ZU G d9„ d:eB¦  «        ZV G d;„ d<eB¦  «        ZW G d=„ d>eB¦  «        ZX G d?„ d@eB¦  «        ZY G dA„ dBeB¦  «        ZZ G dC„ dDeB¦  «        Z[ G dE„ dFeB¦  «        Z\ G dG„ dHeB¦  «        Z] G dI„ dJeB¦  «        Z^ G dK„ dLeB¦  «        Z_ G dM„ dNeB¦  «        Z` G dO„ dPeB¦  «        Za G dQ„ dReB¦  «        Zb G dS„ dTeB¦  «        Zc G dU„ dVeB¦  «        Zd G dW„ dXeB¦  «        Ze G dY„ dZeB¦  «        Zf G d[„ d\eB¦  «        Zg G d]„ d^eB¦  «        Zh G d_„ d`eB¦  «        ZidS )aaa&  

High Level Synthesis Plugins
-----------------------------

Clifford Synthesis
''''''''''''''''''

.. list-table:: Plugins for :class:`qiskit.quantum_info.Clifford` (key = ``"clifford"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Targeted connectivity
      - Description
    * - ``"ag"``
      - :class:`~.AGSynthesisClifford`
      - all-to-all
      - greedily optimizes CX-count
    * - ``"bm"``
      - :class:`~.BMSynthesisClifford`
      - all-to-all
      - optimal count for `n=2,3`; used in ``"default"`` for `n=2,3`
    * - ``"greedy"``
      - :class:`~.GreedySynthesisClifford`
      - all-to-all
      - greedily optimizes CX-count; used in ``"default"`` for `n>=4`
    * - ``"layers"``
      - :class:`~.LayerSynthesisClifford`
      - all-to-all
      -
    * - ``"lnn"``
      - :class:`~.LayerLnnSynthesisClifford`
      - linear
      - many CX-gates but guarantees CX-depth of at most `7*n+2`
    * - ``"default"``
      - :class:`~.DefaultSynthesisClifford`
      - all-to-all
      - usually best for optimizing CX-count (and optimal CX-count for `n=2,3`)

.. autosummary::
   :toctree: ../stubs/

   AGSynthesisClifford
   BMSynthesisClifford
   GreedySynthesisClifford
   LayerSynthesisClifford
   LayerLnnSynthesisClifford
   DefaultSynthesisClifford


Linear Function Synthesis
'''''''''''''''''''''''''

.. list-table:: Plugins for :class:`.LinearFunction` (key = ``"linear"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Targeted connectivity
      - Description
    * - ``"kms"``
      - :class:`~.KMSSynthesisLinearFunction`
      - linear
      - many CX-gates but guarantees CX-depth of at most `5*n`
    * - ``"pmh"``
      - :class:`~.PMHSynthesisLinearFunction`
      - all-to-all
      - greedily optimizes CX-count; used in ``"default"``
    * - ``"default"``
      - :class:`~.DefaultSynthesisLinearFunction`
      - all-to-all
      - best for optimizing CX-count

.. autosummary::
   :toctree: ../stubs/

   KMSSynthesisLinearFunction
   PMHSynthesisLinearFunction
   DefaultSynthesisLinearFunction


Permutation Synthesis
'''''''''''''''''''''

.. list-table:: Plugins for :class:`.PermutationGate` (key = ``"permutation"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Targeted connectivity
      - Description
    * - ``"basic"``
      - :class:`~.BasicSynthesisPermutation`
      - all-to-all
      - optimal SWAP-count; used in ``"default"``
    * - ``"acg"``
      - :class:`~.ACGSynthesisPermutation`
      - all-to-all
      - guarantees SWAP-depth of at most `2`
    * - ``"kms"``
      - :class:`~.KMSSynthesisPermutation`
      - linear
      - many SWAP-gates, but guarantees SWAP-depth of at most `n`
    * - ``"token_swapper"``
      - :class:`~.TokenSwapperSynthesisPermutation`
      - any
      - greedily optimizes SWAP-count for arbitrary connectivity
    * - ``"default"``
      - :class:`~.BasicSynthesisPermutation`
      - all-to-all
      - best for optimizing SWAP-count

.. autosummary::
   :toctree: ../stubs/

   BasicSynthesisPermutation
   ACGSynthesisPermutation
   KMSSynthesisPermutation
   TokenSwapperSynthesisPermutation


QFT Synthesis
'''''''''''''

.. list-table:: Plugins for :class:`.QFTGate` (key = ``"qft"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Targeted connectivity
    * - ``"full"``
      - :class:`~.QFTSynthesisFull`
      - all-to-all
    * - ``"line"``
      - :class:`~.QFTSynthesisLine`
      - linear
    * - ``"default"``
      - :class:`~.QFTSynthesisFull`
      - all-to-all

.. autosummary::
   :toctree: ../stubs/

   QFTSynthesisFull
   QFTSynthesisLine


MCX Synthesis
'''''''''''''

The following table lists synthesis plugins available for an :class:`.MCXGate` gate
with `k` control qubits. If the available number of clean/dirty auxiliary qubits is
not sufficient, the corresponding synthesis method will return `None`.

.. list-table:: Plugins for :class:`.MCXGate` (key = ``"mcx"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Number of clean ancillas
      - Number of dirty ancillas
      - Description
    * - ``"gray_code"``
      - :class:`~.MCXSynthesisGrayCode`
      - `0`
      - `0`
      - exponentially many CX gates; use only for small values of `k`
    * - ``"noaux_v24"``
      - :class:`~.MCXSynthesisNoAuxV24`
      - `0`
      - `0`
      - quadratic number of CX gates; use instead of ``"gray_code"`` for large values of `k`
    * - ``"n_clean_m15"``
      - :class:`~.MCXSynthesisNCleanM15`
      - `k-2`
      - `0`
      - at most `6*k-6` CX gates
    * - ``"n_dirty_i15"``
      - :class:`~.MCXSynthesisNDirtyI15`
      - `0`
      - `k-2`
      - at most `8*k-6` CX gates
    * - ``"1_clean_b95"``
      - :class:`~.MCXSynthesis1CleanB95`
      - `1`
      - `0`
      - at most `16*k-8` CX gates
    * - ``"default"``
      - :class:`~.MCXSynthesisDefault`
      - any
      - any
      - chooses the best algorithm based on the ancillas available

.. autosummary::
   :toctree: ../stubs/

   MCXSynthesisGrayCode
   MCXSynthesisNoAuxV24
   MCXSynthesisNCleanM15
   MCXSynthesisNDirtyI15
   MCXSynthesis1CleanB95
   MCXSynthesisDefault


MCMT Synthesis
''''''''''''''

.. list-table:: Plugins for :class:`.MCMTGate` (key = ``"mcmt"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Number of clean ancillas
      - Number of dirty ancillas
      - Description
    * - ``"vchain"``
      - :class:`.MCMTSynthesisVChain`
      - `k-1`
      - `0`
      - uses a linear number of Toffoli gates
    * - ``"noaux"``
      - :class:`~.MCMTSynthesisNoAux`
      - `0`
      - `0`
      - uses Qiskit's standard control mechanism
    * - ``"default"``
      - :class:`~.MCMTSynthesisDefault`
      - any
      - any
      - chooses the best algorithm based on the ancillas available

.. autosummary::
   :toctree: ../stubs/

   MCMTSynthesisVChain
   MCMTSynthesisNoAux
   MCMTSynthesisDefault


Pauli Evolution Synthesis
'''''''''''''''''''''''''

.. list-table:: Plugins for :class:`.PauliEvolutionGate` (key = ``"PauliEvolution"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Description
      - Targeted connectivity
    * - ``"rustiq"``
      - :class:`~.PauliEvolutionSynthesisRustiq`
      - use the synthesis method from `Rustiq circuit synthesis library 
        <https://github.com/smartiel/rustiq-core>`_
      - all-to-all
    * - ``"default"``
      - :class:`~.PauliEvolutionSynthesisDefault`
      - use a diagonalizing Clifford per Pauli term
      - all-to-all

.. autosummary::
   :toctree: ../stubs/

   PauliEvolutionSynthesisDefault
   PauliEvolutionSynthesisRustiq


Modular Adder Synthesis
'''''''''''''''''''''''

.. list-table:: Plugins for :class:`.ModularAdderGate` (key = ``"ModularAdder"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Number of clean ancillas
      - Description
    * - ``"ripple_cdkm"``
      - :class:`.ModularAdderSynthesisC04`
      - 1
      - a ripple-carry adder
    * - ``"ripple_vbe"``
      - :class:`.ModularAdderSynthesisV95`
      - :math:`n-1`, for :math:`n`-bit numbers
      - a ripple-carry adder
    * - ``"qft"``
      - :class:`.ModularAdderSynthesisD00`
      - 0
      - a QFT-based adder
    * - ``"default"``
      - :class:`~.ModularAdderSynthesisDefault`
      - any
      - chooses the best algorithm based on the ancillas available

.. autosummary::
   :toctree: ../stubs/

   ModularAdderSynthesisC04
   ModularAdderSynthesisD00
   ModularAdderSynthesisV95
   ModularAdderSynthesisDefault

Half Adder Synthesis
''''''''''''''''''''

.. list-table:: Plugins for :class:`.HalfAdderGate` (key = ``"HalfAdder"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Number of clean ancillas
      - Description
    * - ``"ripple_cdkm"``
      - :class:`.HalfAdderSynthesisC04`
      - 1
      - a ripple-carry adder
    * - ``"ripple_vbe"``
      - :class:`.HalfAdderSynthesisV95`
      - :math:`n-1`, for :math:`n`-bit numbers
      - a ripple-carry adder
    * - ``"qft"``
      - :class:`.HalfAdderSynthesisD00`
      - 0
      - a QFT-based adder
    * - ``"default"``
      - :class:`~.HalfAdderSynthesisDefault`
      - any
      - chooses the best algorithm based on the ancillas available

.. autosummary::
   :toctree: ../stubs/

   HalfAdderSynthesisC04
   HalfAdderSynthesisD00
   HalfAdderSynthesisV95
   HalfAdderSynthesisDefault

Full Adder Synthesis
''''''''''''''''''''

.. list-table:: Plugins for :class:`.FullAdderGate` (key = ``"FullAdder"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Number of clean ancillas
      - Description
    * - ``"ripple_cdkm"``
      - :class:`.FullAdderSynthesisC04`
      - 0
      - a ripple-carry adder
    * - ``"ripple_vbe"``
      - :class:`.FullAdderSynthesisV95`
      - :math:`n-1`, for :math:`n`-bit numbers
      - a ripple-carry adder
    * - ``"default"``
      - :class:`~.FullAdderSynthesisDefault`
      - any
      - chooses the best algorithm based on the ancillas available

.. autosummary::
   :toctree: ../stubs/

   FullAdderSynthesisC04
   FullAdderSynthesisV95
   FullAdderSynthesisDefault


Multiplier Synthesis
''''''''''''''''''''

.. list-table:: Plugins for :class:`.MultiplierGate` (key = ``"Multiplier"``)
    :header-rows: 1

    * - Plugin name
      - Plugin class
      - Number of clean ancillas
      - Description
    * - ``"cumulative"``
      - :class:`.MultiplierSynthesisH18`
      - depending on the :class:`.HalfAdderGate` used
      - a cumulative adder based on controlled adders
    * - ``"qft"``
      - :class:`.MultiplierSynthesisR17`
      - 0
      - a QFT-based multiplier

.. autosummary::
   :toctree: ../stubs/

   MultiplierSynthesisH18
   MultiplierSynthesisR17

é    )ÚannotationsN)ÚQuantumCircuit)ÚLinearFunctionÚQFTGateÚMCXGateÚC3XGateÚC4XGateÚPauliEvolutionGateÚPermutationGateÚMCMTGateÚModularAdderGateÚHalfAdderGateÚFullAdderGateÚMultiplierGate)ÚCouplingMap)Úsynth_clifford_fullÚsynth_clifford_layersÚsynth_clifford_depth_lnnÚsynth_clifford_greedyÚsynth_clifford_agÚsynth_clifford_bm)Úsynth_cnot_count_full_pmhÚsynth_cnot_depth_line_kmsÚcalc_inverse_matrix)Útranspose_cx_circ)Úsynth_permutation_basicÚsynth_permutation_acgÚsynth_permutation_depth_lnn_kms)Úsynth_qft_fullÚsynth_qft_line)Úsynth_mcx_n_dirty_i15Úsynth_mcx_n_clean_m15Úsynth_mcx_1_clean_b95Úsynth_mcx_gray_codeÚsynth_mcx_noaux_v24Úsynth_mcmt_vchain)ÚProductFormulaÚsynth_pauli_network_rustiq)Úadder_ripple_c04Úadder_qft_d00Úadder_ripple_v95Úmultiplier_qft_r17Úmultiplier_cumulative_h18)ÚClifford)ÚApproximateTokenSwapperé   )ÚHighLevelSynthesisPluginc                  ó   — e Zd ZdZdd„ZdS )ÚDefaultSynthesisClifforda¸  The default clifford synthesis plugin.

    For N <= 3 qubits this is the optimal CX cost decomposition by Bravyi, Maslov.
    For N > 3 qubits this is done using the general non-optimal greedy compilation
    routine from reference by Bravyi, Hu, Maslov, Shaydulin.

    This plugin name is :``clifford.default`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                óR   — t          |t          ¦  «        sdS t          |¦  «        }|S ©ú%Run synthesis for the given Clifford.N)Ú
isinstancer.   r   ©ÚselfÚhigh_level_objectÚcoupling_mapÚtargetÚqubitsÚoptionsÚdecompositions          úd/granary/edev/quantum/lib/python3.11/site-packages/qiskit/transpiler/passes/synthesis/hls_plugins.pyÚrunzDefaultSynthesisClifford.runç  s.   € åÐ+­XÑ6Ô6ð 	Ø�4å+Ð,=Ñ>Ô>ˆØÐó    ©NNN©Ú__name__Ú
__module__Ú__qualname__Ú__doc__rA   © rB   r@   r3   r3   Ü  s2   € € € € € ðð ðð ð ð ð ð rB   r3   c                  ó   — e Zd ZdZdd„ZdS )ÚAGSynthesisCliffordzêClifford synthesis plugin based on the Aaronson-Gottesman method.

    This plugin name is :``clifford.ag`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                óR   — t          |t          ¦  «        sdS t          |¦  «        }|S r5   )r7   r.   r   r8   s          r@   rA   zAGSynthesisClifford.run÷  s.   € åÐ+­XÑ6Ô6ð 	Ø�4å)Ð*;Ñ<Ô<ˆØÐrB   rC   rD   rI   rB   r@   rK   rK   ð  ó2   € € € € € ðð ðð ð ð ð ð rB   rK   c                  ó   — e Zd ZdZdd„ZdS )ÚBMSynthesisCliffordac  Clifford synthesis plugin based on the Bravyi-Maslov method.

    The method only works on Cliffords with at most 3 qubits, for which it
    constructs the optimal CX cost decomposition.

    This plugin name is :``clifford.bm`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ón   — t          |t          ¦  «        sdS |j        dk    rt          |¦  «        }nd}|S )r6   Né   )r7   r.   Ú
num_qubitsr   r8   s          r@   rA   zBMSynthesisClifford.run
  sC   € åÐ+­XÑ6Ô6ð 	Ø�4àÔ'¨1Ò,Ð,Ý-Ð.?Ñ@Ô@ˆMˆMà ˆMàÐrB   rC   rD   rI   rB   r@   rO   rO      s2   € € € € € ðð ð
ð 
ð 
ð 
ð 
ð 
rB   rO   c                  ó   — e Zd ZdZdd„ZdS )ÚGreedySynthesisClifforda  Clifford synthesis plugin based on the greedy synthesis
    Bravyi-Hu-Maslov-Shaydulin method.

    This plugin name is :``clifford.greedy`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                óR   — t          |t          ¦  «        sdS t          |¦  «        }|S r5   )r7   r.   r   r8   s          r@   rA   zGreedySynthesisClifford.run  ó.   € åÐ+­XÑ6Ô6ð 	Ø�4å-Ð.?Ñ@Ô@ˆØÐrB   rC   rD   rI   rB   r@   rT   rT     ó2   € € € € € ðð ðð ð ð ð ð rB   rT   c                  ó   — e Zd ZdZdd„ZdS )ÚLayerSynthesisClifforda  Clifford synthesis plugin based on the Bravyi-Maslov method
    to synthesize Cliffords into layers.

    This plugin name is :``clifford.layers`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                óR   — t          |t          ¦  «        sdS t          |¦  «        }|S r5   )r7   r.   r   r8   s          r@   rA   zLayerSynthesisClifford.run0  rV   rB   rC   rD   rI   rB   r@   rY   rY   (  rW   rB   rY   c                  ó   — e Zd ZdZdd„ZdS )ÚLayerLnnSynthesisCliffordaL  Clifford synthesis plugin based on the Bravyi-Maslov method
    to synthesize Cliffords into layers, with each layer synthesized
    adhering to LNN connectivity.

    This plugin name is :``clifford.lnn`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                óR   — t          |t          ¦  «        sdS t          |¦  «        }|S r5   )r7   r.   r   r8   s          r@   rA   zLayerLnnSynthesisClifford.runB  s.   € åÐ+­XÑ6Ô6ð 	Ø�4å0Ð1BÑCÔCˆØÐrB   rC   rD   rI   rB   r@   r\   r\   9  s2   € € € € € ðð ðð ð ð ð ð rB   r\   c                  ó   — e Zd ZdZdd„ZdS )ÚDefaultSynthesisLinearFunctionzâThe default linear function synthesis plugin.

    This plugin name is :``linear_function.default`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ó\   — t          |t          ¦  «        sdS t          |j        ¦  «        }|S )ú+Run synthesis for the given LinearFunction.N)r7   r   r   Úlinearr8   s          r@   rA   z"DefaultSynthesisLinearFunction.runR  s1   € åÐ+­^Ñ<Ô<ð 	Ø�4å1Ð2CÔ2JÑKÔKˆØÐrB   rC   rD   rI   rB   r@   r_   r_   K  rM   rB   r_   c                  ó   — e Zd ZdZdd„ZdS )ÚKMSSynthesisLinearFunctiona  Linear function synthesis plugin based on the Kutin-Moulton-Smithline method.

    This plugin name is :``linear_function.kms`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    The plugin supports the following plugin-specific options:

    * use_inverted: Indicates whether to run the algorithm on the inverse matrix
        and to invert the synthesized circuit.
        In certain cases this provides a better decomposition than the direct approach.
    * use_transposed: Indicates whether to run the algorithm on the transposed matrix
        and to invert the order of CX gates in the synthesized circuit.
        In certain cases this provides a better decomposition than the direct approach.

    Nc                óˆ  — t          |t          ¦  «        sdS |                     dd¦  «        }|                     dd¦  «        }|j                             t
          d¬¦  «        }|rt          j        |¦  «        }|rt          |¦  «        }t          |¦  «        }	|rt          |	¦  «        }	|r|	                     ¦   «         }	|	S )ra   NÚuse_invertedFÚuse_transposed©Úcopy)r7   r   Úgetrb   ÚastypeÚboolÚnpÚ	transposer   r   r   Úinverse)
r9   r:   r;   r<   r=   r>   rf   rg   Úmatr?   s
             r@   rA   zKMSSynthesisLinearFunction.runl  sÉ   € åÐ+­^Ñ<Ô<ð 	Ø�4à—{’{ >°5Ñ9Ô9ˆØ ŸšÐ%5°uÑ=Ô=ˆàÔ&×-Ò-­d¸Ð-Ñ?Ô?ˆàð 	$Ý”,˜sÑ#Ô#ˆCØð 	+Ý% cÑ*Ô*ˆCå1°#Ñ6Ô6ˆàð 	=Ý-¨mÑ<Ô<ˆMØð 	4Ø)×1Ò1Ñ3Ô3ˆMàÐrB   rC   rD   rI   rB   r@   rd   rd   [  s2   € € € € € ðð ð ð ð ð ð ð rB   rd   c                  ó   — e Zd ZdZdd„ZdS )ÚPMHSynthesisLinearFunctionu�  Linear function synthesis plugin based on the Patel-Markov-Hayes method.

    This plugin name is :``linear_function.pmh`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    The plugin supports the following plugin-specific options:

    * section size: The size of each section used in the Patelâ€“Markovâ€“Hayes algorithm [1].
    * use_inverted: Indicates whether to run the algorithm on the inverse matrix
        and to invert the synthesized circuit.
        In certain cases this provides a better decomposition than the direct approach.
    * use_transposed: Indicates whether to run the algorithm on the transposed matrix
        and to invert the order of CX gates in the synthesized circuit.
        In certain cases this provides a better decomposition than the direct approach.

    References:
        1. Patel, Ketan N., Igor L. Markov, and John P. Hayes,
           *Optimal synthesis of linear reversible circuits*,
           Quantum Information & Computation 8.3 (2008): 282-294.
           `arXiv:quant-ph/0302002 [quant-ph] <https://arxiv.org/abs/quant-ph/0302002>`_
    Nc                ó¸  — t          |t          ¦  «        sdS |                     dd¦  «        }|                     dd¦  «        }|                     dd¦  «        }|j                             t
          d¬¦  «        }	|rt          j        |	¦  «        }	|rt          |	¦  «        }	t          |	|¬¦  «        }
|rt          |
¦  «        }
|r|
                     ¦   «         }
|
S )	ra   NÚsection_sizeé   rf   Frg   rh   )rt   )r7   r   rj   rb   rk   rl   rm   rn   r   r   r   ro   )r9   r:   r;   r<   r=   r>   rt   rf   rg   rp   r?   s              r@   rA   zPMHSynthesisLinearFunction.runœ  sá   € åÐ+­^Ñ<Ô<ð 	Ø�4à—{’{ >°1Ñ5Ô5ˆØ—{’{ >°5Ñ9Ô9ˆØ ŸšÐ%5°uÑ=Ô=ˆàÔ&×-Ò-­d¸Ð-Ñ?Ô?ˆàð 	$Ý”,˜sÑ#Ô#ˆCØð 	+Ý% cÑ*Ô*ˆCå1°#ÀLÐQÑQÔQˆàð 	=Ý-¨mÑ<Ô<ˆMØð 	4Ø)×1Ò1Ñ3Ô3ˆMàÐrB   rC   rD   rI   rB   r@   rr   rr   …  s2   € € € € € ðð ð,ð ð ð ð ð rB   rr   c                  ó   — e Zd ZdZdd„ZdS )ÚKMSSynthesisPermutationzüThe permutation synthesis plugin based on the Kutin, Moulton, Smithline method.

    This plugin name is :``permutation.kms`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ó\   — t          |t          ¦  «        sdS t          |j        ¦  «        }|S ©ú(Run synthesis for the given Permutation.N)r7   r   r   Úpatternr8   s          r@   rA   zKMSSynthesisPermutation.run½  s1   € åÐ+­_Ñ=Ô=ð 	Ø�4å7Ð8IÔ8QÑRÔRˆØÐrB   rC   rD   rI   rB   r@   rw   rw   ¶  rM   rB   rw   c                  ó   — e Zd ZdZdd„ZdS )ÚBasicSynthesisPermutationzáThe permutation synthesis plugin based on sorting.

    This plugin name is :``permutation.basic`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ó\   — t          |t          ¦  «        sdS t          |j        ¦  «        }|S ry   )r7   r   r   r{   r8   s          r@   rA   zBasicSynthesisPermutation.runÍ  s1   € åÐ+­_Ñ=Ô=ð 	Ø�4å/Ð0AÔ0IÑJÔJˆØÐrB   rC   rD   rI   rB   r@   r}   r}   Æ  rM   rB   r}   c                  ó   — e Zd ZdZdd„ZdS )ÚACGSynthesisPermutationzöThe permutation synthesis plugin based on the Alon, Chung, Graham method.

    This plugin name is :``permutation.acg`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ó\   — t          |t          ¦  «        sdS t          |j        ¦  «        }|S ry   )r7   r   r   r{   r8   s          r@   rA   zACGSynthesisPermutation.runÝ  s1   € åÐ+­_Ñ=Ô=ð 	Ø�4å-Ð.?Ô.GÑHÔHˆØÐrB   rC   rD   rI   rB   r@   r€   r€   Ö  rM   rB   r€   c                  ó   — e Zd ZdZdd„ZdS )ÚQFTSynthesisFullu1  Synthesis plugin for QFT gates using all-to-all connectivity.

    This plugin name is :``qft.full`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    Note that the plugin mechanism is not applied if the gate is called ``qft`` but
    is not an instance of ``QFTGate``. This allows users to create custom gates with
    name ``qft``.

    The plugin supports the following additional options:

    * reverse_qubits (bool): Whether to synthesize the "QFT" operation (if ``False``,
        which is the default) or the "QFT-with-reversal" operation (if ``True``).
        Some implementation of the ``QFTGate`` include a layer of swap gates at the end
        of the synthesized circuit, which can in principle be dropped if the ``QFTGate``
        itself is the last gate in the circuit.
    * approximation_degree (int): The degree of approximation (0 for no approximation).
        It is possible to implement the QFT approximately by ignoring
        controlled-phase rotations with the angle beneath a threshold. This is discussed
        in more detail in [1] or [2].
    * insert_barriers (bool): If True, barriers are inserted as visualization improvement.
    * inverse (bool): If True, the inverse Fourier transform is constructed.
    * name (str): The name of the circuit.

    References:
        1. Adriano Barenco, Artur Ekert, Kalle-Antti Suominen, and PÃ¤ivi TÃ¶rmÃ¤,
           *Approximate Quantum Fourier Transform and Decoherence*,
           Physical Review A (1996).
           `arXiv:quant-ph/9601018 [quant-ph] <https://arxiv.org/abs/quant-ph/9601018>`_
        2. Donny Cheung,
           *Improved Bounds for the Approximate QFT* (2004),
           `arXiv:quant-ph/0403071 [quant-ph] <https://https://arxiv.org/abs/quant-ph/0403071>`_
    Nc                óF  — t          |t          ¦  «        sdS |                     dd¦  «        }|                     dd¦  «        }|                     dd¦  «        }|                     dd¦  «        }	|                     dd¦  «        }
t          |j        | |||	|
¬	¦  «        }|S )
ú$Run synthesis for the given QFTGate.NÚreverse_qubitsFÚapproximation_degreer   Úinsert_barriersro   Úname)rR   Údo_swapsr‡   rˆ   ro   r‰   )r7   r   rj   r   rR   )r9   r:   r;   r<   r=   r>   r†   r‡   rˆ   ro   r‰   r?   s               r@   rA   zQFTSynthesisFull.run	  s³   € õ
 Ð+­WÑ5Ô5ð 	Ø�4à ŸšÐ%5°uÑ=Ô=ˆØ&Ÿ{š{Ð+AÀ1ÑEÔEÐØ!Ÿ+š+Ð&7¸Ñ?Ô?ˆØ—+’+˜i¨Ñ/Ô/ˆØ�{Š{˜6 4Ñ(Ô(ˆå&Ø(Ô3Ø'Ð'Ø!5Ø+ØØð
ñ 
ô 
ˆð ÐrB   rC   rD   rI   rB   r@   rƒ   rƒ   æ  s3   € € € € € ð ð  ðDð ð ð ð ð rB   rƒ   c                  ó   — e Zd ZdZdd„ZdS )ÚQFTSynthesisLineuZ  Synthesis plugin for QFT gates using linear connectivity.

    This plugin name is :``qft.line`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    Note that the plugin mechanism is not applied if the gate is called ``qft`` but
    is not an instance of ``QFTGate``. This allows users to create custom gates with
    name ``qft``.

    The plugin supports the following additional options:

    * reverse_qubits (bool): Whether to synthesize the "QFT" operation (if ``False``,
        which is the default) or the "QFT-with-reversal" operation (if ``True``).
        Some implementation of the ``QFTGate`` include a layer of swap gates at the end
        of the synthesized circuit, which can in principle be dropped if the ``QFTGate``
        itself is the last gate in the circuit.
    * approximation_degree (int): the degree of approximation (0 for no approximation).
        It is possible to implement the QFT approximately by ignoring
        controlled-phase rotations with the angle beneath a threshold. This is discussed
        in more detail in [1] or [2].

    References:
        1. Adriano Barenco, Artur Ekert, Kalle-Antti Suominen, and PÃ¤ivi TÃ¶rmÃ¤,
           *Approximate Quantum Fourier Transform and Decoherence*,
           Physical Review A (1996).
           `arXiv:quant-ph/9601018 [quant-ph] <https://arxiv.org/abs/quant-ph/9601018>`_
        2. Donny Cheung,
           *Improved Bounds for the Approximate QFT* (2004),
           `arXiv:quant-ph/0403071 [quant-ph] <https://https://arxiv.org/abs/quant-ph/0403071>`_
    Nc                ó¼   — t          |t          ¦  «        sdS |                     dd¦  «        }|                     dd¦  «        }t          |j        | |¬¦  «        }|S )r…   Nr†   Fr‡   r   )rR   rŠ   r‡   )r7   r   rj   r    rR   )	r9   r:   r;   r<   r=   r>   r†   r‡   r?   s	            r@   rA   zQFTSynthesisLine.runB  sp   € õ
 Ð+­WÑ5Ô5ð 	Ø�4à ŸšÐ%5°uÑ=Ô=ˆØ&Ÿ{š{Ð+AÀ1ÑEÔEÐå&Ø(Ô3Ø'Ð'Ø!5ð
ñ 
ô 
ˆð
 ÐrB   rC   rD   rI   rB   r@   rŒ   rŒ   "  s2   € € € € € ðð ð>ð ð ð ð ð rB   rŒ   c                  ó   — e Zd ZdZdd„ZdS )Ú TokenSwapperSynthesisPermutationa‹  The permutation synthesis plugin based on the token swapper algorithm.

    This plugin name is :``permutation.token_swapper`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    In more detail, this plugin is used to synthesize objects of type `PermutationGate`.
    When synthesis succeeds, the plugin outputs a quantum circuit consisting only of swap
    gates. When synthesis does not succeed, the plugin outputs `None`.

    If either `coupling_map` or `qubits` is None, then the synthesized circuit
    is not required to adhere to connectivity constraints, as is the case
    when the synthesis is done before layout/routing.

    On the other hand, if both `coupling_map` and `qubits` are specified, the synthesized
    circuit is supposed to adhere to connectivity constraints. At the moment, the
    plugin only creates swap gates between qubits in `qubits`, i.e. it does not use
    any other qubits in the coupling map (if such synthesis is not possible, the
    plugin  outputs `None`).

    The plugin supports the following plugin-specific options:

    * trials: The number of trials for the token swapper to perform the mapping. The
      circuit with the smallest number of SWAPs is returned.
    * seed: The argument to the token swapper specifying the seed for random trials.
    * parallel_threshold: The argument to the token swapper specifying the number of nodes
      in the graph beyond which the algorithm will use parallel processing.

    For more details on the token swapper algorithm, see to the paper:
    `arXiv:1902.09102 <https://arxiv.org/abs/1902.09102>`__.
    Nc                óª  — t          |t          ¦  «        sdS |                     dd¦  «        }|                     dd¦  «        }|                     dd¦  «        }|j        }	d„ t	          |	¦  «        D ¦   «         }
|�|€"t          j        t          |	¦  «        ¦  «        }n|                     |d	¬
¦  «        }|j	         
                    ¦   «         }t          ||¬¦  «        }	 |                     |
||¬¦  «        }n# t          j        $ r d}Y nw xY w|�?t          t          |                     ¦   «         ¦  «        ¦  «        }|D ]} |j        |Ž  Œ|S dS )rz   NÚtrialsé   Úseedr   Úparallel_thresholdé2   c                ó   — i | ]\  }}||“Œ	S rI   rI   )Ú.0ÚiÚjs      r@   ú
<dictcomp>z8TokenSwapperSynthesisPermutation.run.<locals>.<dictcomp>€  s   € Ð?Ð?Ð?¡D A q˜1˜aÐ?Ð?Ð?rB   F)Úcheck_if_connected)r“   )r”   )r7   r   rj   r{   Ú	enumerater   Ú	from_fullÚlenÚreduceÚgraphÚto_undirectedr/   ÚmapÚrxÚInvalidMappingr   Únode_indicesÚswap)r9   r:   r;   r<   r=   r>   r‘   r“   r”   r{   Úpattern_as_dictÚused_coupling_mapr    ÚswapperÚswapper_resultr?   r¦   s                    r@   rA   z$TokenSwapperSynthesisPermutation.runu  s‰  € õ Ð+­_Ñ=Ô=ð 	Ø�4à—’˜X qÑ)Ô)ˆØ�{Š{˜6 1Ñ%Ô%ˆØ$Ÿ[š[Ð)=¸rÑBÔBÐà#Ô+ˆØ?Ð?­I°gÑ,>Ô,>Ð?Ñ?Ô?ˆð Ð 6 >õ !,Ô 5µc¸'±l´lÑ CÔ CÐÐð !-× 3Ò 3°FÈuÐ 3Ñ UÔ UÐà!Ô'×5Ò5Ñ7Ô7ˆÝ)¨%°dÐ;Ñ;Ô;ˆð	"Ø$Ÿ[š[Ø Ð<Nð )ñ ô ˆNˆNøõ Ô ð 	"ð 	"ð 	"Ø!ˆNˆNˆNð	"øøøð Ð%Ý*­3¨u×/AÒ/AÑ/CÔ/CÑ+DÔ+DÑEÔEˆMØ&ð *ð *�Ø"�Ô" DÐ)Ð)Ð)Ø Ð àˆts   Ã"C; Ã;DÄDrC   rD   rI   rB   r@   r�   r�   U  s2   € € € € € ðð ð>,ð ,ð ,ð ,ð ,ð ,rB   r�   c                  ó   — e Zd ZdZdd„ZdS )ÚMCXSynthesisNDirtyI15a  Synthesis plugin for a multi-controlled X gate based on the paper
    by Iten et al. (2016).

    See [1] for details.

    This plugin name is :``mcx.n_dirty_i15`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    For a multi-controlled X gate with :math:`k\ge 3` control qubits this synthesis
    method requires :math:`k - 2` additional dirty auxiliary qubits. The synthesized
    circuit consists of :math:`2 * k - 1` qubits and at most :math:`8 * k - 6` CX gates.

    The plugin supports the following plugin-specific options:

    * num_clean_ancillas: The number of clean auxiliary qubits available.
    * num_dirty_ancillas: The number of dirty auxiliary qubits available.
    * relative_phase: When set to ``True``, the method applies the optimized multi-controlled
      X gate up to a relative phase, in a way that, by lemma 8 of [1], the relative
      phases of the ``action part`` cancel out with the phases of the ``reset part``.
    * action_only: when set to ``True``, the method applies only the ``action part``
      of lemma 8 of [1].

    References:
        1. Iten et. al., *Quantum Circuits for Isometries*, Phys. Rev. A 93, 032318 (2016),
           `arXiv:1501.06911 <http://arxiv.org/abs/1501.06911>`_
    Nc                óV  — t          |t          t          t          f¦  «        sdS |j        }|                     dd¦  «        }|                     dd¦  «        }|                     dd¦  «        }	|                     dd¦  «        }
|dk    r||z   |d	z
  k     rdS t          ||	|
¦  «        }|S )
ú%Run synthesis for the given MCX gate.NÚnum_clean_ancillasr   Únum_dirty_ancillasÚrelative_phaseFÚactions_onlyrQ   ru   )r7   r   r   r	   Únum_ctrl_qubitsrj   r!   )r9   r:   r;   r<   r=   r>   r³   r¯   r°   r±   Úaction_onlyr?   s               r@   rA   zMCXSynthesisNDirtyI15.runÀ  s¼   € õ Ð+­gµwÅÐ-HÑIÔIð 	ð
 �4à+Ô;ˆØ$Ÿ[š[Ð)=¸qÑAÔAÐØ$Ÿ[š[Ð)=¸qÑAÔAÐØ ŸšÐ%5°uÑ=Ô=ˆØ—k’k .°%Ñ8Ô8ˆà˜aÒÐÐ$6Ð9KÑ$KÈoÐ`aÑNaÒ$aÐ$aà�4å-¨o¸~È{Ñ[Ô[ˆØÐrB   rC   rD   rI   rB   r@   r¬   r¬   ¤  s2   € € € € € ðð ð6ð ð ð ð ð rB   r¬   c                  ó   — e Zd ZdZdd„ZdS )ÚMCXSynthesisNCleanM15a3  Synthesis plugin for a multi-controlled X gate based on the paper by
    Maslov (2016).

    See [1] for details.

    This plugin name is :``mcx.n_clean_m15`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    For a multi-controlled X gate with :math:`k\ge 3` control qubits this synthesis
    method requires :math:`k - 2` additional clean auxiliary qubits. The synthesized
    circuit consists of :math:`2 * k - 1` qubits and at most :math:`6 * k - 6` CX gates.

    The plugin supports the following plugin-specific options:

    * num_clean_ancillas: The number of clean auxiliary qubits available.

    References:
        1. Maslov., Phys. Rev. A 93, 022311 (2016),
           `arXiv:1508.03273 <https://arxiv.org/pdf/1508.03273>`_
    Nc                óÈ   — t          |t          t          t          f¦  «        sdS |j        }|                     dd¦  «        }|dk    r||dz
  k     rdS t          |¦  «        }|S )r®   Nr¯   r   rQ   ru   )r7   r   r   r	   r³   rj   r"   ©	r9   r:   r;   r<   r=   r>   r³   r¯   r?   s	            r@   rA   zMCXSynthesisNCleanM15.runî  su   € õ Ð+­gµwÅÐ-HÑIÔIð 	ð
 �4à+Ô;ˆØ$Ÿ[š[Ð)=¸qÑAÔAÐà˜aÒÐÐ$6¸È1Ñ9LÒ$LÐ$Là�4å-¨oÑ>Ô>ˆØÐrB   rC   rD   rI   rB   r@   r¶   r¶   Ø  s2   € € € € € ðð ð*ð ð ð ð ð rB   r¶   c                  ó   — e Zd ZdZdd„ZdS )ÚMCXSynthesis1CleanB95aA  Synthesis plugin for a multi-controlled X gate based on the paper by
    Barenco et al. (1995).

    See [1] for details.

    This plugin name is :``mcx.1_clean_b95`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    For a multi-controlled X gate with :math:`k\ge 5` control qubits this synthesis
    method requires a single additional clean auxiliary qubit. The synthesized
    circuit consists of :math:`k + 2` qubits and at most :math:`16 * k - 8` CX gates.

    The plugin supports the following plugin-specific options:

    * num_clean_ancillas: The number of clean auxiliary qubits available.

    References:
        1. Barenco et. al., Phys.Rev. A52 3457 (1995),
           `arXiv:quant-ph/9503016 <https://arxiv.org/abs/quant-ph/9503016>`_
    Nc                óÒ   — t          |t          t          t          f¦  «        sdS |j        }|dk    rdS |                     dd¦  «        }|dk    r|dk    rdS t          |¦  «        }|S )r®   Nru   r¯   r   r’   )r7   r   r   r	   r³   rj   r#   r¸   s	            r@   rA   zMCXSynthesis1CleanB95.run  s€   € õ Ð+­gµwÅÐ-HÑIÔIð 	ð
 �4à+Ô;ˆà˜aÒÐà�4à$Ÿ[š[Ð)=¸qÑAÔAÐà˜aÒÐÐ$6¸!Ò$;Ð$;à�4å-¨oÑ>Ô>ˆØÐrB   rC   rD   rI   rB   r@   rº   rº     s2   € € € € € ðð ð*ð ð ð ð ð rB   rº   c                  ó   — e Zd ZdZdd„ZdS )ÚMCXSynthesisGrayCodea6  Synthesis plugin for a multi-controlled X gate based on the Gray code.

    This plugin name is :``mcx.gray_code`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    For a multi-controlled X gate with :math:`k` control qubits this synthesis
    method requires no additional clean auxiliary qubits. The synthesized
    circuit consists of :math:`k + 1` qubits.

    It is not recommended to use this method for large values of :math:`k + 1`
    as it produces exponentially many gates.
    Nc                óz   — t          |t          t          t          f¦  «        sdS |j        }t          |¦  «        }|S ©r®   N)r7   r   r   r	   r³   r$   ©r9   r:   r;   r<   r=   r>   r³   r?   s           r@   rA   zMCXSynthesisGrayCode.runA  ó@   € õ Ð+­gµwÅÐ-HÑIÔIð 	ð
 �4à+Ô;ˆÝ+¨OÑ<Ô<ˆØÐrB   rC   rD   rI   rB   r@   r½   r½   3  s2   € € € € € ðð ðð ð ð ð ð rB   r½   c                  ó   — e Zd ZdZdd„ZdS )ÚMCXSynthesisNoAuxV24a	  Synthesis plugin for a multi-controlled X gate based on the
    implementation for MCPhaseGate, which is in turn based on the
    paper by Vale et al. (2024).

    See [1] for details.

    This plugin name is :``mcx.noaux_v24`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    For a multi-controlled X gate with :math:`k` control qubits this synthesis
    method requires no additional clean auxiliary qubits. The synthesized
    circuit consists of :math:`k + 1` qubits.

    References:
        1. Vale et. al., *Circuit Decomposition of Multicontrolled Special Unitary
           Single-Qubit Gates*, IEEE TCAD 43(3) (2024),
           `arXiv:2302.06377 <https://arxiv.org/abs/2302.06377>`_
    Nc                óz   — t          |t          t          t          f¦  «        sdS |j        }t          |¦  «        }|S r¿   )r7   r   r   r	   r³   r%   rÀ   s           r@   rA   zMCXSynthesisNoAuxV24.rund  rÁ   rB   rC   rD   rI   rB   r@   rÃ   rÃ   P  s2   € € € € € ðð ð&ð ð ð ð ð rB   rÃ   c                  ó   — e Zd ZdZdd„ZdS )ÚMCXSynthesisDefaultzäThe default synthesis plugin for a multi-controlled X gate.

    This plugin name is :``mcx.default`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                óP  — t          |t          t          t          f¦  «        sdS  t	          ¦   «         j        ||||fi |¤Žx}	 �|S  t          ¦   «         j        ||||fi |¤Žx}	 �|S  t          ¦   «         j        ||||fi |¤Žx}	 �|S  t          ¦   «         j        ||||fi |¤ŽS r¿   )	r7   r   r   r	   r¶   rA   r¬   rº   rÃ   r8   s          r@   rA   zMCXSynthesisDefault.runz  s7  € õ Ð+­gµwÅÐ-HÑIÔIð 	ð
 �4ð
 9Õ2Ñ4Ô4Ô8Ø! <°¸ðð ØCJðð ð ˆMð ð	ð
 !Ð ð 9Õ2Ñ4Ô4Ô8Ø! <°¸ðð ØCJðð ð ˆMð ð	ð
 !Ð ð 9Õ2Ñ4Ô4Ô8Ø! <°¸ðð ØCJðð ð ˆMð ð	ð
 !Ð à)Õ#Ñ%Ô%Ô)Ø˜|¨V°Vð
ð 
Ø?Fð
ð 
ð 	
rB   rC   rD   rI   rB   r@   rÆ   rÆ   s  s2   € € € € € ðð ð#
ð #
ð #
ð #
ð #
ð #
rB   rÆ   c                  ó   — e Zd ZdZdd„ZdS )ÚMCMTSynthesisDefaultz'A default decomposition for MCMT gates.Nc                ó®   — t          |t          ¦  «        sd S  t          ¦   «         j        ||||fi |¤Žx}	 �|S  t	          ¦   «         j        ||||fi |¤ŽS ©N)r7   r   ÚMCMTSynthesisVChainrA   ÚMCMTSynthesisNoAuxr8   s          r@   rA   zMCMTSynthesisDefault.run£  s�   € åÐ+­XÑ6Ô6ð 	Ø�4ð 7Õ0Ñ2Ô2Ô6Ø! <°¸ðð ØCJðð ð ˆMð ð	ð
 !Ð à'Õ!Ñ#Ô#Ô'Ð(9¸<ÈÐQWÐcÐcÐ[bÐcÐcÐcrB   rC   rD   rI   rB   r@   rÉ   rÉ      s4   € € € € € Ø1Ð1ðdð dð dð dð dð drB   rÉ   c                  ó   — e Zd ZdZdd„ZdS )rÍ   ú+A V-chain based synthesis for ``MCMTGate``.Nc                ó  — t          |t          ¦  «        sd S |j        }|                     dd ¦  «        }|j        dk    rJt          |j        ¦  «        }|                     |                     |j	        |¬¦  «        |j
        ¦  «         nft          |j        |j        ¬¦  «        }	t          |j        ¦  «        D ]}
|	                     ||
gg ¦  «         Œ|	                     |j	        |¬¦  «        }|                     ¦   «         S )NÚ
ctrl_stater0   )rÑ   )r‰   )r7   r   Ú	base_gaterj   Únum_target_qubitsr   rR   ÚappendÚcontrolr³   r=   ÚlabelÚrangeÚ	decompose)r9   r:   r;   r<   r=   r>   rÒ   rÑ   ÚcircuitÚbaser˜   s              r@   rA   zMCMTSynthesisNoAux.runµ  s  € ÝÐ+­XÑ6Ô6ð 	Ø�4à%Ô/ˆ	Ø—[’[ ¨tÑ4Ô4ˆ
àÔ.°!Ò3Ð3å$Ð%6Ô%AÑBÔBˆGØ�NŠNØ×!Ò!Ð"3Ô"CÐPZÐ!Ñ[Ô[Ø”ñô ð ð õ "Ð"3Ô"EÐL]ÔLcÐdÑdÔdˆDÝÐ,Ô>Ñ?Ô?ð 0ð 0�Ø—’˜I¨ s¨BÑ/Ô/Ð/Ð/à—l’lÐ#4Ô#DÐQ[�lÑ\Ô\ˆGà× Ò Ñ"Ô"Ð"rB   rC   rD   rI   rB   r@   rÍ   rÍ   ²  s.   € € € € € Ø5Ð5ð#ð #ð #ð #ð #ð #rB   rÍ   c                  ó   — e Zd ZdZdd„ZdS )rÌ   rÏ   Nc                óæ   — t          |t          ¦  «        sd S |                     dd¦  «        |j        dz
  k     rd S |                     dd ¦  «        }t	          |j        |j        |j        |¦  «        S )Nr¯   r   r0   rÑ   )r7   r   rj   r³   r&   rÒ   rÓ   )r9   r:   r;   r<   r=   r>   rÑ   s          r@   rA   zMCMTSynthesisVChain.runÑ  s}   € ÝÐ+­XÑ6Ô6ð 	Ø�4à�;Š;Ð+¨QÑ/Ô/Ð2CÔ2SÐVWÑ2WÒWÐWØ�4à—[’[ ¨tÑ4Ô4ˆ
å ØÔ'ØÔ-ØÔ/Øñ	
ô 
ð 	
rB   rC   rD   rI   rB   r@   rÌ   rÌ   Î  s.   € € € € € Ø5Ð5ð
ð 
ð 
ð 
ð 
ð 
rB   rÌ   c                  ó   — e Zd ZdZdd„ZdS )ÚModularAdderSynthesisDefaulta   The default modular adder (no carry in, no carry out qubit) synthesis.

    This plugin name is:``ModularAdder.default`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    If at least one clean auxiliary qubit is available, the :class:`ModularAdderSynthesisC04`
    is used, otherwise :class:`ModularAdderSynthesisD00`.

    The plugin supports the following plugin-specific options:

    * ``num_clean_ancillas``: The number of clean auxiliary qubits available.

    Nc                ó  — t          |t          ¦  «        sd S |j        dk    r! t          ¦   «         j        ||||fi |¤Ž}|�|S  t          ¦   «         j        ||||fi |¤Žx}	 �|S  t          ¦   «         j        ||||fi |¤ŽS )Nr’   )r7   r   Únum_state_qubitsÚModularAdderSynthesisD00rA   ÚModularAdderSynthesisC04r8   s          r@   rA   z ModularAdderSynthesisDefault.runñ  sê   € ÝÐ+Õ-=Ñ>Ô>ð 	Ø�4ð Ô-°Ò2Ð2Ø:Õ4Ñ6Ô6Ô:Ø! <°¸ðð ØCJðð ˆMð Ð(Ø$Ð$ð <Õ5Ñ7Ô7Ô;Ø! <°¸ðð ØCJðð ð ˆMð ð	ð
 !Ð ð .Õ'Ñ)Ô)Ô-Ø˜|¨V°Vð
ð 
Ø?Fð
ð 
ð 	
rB   rC   rD   rI   rB   r@   rÞ   rÞ   â  s2   € € € € € ðð ð
ð 
ð 
ð 
ð 
ð 
rB   rÞ   c                  ó   — e Zd ZdZdd„ZdS )râ   a«  A ripple-carry adder, modulo :math:`2^n`.

    This plugin name is:``ModularAdder.ripple_c04`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    This plugin requires at least one clean auxiliary qubit.

    The plugin supports the following plugin-specific options:

    * ``num_clean_ancillas``: The number of clean auxiliary qubits available.

    Nc                ó”   — t          |t          ¦  «        sd S |                     dd¦  «        dk     rd S t          |j        d¬¦  «        S )Nr¯   r   r0   Úfixed©Úkind)r7   r   rj   r)   rà   ©r9   r:   r;   r<   r=   r>   s         r@   rA   zModularAdderSynthesisC04.run  sS   € ÝÐ+Õ-=Ñ>Ô>ð 	Ø�4ð �;Š;Ð+¨QÑ/Ô/°!Ò3Ð3Ø�4åÐ 1Ô BÈÐQÑQÔQÐQrB   rC   rD   rI   rB   r@   râ   râ     s8   € € € € € ðð ðRð Rð Rð Rð Rð RrB   râ   c                  ó   — e Zd ZdZdd„ZdS )ÚModularAdderSynthesisV95aï  A ripple-carry adder, modulo :math:`2^n`.

    This plugin name is:``ModularAdder.ripple_v95`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    For an adder on 2 registers with :math:`n` qubits each, this plugin requires at
    least :math:`n-1` clean auxiliary qubit.

    The plugin supports the following plugin-specific options:

    * ``num_clean_ancillas``: The number of clean auxiliary qubits available.

    Nc                óž   — t          |t          ¦  «        sd S |j        }|dz
  |                     dd¦  «        k    rd S t	          |d¬¦  «        S )Nr0   r¯   r   rå   ræ   )r7   r   rà   rj   r+   ©r9   r:   r;   r<   r=   r>   rà   s          r@   rA   zModularAdderSynthesisV95.run3  s^   € ÝÐ+Õ-=Ñ>Ô>ð 	Ø�4à,Ô=Ðð ˜aÑ '§+¢+Ð.BÀAÑ"FÔ"FÒFÐFØ�4åÐ 0°wÐ?Ñ?Ô?Ð?rB   rC   rD   rI   rB   r@   rê   rê   $  s8   € € € € € ðð ð
@ð 
@ð 
@ð 
@ð 
@ð 
@rB   rê   c                  ó   — e Zd ZdZdd„ZdS )rá   z×A QFT-based adder, modulo :math:`2^n`.

    This plugin name is:``ModularAdder.qft_d00`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ó\   — t          |t          ¦  «        sd S t          |j        d¬¦  «        S )Nrå   ræ   )r7   r   r*   rà   rè   s         r@   rA   zModularAdderSynthesisD00.runG  s2   € ÝÐ+Õ-=Ñ>Ô>ð 	Ø�4åÐ.Ô?ÀgÐNÑNÔNÐNrB   rC   rD   rI   rB   r@   rá   rá   @  s8   € € € € € ðð ðOð Oð Oð Oð Oð OrB   rá   c                  ó   — e Zd ZdZdd„ZdS )ÚHalfAdderSynthesisDefaultao  The default half-adder (no carry in, but a carry out qubit) synthesis.

    If we have an auxiliary qubit available, the Cuccaro ripple-carry adder uses
    :math:`O(n)` CX gates and 1 auxiliary qubit, whereas the Vedral ripple-carry uses more CX
    and :math:`n-1` auxiliary qubits. The QFT-based adder uses no auxiliary qubits, but
    :math:`O(n^2)`, hence it is only used if no auxiliary qubits are available.

    This plugin name is:``HalfAdder.default`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    If at least one clean auxiliary qubit is available, the :class:`HalfAdderSynthesisC04`
    is used, otherwise :class:`HalfAdderSynthesisD00`.

    The plugin supports the following plugin-specific options:

    * ``num_clean_ancillas``: The number of clean auxiliary qubits available.

    Nc                ó  — t          |t          ¦  «        sd S |j        dk    r! t          ¦   «         j        ||||fi |¤Ž}|�|S  t          ¦   «         j        ||||fi |¤Žx}	 �|S  t          ¦   «         j        ||||fi |¤ŽS )NrQ   )r7   r   rà   ÚHalfAdderSynthesisV95rA   ÚHalfAdderSynthesisC04ÚHalfAdderSynthesisD00r8   s          r@   rA   zHalfAdderSynthesisDefault.runb  sé   € ÝÐ+­]Ñ;Ô;ð 	Ø�4ð Ô-°Ò2Ð2Ø7Õ1Ñ3Ô3Ô7Ø! <°¸ðð ØCJðð ˆMð Ð(Ø$Ð$ð 9Õ2Ñ4Ô4Ô8Ø! <°¸ðð ØCJðð ð ˆMð ð	ð
 !Ð ð +Õ$Ñ&Ô&Ô*Ø˜|¨V°Vð
ð 
Ø?Fð
ð 
ð 	
rB   rC   rD   rI   rB   r@   rð   rð   N  s2   € € € € € ðð ð&
ð 
ð 
ð 
ð 
ð 
rB   rð   c                  ó   — e Zd ZdZdd„ZdS )ró   a©  A ripple-carry adder with a carry-out bit.

    This plugin name is:``HalfAdder.ripple_c04`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    This plugin requires at least one clean auxiliary qubit.

    The plugin supports the following plugin-specific options:

    * ``num_clean_ancillas``: The number of clean auxiliary qubits available.

    Nc                ó”   — t          |t          ¦  «        sd S |                     dd¦  «        dk     rd S t          |j        d¬¦  «        S )Nr¯   r   r0   Úhalfræ   )r7   r   rj   r)   rà   rè   s         r@   rA   zHalfAdderSynthesisC04.runŠ  sR   € ÝÐ+­]Ñ;Ô;ð 	Ø�4ð �;Š;Ð+¨QÑ/Ô/°!Ò3Ð3Ø�4åÐ 1Ô BÈÐPÑPÔPÐPrB   rC   rD   rI   rB   r@   ró   ró   |  s8   € € € € € ðð ðQð Qð Qð Qð Qð QrB   ró   c                  ó   — e Zd ZdZdd„ZdS )rò   aì  A ripple-carry adder with a carry-out bit.

    This plugin name is:``HalfAdder.ripple_v95`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    For an adder on 2 registers with :math:`n` qubits each, this plugin requires at
    least :math:`n-1` clean auxiliary qubit.

    The plugin supports the following plugin-specific options:

    * ``num_clean_ancillas``: The number of clean auxiliary qubits available.
    Nc                óž   — t          |t          ¦  «        sd S |j        }|dz
  |                     dd¦  «        k    rd S t	          |d¬¦  «        S )Nr0   r¯   r   r÷   ræ   )r7   r   rà   rj   r+   rì   s          r@   rA   zHalfAdderSynthesisV95.run£  ó]   € ÝÐ+­]Ñ;Ô;ð 	Ø�4à,Ô=Ðð ˜aÑ '§+¢+Ð.BÀAÑ"FÔ"FÒFÐFØ�4åÐ 0°vÐ>Ñ>Ô>Ð>rB   rC   rD   rI   rB   r@   rò   rò   •  ó2   € € € € € ðð ð
?ð 
?ð 
?ð 
?ð 
?ð 
?rB   rò   c                  ó   — e Zd ZdZdd„ZdS )rô   zäA QFT-based adder with a carry-in and a carry-out bit.

    This plugin name is:``HalfAdder.qft_d00`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ó\   — t          |t          ¦  «        sd S t          |j        d¬¦  «        S )Nr÷   ræ   )r7   r   r*   rà   rè   s         r@   rA   zHalfAdderSynthesisD00.run·  s1   € ÝÐ+­]Ñ;Ô;ð 	Ø�4åÐ.Ô?ÀfÐMÑMÔMÐMrB   rC   rD   rI   rB   r@   rô   rô   °  s8   € € € € € ðð ðNð Nð Nð Nð Nð NrB   rô   c                  ó   — e Zd ZdZdd„ZdS )ÚFullAdderSynthesisDefaultzçA ripple-carry adder with a carry-in and a carry-out bit.

    This plugin name is:``FullAdder.default`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                óÂ   — t          |t          ¦  «        sd S |j        dk    r! t          ¦   «         j        ||||fi |¤Ž}|�|S  t          ¦   «         j        ||||fi |¤ŽS )Nr0   )r7   r   rà   ÚFullAdderSynthesisV95rA   ÚFullAdderSynthesisC04r8   s          r@   rA   zFullAdderSynthesisDefault.runÅ  s�   € ÝÐ+­]Ñ;Ô;ð 	Ø�4ð Ô-°Ò2Ð2Ø7Õ1Ñ3Ô3Ô7Ø! <°¸ðð ØCJðð ˆMð Ð(Ø$Ð$à*Õ$Ñ&Ô&Ô*Ø˜|¨V°Vð
ð 
Ø?Fð
ð 
ð 	
rB   rC   rD   rI   rB   r@   rÿ   rÿ   ¾  s2   € € € € € ðð ð
ð 
ð 
ð 
ð 
ð 
rB   rÿ   c                  ó   — e Zd ZdZdd„ZdS )r  a  A ripple-carry adder with a carry-in and a carry-out bit.

    This plugin name is:``FullAdder.ripple_c04`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    This plugin requires no auxiliary qubits.
    Nc                ó\   — t          |t          ¦  «        sd S t          |j        d¬¦  «        S )NÚfullræ   )r7   r   r)   rà   rè   s         r@   rA   zFullAdderSynthesisC04.runà  s1   € ÝÐ+­]Ñ;Ô;ð 	Ø�4åÐ 1Ô BÈÐPÑPÔPÐPrB   rC   rD   rI   rB   r@   r  r  ×  s8   € € € € € ðð ðQð Qð Qð Qð Qð QrB   r  c                  ó   — e Zd ZdZdd„ZdS )r  aü  A ripple-carry adder with a carry-in and a carry-out bit.

    This plugin name is:``FullAdder.ripple_v95`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    For an adder on 2 registers with :math:`n` qubits each, this plugin requires at
    least :math:`n-1` clean auxiliary qubits.

    The plugin supports the following plugin-specific options:

    * ``num_clean_ancillas``: The number of clean auxiliary qubits available.
    Nc                óž   — t          |t          ¦  «        sd S |j        }|dz
  |                     dd¦  «        k    rd S t	          |d¬¦  «        S )Nr0   r¯   r   r  ræ   )r7   r   rà   rj   r+   rì   s          r@   rA   zFullAdderSynthesisV95.runõ  rú   rB   rC   rD   rI   rB   r@   r  r  ç  rû   rB   r  c                  ó   — e Zd ZdZdd„ZdS )ÚMultiplierSynthesisH18zéA cumulative multiplier based on controlled adders.

    This plugin name is:``Multiplier.cumulative_h18`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ód   — t          |t          ¦  «        sd S t          |j        |j        ¦  «        S rË   )r7   r   r-   rà   Únum_result_qubitsrè   s         r@   rA   zMultiplierSynthesisH18.run	  s8   € ÝÐ+­^Ñ<Ô<ð 	Ø�4å(ØÔ.Ð0AÔ0Sñ
ô 
ð 	
rB   rC   rD   rI   rB   r@   r	  r	    ó2   € € € € € ðð ð
ð 
ð 
ð 
ð 
ð 
rB   r	  c                  ó   — e Zd ZdZdd„ZdS )ÚMultiplierSynthesisR17zÆA QFT-based multiplier.

    This plugin name is:``Multiplier.qft_r17`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.
    Nc                ód   — t          |t          ¦  «        sd S t          |j        |j        ¦  «        S rË   )r7   r   r,   rà   r  rè   s         r@   rA   zMultiplierSynthesisR17.run  s8   € ÝÐ+­^Ñ<Ô<ð 	Ø�4å!ØÔ.Ð0AÔ0Sñ
ô 
ð 	
rB   rC   rD   rI   rB   r@   r  r    r  rB   r  c                  ó   — e Zd ZdZdd„ZdS )ÚPauliEvolutionSynthesisDefaultaÅ  Synthesize a :class:`.PauliEvolutionGate` using the default synthesis algorithm.

    This plugin name is:``PauliEvolution.default`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    The following plugin option can be set:

    * preserve_order: If ``False``, allow re-ordering the Pauli terms in the Hamiltonian to
        reduce the circuit depth of the decomposition.

    Nc                ó´   — t          |t          ¦  «        sd S |j        }d|v r"t          |t          ¦  «        r|d         |_        |                     |¦  «        S )NÚpreserve_order)r7   r
   Ú	synthesisr'   r  Ú
synthesize)r9   r:   r;   r<   r=   r>   Úalgos          r@   rA   z"PauliEvolutionSynthesisDefault.run/  s`   € ÝÐ+Õ-?Ñ@Ô@ð 	ð �4à Ô*ˆà˜wÐ&Ð&­:°d½NÑ+KÔ+KÐ&Ø")Ð*:Ô";ˆDÔà�ŠÐ0Ñ1Ô1Ð1rB   rC   rD   rI   rB   r@   r  r  "  s2   € € € € € ð
ð 
ð2ð 2ð 2ð 2ð 2ð 2rB   r  c                  ó   — e Zd ZdZdd„ZdS )ÚPauliEvolutionSynthesisRustiquÜ  Synthesize a :class:`.PauliEvolutionGate` using Rustiq.

    This plugin name is :``PauliEvolution.rustiq`` which can be used as the key on
    an :class:`~.HLSConfig` object to use this method with :class:`~.HighLevelSynthesis`.

    The Rustiq synthesis algorithm is described in [1], and is implemented in
    Rust-based quantum circuit synthesis library available at
    https://github.com/smartiel/rustiq-core.

    On large circuits the plugin may take a significant runtime.

    The plugin supports the following additional options:

    * optimize_count (bool): if `True` the synthesis algorithm will try to optimize
        the 2-qubit gate count; and if `False` then the 2-qubit depth.
    * preserve_order (bool): whether the order of paulis should be preserved, up to
        commutativity.
    * upto_clifford (bool): if `True`, the final Clifford operator is not synthesized.
    * upto_phase (bool): if `True`, the global phase of the returned circuit may
        differ from the global phase of the given pauli network.
    * resynth_clifford_method (int): describes the strategy to synthesize the final
        Clifford operator. Allowed values are `0` (naive approach), `1` (qiskit
        greedy synthesis), `2` (rustiq isometry synthesis).

    References:
        1. TimothÃ©e Goubault de BrugiÃ¨re and Simon Martiel,
           *Faster and shorter synthesis of Hamiltonian simulation circuits*,
           `arXiv:2404.03280 [quant-ph] <https://arxiv.org/abs/2404.03280>`_

    Nc           	     ó  — t          |t          ¦  «        sd S |j        }t          |t          ¦  «        st	          j        ddt          ¬¦  «         d S d|v r|d         |_        |j        }| 	                    |¦  «        }| 
                    dd¦  «        }	| 
                    dd¦  «        }
| 
                    dd¦  «        }| 
                    d	d¦  «        }| 
                    d
d¦  «        }t          |||	|
|||¬¦  «        S )NzNCannot apply Rustiq if the evolution synthesis does not implement ``expand``. ru   )Ú
stacklevelÚcategoryr  Úoptimize_countTÚupto_cliffordFÚ
upto_phaseÚresynth_clifford_methodr0   )rR   Úpauli_networkr  r  r  r  r  )r7   r
   r  r'   ÚwarningsÚwarnÚRuntimeWarningr  rR   Úexpandrj   r(   )r9   r:   r;   r<   r=   r>   r  rR   r   r  r  r  r  r  s                 r@   rA   z!PauliEvolutionSynthesisRustiq.run]  s"  € ÝÐ+Õ-?Ñ@Ô@ð 	ð �4à Ô*ˆå˜$¥Ñ/Ô/ð 	ÝŒMØ`ØÝ'ðñ ô ð ð
 �4à˜wÐ&Ð&Ø")Ð*:Ô";ˆDÔà&Ô1ˆ
ØŸšÐ$5Ñ6Ô6ˆà ŸšÐ%5°tÑ<Ô<ˆØ ŸšÐ%5°tÑ<Ô<ˆØŸš O°UÑ;Ô;ˆØ—[’[ ¨uÑ5Ô5ˆ
Ø")§+¢+Ð.GÈÑ"KÔ"KÐå)Ø!Ø'Ø)Ø)Ø'Ø!Ø$;ð
ñ 
ô 
ð 	
rB   rC   rD   rI   rB   r@   r  r  =  s2   € € € € € ðð ð>$
ð $
ð $
ð $
ð $
ð $
rB   r  )jrH   Ú
__future__r   r!  Únumpyrm   Ú	rustworkxr£   Úqiskit.circuit.quantumcircuitr   Úqiskit.circuit.libraryr   r   r   r   r	   r
   r   r   r   r   r   r   Úqiskit.transpiler.couplingr   Úqiskit.synthesis.cliffordr   r   r   r   r   r   Úqiskit.synthesis.linearr   r   r   Ú-qiskit.synthesis.linear.linear_circuits_utilsr   Úqiskit.synthesis.permutationr   r   r   Úqiskit.synthesis.qftr   r    Ú!qiskit.synthesis.multi_controlledr!   r"   r#   r$   r%   r&   Úqiskit.synthesis.evolutionr'   r(   Úqiskit.synthesis.arithmeticr)   r*   r+   r,   r-   Úqiskit.quantum_info.operatorsr.   Ú+qiskit.transpiler.passes.routing.algorithmsr/   Úpluginr1   r3   rK   rO   rT   rY   r\   r_   rd   rr   rw   r}   r€   rƒ   rŒ   r�   r¬   r¶   rº   r½   rÃ   rÆ   rÉ   rÍ   rÌ   rÞ   râ   rê   rá   rð   ró   rò   rô   rÿ   r  r  r	  r  r  r  rI   rB   r@   ú<module>r6     sÀ	  ððIð IðV #Ð "Ð "Ð "Ð "Ð "à €€€Ø Ð Ð Ð Ø Ð Ð Ð à 8Ð 8Ð 8Ð 8Ð 8Ð 8ðð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð 3Ð 2Ð 2Ð 2Ð 2Ð 2ðð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ðð ð ð ð ð ð ð ð ð ð
 LÐ KÐ KÐ KÐ KÐ Kðð ð ð ð ð ð ð ð ð ð
ð ð ð ð ð ð ð ðð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð RÐ QÐ QÐ QÐ QÐ QÐ QÐ Qðð ð ð ð ð ð ð ð ð ð ð ð ð ð 3Ð 2Ð 2Ð 2Ð 2Ð 2Ø OÐ OÐ OÐ OÐ OÐ OØ ,Ð ,Ð ,Ð ,Ð ,Ð ,ðð ð ð ð Ð7ñ ô ð ð(ð ð ð ð Ð2ñ ô ð ð ð ð ð ð Ð2ñ ô ð ð.ð ð ð ð Ð6ñ ô ð ð"ð ð ð ð Ð5ñ ô ð ð"ð ð ð ð Ð 8ñ ô ð ð$ð ð ð ð Ð%=ñ ô ð ð 'ð 'ð 'ð 'ð 'Ð!9ñ 'ô 'ð 'ðT.ð .ð .ð .ð .Ð!9ñ .ô .ð .ðbð ð ð ð Ð6ñ ô ð ð ð ð ð ð Ð 8ñ ô ð ð ð ð ð ð Ð6ñ ô ð ð 9ð 9ð 9ð 9ð 9Ð/ñ 9ô 9ð 9ðx0ð 0ð 0ð 0ð 0Ð/ñ 0ô 0ð 0ðfLð Lð Lð Lð LÐ'?ñ Lô Lð Lð^1ð 1ð 1ð 1ð 1Ð4ñ 1ô 1ð 1ðh(ð (ð (ð (ð (Ð4ñ (ô (ð (ðV-ð -ð -ð -ð -Ð4ñ -ô -ð -ð`ð ð ð ð Ð3ñ ô ð ð: ð  ð  ð  ð  Ð3ñ  ô  ð  ðF*
ð *
ð *
ð *
ð *
Ð2ñ *
ô *
ð *
ðZdð dð dð dð dÐ3ñ dô dð dð$#ð #ð #ð #ð #Ð1ñ #ô #ð #ð8
ð 
ð 
ð 
ð 
Ð2ñ 
ô 
ð 
ð(&
ð &
ð &
ð &
ð &
Ð#;ñ &
ô &
ð &
ðRRð Rð Rð Rð RÐ7ñ Rô Rð Rð2@ð @ð @ð @ð @Ð7ñ @ô @ð @ð8Oð Oð Oð Oð OÐ7ñ Oô Oð Oð+
ð +
ð +
ð +
ð +
Ð 8ñ +
ô +
ð +
ð\Qð Qð Qð Qð QÐ4ñ Qô Qð Qð2?ð ?ð ?ð ?ð ?Ð4ñ ?ô ?ð ?ð6Nð Nð Nð Nð NÐ4ñ Nô Nð Nð
ð 
ð 
ð 
ð 
Ð 8ñ 
ô 
ð 
ð2Qð Qð Qð Qð QÐ4ñ Qô Qð Qð ?ð ?ð ?ð ?ð ?Ð4ñ ?ô ?ð ?ð6
ð 
ð 
ð 
ð 
Ð5ñ 
ô 
ð 
ð 
ð 
ð 
ð 
ð 
Ð5ñ 
ô 
ð 
ð 2ð 2ð 2ð 2ð 2Ð%=ñ 2ô 2ð 2ð6D
ð D
ð D
ð D
ð D
Ð$<ñ D
ô D
ð D
ð D
ð D
rB   