{ "cells": [ { "cell_type": "code", "execution_count": 1, "id": "183b8234-2d76-4626-8c36-c899cfe6fdf3", "metadata": {}, "outputs": [], "source": [ "import os \n", "import sys\n", "sys.path.insert(0, os.path.abspath('../..'))\n", "\n", "import sympy as sp\n", "import numpy as np\n", "import itertools as it\n", "import pysymmpol as sy\n", "import pysymmpol.utils as ut\n", "from IPython.display import display, Latex" ] }, { "cell_type": "markdown", "id": "8d195105-2a22-484f-8b75-065633c6deeb", "metadata": {}, "source": [ "# Class: State" ] }, { "cell_type": "markdown", "id": "b289cbd1-e2f9-4ccd-9aa5-b90a2fb4062f", "metadata": {}, "source": [ "In two dimensions, there is a isomorphism between the bosonic and fermionic Fock spaces known as the Fermion-Boson correspondence. The bosonic states are represented \n", "in terms of conjugacy classes $\\lambda = (1^{k_1} 2^{k_2}\\cdots)$, and the fermionic states $\\lambda = (\\lambda_1, \\lambda_2, \\dots, \\lambda_N)$ are represented in terms of partition states that we have discussed above. These states are not equivalent, but since the Fock space is decomposed in terms of the number of boxes, that we call **level**, therefore, we have an expansion of the form " ] }, { "cell_type": "markdown", "id": "40c8f503-3797-4a74-8ef6-f3ea78777c92", "metadata": {}, "source": [ "$|1^{k_1} 2^{k_2}\\cdots\\rangle = \\sum_{\\lambda} C_{\\lambda} |\\lambda_1, \\lambda_2, \\dots, \\lambda_N\\rangle\\qquad \\left(n = \\sum_i\\lambda_i = \\sum_j j k_j\\right)$" ] }, { "cell_type": "markdown", "id": "b69d5b2a-a4a7-4610-be59-9be5c9c76ffe", "metadata": {}, "source": [ "and the sum is over all partitions with $n$ boxes, and the coefficients above are written in terms of Schur polynomials. \n", "\n", "Therefore, this module consider a given level $n$, number of boxes, and build all possible bosonic and fermionic states. From the mathematical viewpoint, we determine the partitions \n", "of the integers $n$ and write these partitions in both forms $\\lambda = (1^{k_1} 2^{k_2}\\cdots) = (\\lambda_1, \\lambda_2, \\dots, \\lambda_N)$. \n", "\n", "*As before, we represent conjugacy classes as dictionaries and partitions as tuples.*" ] }, { "cell_type": "markdown", "id": "6ab2f0a1-7301-4e9c-897a-f80004dac7a0", "metadata": {}, "source": [ "Before we start, it is important to undertand that the empty state at level zero (no boxes) is the quantum vacuum, and is represented by the absence of bosonic or fermionic operators. It is represented as an empty tuple. " ] }, { "cell_type": "markdown", "id": "ba1f0d48-2c65-4d4b-8287-ca9be5bc74c9", "metadata": { "jp-MarkdownHeadingCollapsed": true }, "source": [ "## Conjugacy States" ] }, { "cell_type": "code", "execution_count": 2, "id": "d786921d-a44f-4157-ad16-fcb60f816d24", "metadata": {}, "outputs": [], "source": [ "# Given the level n, we can build the class states:\n", "state = sy.State(3)" ] }, { "cell_type": "code", "execution_count": 8, "id": "f9409725-e29b-442a-b50c-35000911a788", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "({1: 3, 2: 0, 3: 0}, {1: 1, 2: 1, 3: 0}, {1: 0, 2: 0, 3: 1})" ] }, "execution_count": 8, "metadata": {}, "output_type": "execute_result" } ], "source": [ "state.conjugacy_states() # and with this method, we see the possible states in this level. 3 states. This number is equal the partition of the n, in our case, n=3" ] }, { "cell_type": "code", "execution_count": 4, "id": "3efdaa61-b015-4347-a93c-5d2524b57bb2", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "((3, 0, 0), (1, 1, 0), (0, 0, 1))" ] }, "execution_count": 4, "metadata": {}, "output_type": "execute_result" } ], "source": [ "state._conjugacy_states() # There is also a nonpublic method that returns these states as tuples." ] }, { "cell_type": "markdown", "id": "cd8d4f3a-e7f4-45c6-a858-534deac137d2", "metadata": {}, "source": [ "Now one can see that we can build the corresponding Young diagrams using the previous module." ] }, { "cell_type": "code", "execution_count": 5, "id": "d32815a4-51a8-489f-b6a0-4ae18f8b6d86", "metadata": {}, "outputs": [], "source": [ "state_level3 = sy.State(3)" ] }, { "cell_type": "code", "execution_count": 9, "id": "1d08245e-e64b-404f-9fa6-339d5309daa7", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "3" ] }, "execution_count": 9, "metadata": {}, "output_type": "execute_result" } ], "source": [ "len(state_level3._conjugacy_states()) # There are 3 states, of course." ] }, { "cell_type": "code", "execution_count": 11, "id": "9733a4a8-7a47-48c8-9859-ffe2ec15cfc0", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "--------------------------------------------------------------------------------\n", "Bosonic state 1: |{1: 3, 2: 0, 3: 0}>\n", "■ \n", "■ \n", "■ \n", "--------------------------------------------------------------------------------\n", "--------------------------------------------------------------------------------\n", "Bosonic state 2: |{1: 1, 2: 1, 3: 0}>\n", "■ \n", "■ ■ \n", "--------------------------------------------------------------------------------\n", "--------------------------------------------------------------------------------\n", "Bosonic state 3: |{1: 0, 2: 0, 3: 1}>\n", "■ ■ ■ \n", "--------------------------------------------------------------------------------\n" ] } ], "source": [ "# We can use the ConjugacyClass to write the diagrams\n", "for a in state_level3.conjugacy_states():\n", " print(40*\"--\")\n", " print(f\"Bosonic state {state_level3.conjugacy_states().index(a)+1}: |{a}>\")\n", " sy.ConjugacyClass(a).draw_diagram()\n", " print(40*\"--\")" ] }, { "cell_type": "markdown", "id": "1da38d2d-bab4-4df0-81f0-7c64cf6a2576", "metadata": {}, "source": [ "## Partition State" ] }, { "cell_type": "markdown", "id": "56be4d53-905a-4bd3-b52a-210a3b2b4ee8", "metadata": {}, "source": [ "Using the same examples, we can build the ''fermionic'' states. " ] }, { "cell_type": "code", "execution_count": 12, "id": "862665d8-99cb-43bb-a23c-d332c1cf2867", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "3" ] }, "execution_count": 12, "metadata": {}, "output_type": "execute_result" } ], "source": [ "len(state_level3.partition_states()) " ] }, { "cell_type": "code", "execution_count": 14, "id": "f5676fce-473e-4b95-af11-ece491123721", "metadata": { "scrolled": true }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "--------------------------------------------------------------------------------\n", "Fermionic representation 1: |(1, 1, 1)>\n", "■ \n", "■ \n", "■ \n", "--------------------------------------------------------------------------------\n", "--------------------------------------------------------------------------------\n", "Fermionic representation 2: |(2, 1, 0)>\n", "■ \n", "■ ■ \n", "--------------------------------------------------------------------------------\n", "--------------------------------------------------------------------------------\n", "Fermionic representation 3: |(3, 0, 0)>\n", "■ ■ ■ \n", "--------------------------------------------------------------------------------\n" ] } ], "source": [ "for a in state_level3.partition_states():\n", " print(40*\"--\")\n", " print(f\"Fermionic representation {state_level3.partition_states().index(a)+1}: |{a}>\")\n", " sy.YoungDiagram(a).draw_diagram()\n", " print(40*\"--\")" ] }, { "cell_type": "code", "execution_count": null, "id": "e3d9bc29-8053-4f4a-bf68-26c6c3499f62", "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.12.2" } }, "nbformat": 4, "nbformat_minor": 5 }