<jupyter_start><jupyter_text>Let's create some quantum systems.You can use ``Qubits`` class to create a qubit, and it won't require a ``dimension`` information and also use $\sigma_{z}$ as the default ``operator``.Alternatively, you can use ``QuantumSystem`` class, but, in this case, you need to give at least one of the relevant information (``operator``, ``dimension``, or ``frequency``) while creating it.<jupyter_code>Qubit1 = QuantumSystem(operator=qt.sigmaz)
Qubit2 = Qubit(frequency=0.5)
Cavity1 = Cavity(dimension=3)
Spin1 = Spin(jValue=1) # you can either give a dimension or, equivalently, the spin quantum number. The spin object can handle either.<jupyter_output><class 'quanguru.classes.QSys.qSystem'><jupyter_text>You can set any attribute while creating the objects as above, or you can set or change them later as below.<jupyter_code>Qubit1.frequency = 1
Qubit1.dimension = 2
Qubit2.frequency = 2<jupyter_output><empty_output><jupyter_text>now let's print the Hamiltonian of these qubits.Notice that their Hamiltonians are equal, even though the Qubit1 has ``frequency=1`` and Qubit2 has ``frequency=2``.The reason is that the ``Qubit`` class also assumes the usual 1/2 in Qubit Hamiltonian:$H = \frac{\omega}{2}\sigma_{z}$.while the generic ``QuantumSystem`` with ``operator`` $\hat{O}$ and ``frequency`` $\omega$ has the Hamiltonian:$H = \omega\hat{O}$.<jupyter_code>Qubit1.totalHam.A, Qubit2.totalHam.A<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.12121212121212122, 'fraction_numerical': 0.01584022038567493, 'mean_word_length': 6.338383838383838, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '3', 'dir': 'jupyter-structured-clean-dedup', 'id': '448638', 'license': 'BSD-3-Clause', 'n_tokens_mistral': 477, 'n_tokens_neox': 451, 'n_words': 157, 'path': 'docs/source/classes/Tutorials/QSystems/createQuantumSystems.ipynb', 'repo_name': 'AngsarM/QuanGuru', 'size': '1452'}