# qiskit.aqua.components.initial_states.Zero¶

class Zero(num_qubits)[소스]

The zero (null/vacuum) state.

This is suitable for those situations in which the all-zeros state is the desired state. This is the case for a vacuum state in physics or chemistry

매개변수

num_qubits (int) – Number of qubits, has a minimum value of 1.

__init__(num_qubits)[소스]
매개변수

num_qubits (int) – Number of qubits, has a minimum value of 1.

Methods

 __init__(num_qubits) type num_qubits int construct_circuit([mode, register]) Construct the statevector of desired initial state.

Attributes

property bitstr
construct_circuit(mode='circuit', register=None)[소스]

Construct the statevector of desired initial state.

매개변수
• modevector or circuit. The vector mode produces the vector. While the circuit constructs the quantum circuit corresponding that vector.

• register – qubits for circuit construction.

반환값

statevector.

반환 형식

QuantumCircuit or numpy.ndarray

예외

AquaError – when mode is not ‘vector’ or ‘circuit’.