diff --git a/.doctrees/api/ffsim.doctree b/.doctrees/api/ffsim.doctree index d991f0070..2250c5b71 100644 Binary files a/.doctrees/api/ffsim.doctree and b/.doctrees/api/ffsim.doctree differ diff --git a/.doctrees/api/ffsim.hamiltonians.doctree b/.doctrees/api/ffsim.hamiltonians.doctree index 559ef2d3b..7ddcfc8dd 100644 Binary files a/.doctrees/api/ffsim.hamiltonians.doctree and b/.doctrees/api/ffsim.hamiltonians.doctree differ diff --git a/.doctrees/environment.pickle b/.doctrees/environment.pickle index d78245c7e..1073e3391 100644 Binary files a/.doctrees/environment.pickle and b/.doctrees/environment.pickle differ diff --git a/.doctrees/nbsphinx/tutorials/01-introduction.ipynb b/.doctrees/nbsphinx/tutorials/01-introduction.ipynb index 7c97f92d2..eb6296423 100644 --- a/.doctrees/nbsphinx/tutorials/01-introduction.ipynb +++ b/.doctrees/nbsphinx/tutorials/01-introduction.ipynb @@ -16,10 +16,10 @@ "execution_count": 1, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:54.675927Z", - "iopub.status.busy": "2023-10-25T20:21:54.675704Z", - "iopub.status.idle": "2023-10-25T20:21:54.970497Z", - "shell.execute_reply": "2023-10-25T20:21:54.969938Z" + "iopub.execute_input": "2023-10-25T20:35:03.177848Z", + "iopub.status.busy": "2023-10-25T20:35:03.177651Z", + "iopub.status.idle": "2023-10-25T20:35:03.459674Z", + "shell.execute_reply": "2023-10-25T20:35:03.459100Z" } }, "outputs": [], @@ -62,10 +62,10 @@ "execution_count": 2, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:54.973864Z", - "iopub.status.busy": "2023-10-25T20:21:54.973471Z", - "iopub.status.idle": "2023-10-25T20:21:54.978330Z", - "shell.execute_reply": "2023-10-25T20:21:54.977824Z" + "iopub.execute_input": "2023-10-25T20:35:03.463614Z", + "iopub.status.busy": "2023-10-25T20:35:03.462457Z", + "iopub.status.idle": "2023-10-25T20:35:03.467607Z", + "shell.execute_reply": "2023-10-25T20:35:03.467142Z" } }, "outputs": [], @@ -93,10 +93,10 @@ "execution_count": 3, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:54.980716Z", - "iopub.status.busy": "2023-10-25T20:21:54.980477Z", - "iopub.status.idle": "2023-10-25T20:21:54.984122Z", - "shell.execute_reply": "2023-10-25T20:21:54.983581Z" + "iopub.execute_input": "2023-10-25T20:35:03.471408Z", + "iopub.status.busy": "2023-10-25T20:35:03.470463Z", + "iopub.status.idle": "2023-10-25T20:35:03.474338Z", + "shell.execute_reply": "2023-10-25T20:35:03.473884Z" } }, "outputs": [], diff --git a/.doctrees/nbsphinx/tutorials/02-orbital-rotation.ipynb b/.doctrees/nbsphinx/tutorials/02-orbital-rotation.ipynb index 6473e7148..fa69ae294 100644 --- a/.doctrees/nbsphinx/tutorials/02-orbital-rotation.ipynb +++ b/.doctrees/nbsphinx/tutorials/02-orbital-rotation.ipynb @@ -43,10 +43,10 @@ "execution_count": 1, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:56.483934Z", - "iopub.status.busy": "2023-10-25T20:21:56.483369Z", - "iopub.status.idle": "2023-10-25T20:21:56.779886Z", - "shell.execute_reply": "2023-10-25T20:21:56.779271Z" + "iopub.execute_input": "2023-10-25T20:35:04.971468Z", + "iopub.status.busy": "2023-10-25T20:35:04.971111Z", + "iopub.status.idle": "2023-10-25T20:35:05.249674Z", + "shell.execute_reply": "2023-10-25T20:35:05.249132Z" } }, "outputs": [], @@ -111,10 +111,10 @@ "execution_count": 2, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:56.783618Z", - "iopub.status.busy": "2023-10-25T20:21:56.783130Z", - "iopub.status.idle": "2023-10-25T20:21:56.809491Z", - "shell.execute_reply": "2023-10-25T20:21:56.808959Z" + "iopub.execute_input": "2023-10-25T20:35:05.253297Z", + "iopub.status.busy": "2023-10-25T20:35:05.252823Z", + "iopub.status.idle": "2023-10-25T20:35:05.277147Z", + "shell.execute_reply": "2023-10-25T20:35:05.276659Z" } }, "outputs": [], @@ -158,10 +158,10 @@ "execution_count": 3, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:56.813179Z", - "iopub.status.busy": "2023-10-25T20:21:56.812782Z", - "iopub.status.idle": "2023-10-25T20:21:56.823844Z", - "shell.execute_reply": "2023-10-25T20:21:56.823334Z" + "iopub.execute_input": "2023-10-25T20:35:05.280112Z", + "iopub.status.busy": "2023-10-25T20:35:05.279739Z", + "iopub.status.idle": "2023-10-25T20:35:05.294878Z", + "shell.execute_reply": "2023-10-25T20:35:05.294367Z" } }, "outputs": [], @@ -201,10 +201,10 @@ "execution_count": 4, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:56.827505Z", - "iopub.status.busy": "2023-10-25T20:21:56.827212Z", - "iopub.status.idle": "2023-10-25T20:21:56.832798Z", - "shell.execute_reply": "2023-10-25T20:21:56.832278Z" + "iopub.execute_input": "2023-10-25T20:35:05.297632Z", + "iopub.status.busy": "2023-10-25T20:35:05.297293Z", + "iopub.status.idle": "2023-10-25T20:35:05.303392Z", + "shell.execute_reply": "2023-10-25T20:35:05.302944Z" } }, "outputs": [], diff --git a/.doctrees/nbsphinx/tutorials/03-double-factorized.ipynb b/.doctrees/nbsphinx/tutorials/03-double-factorized.ipynb index f1ae49482..9420e0f89 100644 --- a/.doctrees/nbsphinx/tutorials/03-double-factorized.ipynb +++ b/.doctrees/nbsphinx/tutorials/03-double-factorized.ipynb @@ -43,10 +43,10 @@ "execution_count": 1, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:58.554855Z", - "iopub.status.busy": "2023-10-25T20:21:58.554654Z", - "iopub.status.idle": "2023-10-25T20:21:58.952682Z", - "shell.execute_reply": "2023-10-25T20:21:58.952002Z" + "iopub.execute_input": "2023-10-25T20:35:06.830652Z", + "iopub.status.busy": "2023-10-25T20:35:06.830244Z", + "iopub.status.idle": "2023-10-25T20:35:07.218102Z", + "shell.execute_reply": "2023-10-25T20:35:07.217498Z" } }, "outputs": [ @@ -92,10 +92,10 @@ "execution_count": 2, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:58.956199Z", - "iopub.status.busy": "2023-10-25T20:21:58.955678Z", - "iopub.status.idle": "2023-10-25T20:21:58.962350Z", - "shell.execute_reply": "2023-10-25T20:21:58.961820Z" + "iopub.execute_input": "2023-10-25T20:35:07.222122Z", + "iopub.status.busy": "2023-10-25T20:35:07.221083Z", + "iopub.status.idle": "2023-10-25T20:35:07.228822Z", + "shell.execute_reply": "2023-10-25T20:35:07.228363Z" } }, "outputs": [ @@ -110,44 +110,44 @@ " [-5.57029092e-17 -6.77238770e-01]]\n", "\n", "Two-body tensor:\n", - "[[[[5.23173938e-01 3.58782168e-17]\n", - " [3.58782168e-17 5.33545754e-01]]\n", + "[[[[0.52317394 0. ]\n", + " [0. 0.53354575]]\n", "\n", - " [[2.49859013e-17 2.48240570e-01]\n", - " [2.48240570e-01 4.83067333e-17]]]\n", + " [[0. 0.24824057]\n", + " [0.24824057 0. ]]]\n", "\n", "\n", - " [[[2.49859013e-17 2.48240570e-01]\n", - " [2.48240570e-01 4.83067333e-17]]\n", + " [[[0. 0.24824057]\n", + " [0.24824057 0. ]]\n", "\n", - " [[5.33545754e-01 4.01841799e-17]\n", - " [4.01841799e-17 5.53132024e-01]]]]\n", + " [[0.53354575 0. ]\n", + " [0. 0.55313202]]]]\n", "\n", "Double-factorized representation\n", "--------------------------------\n", "One-body tensor:\n", - "[[-1.21318608e+00 -1.27383424e-16]\n", - " [-8.82879498e-17 -1.07792507e+00]]\n", + "[[-1.21318608e+00 -8.52909490e-17]\n", + " [-5.57029092e-17 -1.07792507e+00]]\n", "\n", "Diagonal Coulomb matrices:\n", - "[[[ 5.14653029e-01 5.33545754e-01]\n", - " [ 5.33545754e-01 5.53132024e-01]]\n", + "[[[ 0.51465303 0.53354575]\n", + " [ 0.53354575 0.55313202]]\n", "\n", - " [[ 2.48240570e-01 -2.48240570e-01]\n", - " [-2.48240570e-01 2.48240570e-01]]\n", + " [[ 0.24824057 -0.24824057]\n", + " [-0.24824057 0.24824057]]\n", "\n", - " [[ 2.27521846e-62 -1.39236953e-32]\n", - " [-1.39236953e-32 8.52090881e-03]]]\n", + " [[ 0. 0. ]\n", + " [ 0. 0.00852091]]]\n", "\n", "Orbital rotations:\n", - "[[[ 1.00000000e+00 0.00000000e+00]\n", - " [ 0.00000000e+00 1.00000000e+00]]\n", + "[[[ 1. 0. ]\n", + " [ 0. 1. ]]\n", "\n", - " [[-7.07106781e-01 -7.07106781e-01]\n", - " [ 7.07106781e-01 -7.07106781e-01]]\n", + " [[-0.70710678 0.70710678]\n", + " [ 0.70710678 0.70710678]]\n", "\n", - " [[-1.27830444e-15 -1.00000000e+00]\n", - " [-1.00000000e+00 1.27830444e-15]]]\n" + " [[ 0. 1. ]\n", + " [ 1. 0. ]]]\n" ] } ], @@ -226,10 +226,10 @@ "execution_count": 3, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:58.964994Z", - "iopub.status.busy": "2023-10-25T20:21:58.964800Z", - "iopub.status.idle": "2023-10-25T20:21:58.969237Z", - "shell.execute_reply": "2023-10-25T20:21:58.968662Z" + "iopub.execute_input": "2023-10-25T20:35:07.231721Z", + "iopub.status.busy": "2023-10-25T20:35:07.231326Z", + "iopub.status.idle": "2023-10-25T20:35:07.235822Z", + "shell.execute_reply": "2023-10-25T20:35:07.235383Z" } }, "outputs": [], @@ -284,10 +284,10 @@ "execution_count": 4, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:58.971561Z", - "iopub.status.busy": "2023-10-25T20:21:58.971370Z", - "iopub.status.idle": "2023-10-25T20:21:58.975805Z", - "shell.execute_reply": "2023-10-25T20:21:58.975300Z" + "iopub.execute_input": "2023-10-25T20:35:07.238237Z", + "iopub.status.busy": "2023-10-25T20:35:07.237944Z", + "iopub.status.idle": "2023-10-25T20:35:07.241544Z", + "shell.execute_reply": "2023-10-25T20:35:07.241102Z" } }, "outputs": [], @@ -324,10 +324,10 @@ "execution_count": 5, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:58.978437Z", - "iopub.status.busy": "2023-10-25T20:21:58.978080Z", - "iopub.status.idle": "2023-10-25T20:21:58.982595Z", - "shell.execute_reply": "2023-10-25T20:21:58.982136Z" + "iopub.execute_input": "2023-10-25T20:35:07.244003Z", + "iopub.status.busy": "2023-10-25T20:35:07.243667Z", + "iopub.status.idle": "2023-10-25T20:35:07.248163Z", + "shell.execute_reply": "2023-10-25T20:35:07.247733Z" } }, "outputs": [ @@ -366,10 +366,10 @@ "execution_count": 6, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:58.985006Z", - "iopub.status.busy": "2023-10-25T20:21:58.984666Z", - "iopub.status.idle": "2023-10-25T20:21:58.993265Z", - "shell.execute_reply": "2023-10-25T20:21:58.992815Z" + "iopub.execute_input": "2023-10-25T20:35:07.250637Z", + "iopub.status.busy": "2023-10-25T20:35:07.250292Z", + "iopub.status.idle": "2023-10-25T20:35:07.259162Z", + "shell.execute_reply": "2023-10-25T20:35:07.258584Z" } }, "outputs": [ @@ -408,10 +408,10 @@ "execution_count": 7, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:58.995587Z", - "iopub.status.busy": "2023-10-25T20:21:58.995290Z", - "iopub.status.idle": "2023-10-25T20:21:59.002511Z", - "shell.execute_reply": "2023-10-25T20:21:59.002043Z" + "iopub.execute_input": "2023-10-25T20:35:07.261363Z", + "iopub.status.busy": "2023-10-25T20:35:07.261182Z", + "iopub.status.idle": "2023-10-25T20:35:07.268841Z", + "shell.execute_reply": "2023-10-25T20:35:07.268302Z" } }, "outputs": [ @@ -449,10 +449,10 @@ "execution_count": 8, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:59.004680Z", - "iopub.status.busy": "2023-10-25T20:21:59.004486Z", - "iopub.status.idle": "2023-10-25T20:21:59.041121Z", - "shell.execute_reply": "2023-10-25T20:21:59.040653Z" + "iopub.execute_input": "2023-10-25T20:35:07.272245Z", + "iopub.status.busy": "2023-10-25T20:35:07.271971Z", + "iopub.status.idle": "2023-10-25T20:35:07.310868Z", + "shell.execute_reply": "2023-10-25T20:35:07.310326Z" } }, "outputs": [ @@ -460,7 +460,7 @@ "name": "stdout", "output_type": "stream", "text": [ - "Fidelity of Trotter-evolved state with exact state: 0.9999906233109686\n" + "Fidelity of Trotter-evolved state with exact state: 0.9999906233109683\n" ] } ], @@ -492,10 +492,10 @@ "execution_count": 9, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:59.043638Z", - "iopub.status.busy": "2023-10-25T20:21:59.043332Z", - "iopub.status.idle": "2023-10-25T20:21:59.070826Z", - "shell.execute_reply": "2023-10-25T20:21:59.070341Z" + "iopub.execute_input": "2023-10-25T20:35:07.313500Z", + "iopub.status.busy": "2023-10-25T20:35:07.313201Z", + "iopub.status.idle": "2023-10-25T20:35:07.345334Z", + "shell.execute_reply": "2023-10-25T20:35:07.344444Z" } }, "outputs": [ @@ -503,7 +503,7 @@ "name": "stdout", "output_type": "stream", "text": [ - "Fidelity of Trotter-evolved state with exact state: 0.9999906233109686\n" + "Fidelity of Trotter-evolved state with exact state: 0.9999906233109683\n" ] } ], @@ -534,10 +534,10 @@ "execution_count": 10, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:21:59.073522Z", - "iopub.status.busy": "2023-10-25T20:21:59.073215Z", - "iopub.status.idle": "2023-10-25T20:21:59.085212Z", - "shell.execute_reply": "2023-10-25T20:21:59.084766Z" + "iopub.execute_input": "2023-10-25T20:35:07.347751Z", + "iopub.status.busy": "2023-10-25T20:35:07.347571Z", + "iopub.status.idle": "2023-10-25T20:35:07.361969Z", + "shell.execute_reply": "2023-10-25T20:35:07.361089Z" } }, "outputs": [ @@ -545,7 +545,7 @@ "name": "stdout", "output_type": "stream", "text": [ - "Fidelity of Trotter-evolved state with exact state: 0.9999999336740067\n" + "Fidelity of Trotter-evolved state with exact state: 0.9999999336740071\n" ] } ], diff --git a/.doctrees/nbsphinx/tutorials/04-lucj.ipynb b/.doctrees/nbsphinx/tutorials/04-lucj.ipynb index 360bdfa44..2e5da9900 100644 --- a/.doctrees/nbsphinx/tutorials/04-lucj.ipynb +++ b/.doctrees/nbsphinx/tutorials/04-lucj.ipynb @@ -14,10 +14,10 @@ "execution_count": 1, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:22:00.882746Z", - "iopub.status.busy": "2023-10-25T20:22:00.882257Z", - "iopub.status.idle": "2023-10-25T20:22:01.407281Z", - "shell.execute_reply": "2023-10-25T20:22:01.406757Z" + "iopub.execute_input": "2023-10-25T20:35:09.127230Z", + "iopub.status.busy": "2023-10-25T20:35:09.126861Z", + "iopub.status.idle": "2023-10-25T20:35:09.731464Z", + "shell.execute_reply": "2023-10-25T20:35:09.730938Z" } }, "outputs": [ @@ -25,7 +25,7 @@ "name": "stdout", "output_type": "stream", "text": [ - "converged SCF energy = -77.4456267643962\n" + "converged SCF energy = -77.4456267643961\n" ] }, { @@ -110,10 +110,10 @@ "execution_count": 2, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:22:01.412282Z", - "iopub.status.busy": "2023-10-25T20:22:01.411120Z", - "iopub.status.idle": "2023-10-25T20:22:01.788588Z", - "shell.execute_reply": "2023-10-25T20:22:01.787987Z" + "iopub.execute_input": "2023-10-25T20:35:09.735037Z", + "iopub.status.busy": "2023-10-25T20:35:09.734503Z", + "iopub.status.idle": "2023-10-25T20:35:10.150599Z", + "shell.execute_reply": "2023-10-25T20:35:10.150030Z" } }, "outputs": [ @@ -121,14 +121,14 @@ "name": "stdout", "output_type": "stream", "text": [ - "E(CCSD) = -77.49387212754471 E_corr = -0.04824536314851481\n" + "E(CCSD) = -77.49387212754462 E_corr = -0.04824536314851294\n" ] }, { "name": "stdout", "output_type": "stream", "text": [ - "Energy at initialialization: -77.46975600021685\n" + "Energy at initialialization: -77.46975600021707\n" ] } ], @@ -176,10 +176,10 @@ "execution_count": 3, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:22:01.791394Z", - "iopub.status.busy": "2023-10-25T20:22:01.791131Z", - "iopub.status.idle": "2023-10-25T20:22:56.084656Z", - "shell.execute_reply": "2023-10-25T20:22:56.084141Z" + "iopub.execute_input": "2023-10-25T20:35:10.153461Z", + "iopub.status.busy": "2023-10-25T20:35:10.153250Z", + "iopub.status.idle": "2023-10-25T20:35:55.828394Z", + "shell.execute_reply": "2023-10-25T20:35:55.827838Z" } }, "outputs": [ @@ -191,12 +191,12 @@ " message: CONVERGENCE: REL_REDUCTION_OF_F_<=_FACTR*EPSMCH\n", " success: True\n", " status: 0\n", - " fun: -77.62901809766743\n", - " x: [-2.484e-01 7.969e-01 ... -5.994e-01 2.612e-02]\n", - " nit: 237\n", - " jac: [ 4.547e-05 6.253e-05 ... 9.095e-05 1.563e-04]\n", - " nfev: 18980\n", - " njev: 260\n", + " fun: -77.62901478093653\n", + " x: [-2.548e-01 6.030e-01 ... 8.487e-01 3.133e-01]\n", + " nit: 201\n", + " jac: [-3.411e-05 5.684e-05 ... -3.695e-05 3.553e-05]\n", + " nfev: 16206\n", + " njev: 222\n", " hess_inv: <72x72 LbfgsInvHessProduct with dtype=float64>\n" ] } @@ -251,10 +251,10 @@ "execution_count": 4, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:22:56.087244Z", - "iopub.status.busy": "2023-10-25T20:22:56.086919Z", - "iopub.status.idle": "2023-10-25T20:24:15.899979Z", - "shell.execute_reply": "2023-10-25T20:24:15.899402Z" + "iopub.execute_input": "2023-10-25T20:35:55.831065Z", + "iopub.status.busy": "2023-10-25T20:35:55.830860Z", + "iopub.status.idle": "2023-10-25T20:37:01.553068Z", + "shell.execute_reply": "2023-10-25T20:37:01.552567Z" } }, "outputs": [ @@ -266,12 +266,12 @@ " message: CONVERGENCE: REL_REDUCTION_OF_F_<=_FACTR*EPSMCH\n", " success: True\n", " status: 0\n", - " fun: -77.6280696593387\n", - " x: [ 2.256e+00 4.570e-01 ... -6.100e-01 4.518e-02]\n", - " nit: 586\n", - " jac: [ 6.963e-05 7.674e-05 ... 2.615e-04 -3.823e-04]\n", - " nfev: 28905\n", - " njev: 615\n", + " fun: -77.62872959177449\n", + " x: [-4.398e-01 1.209e+00 ... 9.303e-01 -3.817e-01]\n", + " nit: 467\n", + " jac: [ 7.788e-04 -1.293e-04 ... 5.684e-05 7.390e-05]\n", + " nfev: 23641\n", + " njev: 503\n", " hess_inv: <46x46 LbfgsInvHessProduct with dtype=float64>\n" ] } diff --git a/.doctrees/nbsphinx/tutorials/05-entanglement-forging.ipynb b/.doctrees/nbsphinx/tutorials/05-entanglement-forging.ipynb index 80a6baf05..ce59dedc5 100644 --- a/.doctrees/nbsphinx/tutorials/05-entanglement-forging.ipynb +++ b/.doctrees/nbsphinx/tutorials/05-entanglement-forging.ipynb @@ -14,10 +14,10 @@ "execution_count": 1, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:17.762959Z", - "iopub.status.busy": "2023-10-25T20:24:17.762532Z", - "iopub.status.idle": "2023-10-25T20:24:18.221382Z", - "shell.execute_reply": "2023-10-25T20:24:18.220857Z" + "iopub.execute_input": "2023-10-25T20:37:03.214961Z", + "iopub.status.busy": "2023-10-25T20:37:03.214603Z", + "iopub.status.idle": "2023-10-25T20:37:03.665782Z", + "shell.execute_reply": "2023-10-25T20:37:03.665270Z" } }, "outputs": [ @@ -90,10 +90,10 @@ "execution_count": 2, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:18.226276Z", - "iopub.status.busy": "2023-10-25T20:24:18.224796Z", - "iopub.status.idle": "2023-10-25T20:24:18.265443Z", - "shell.execute_reply": "2023-10-25T20:24:18.264964Z" + "iopub.execute_input": "2023-10-25T20:37:03.670968Z", + "iopub.status.busy": "2023-10-25T20:37:03.669311Z", + "iopub.status.idle": "2023-10-25T20:37:03.706953Z", + "shell.execute_reply": "2023-10-25T20:37:03.706430Z" } }, "outputs": [ @@ -101,7 +101,7 @@ "name": "stdout", "output_type": "stream", "text": [ - "Energy at initialialization: -75.68366174447618\n" + "Energy at initialialization: -75.68366174447621\n" ] } ], @@ -135,10 +135,10 @@ "execution_count": 3, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:18.269135Z", - "iopub.status.busy": "2023-10-25T20:24:18.268227Z", - "iopub.status.idle": "2023-10-25T20:24:20.012424Z", - "shell.execute_reply": "2023-10-25T20:24:20.011652Z" + "iopub.execute_input": "2023-10-25T20:37:03.710817Z", + "iopub.status.busy": "2023-10-25T20:37:03.709874Z", + "iopub.status.idle": "2023-10-25T20:37:05.455758Z", + "shell.execute_reply": "2023-10-25T20:37:05.455155Z" } }, "outputs": [ @@ -150,7 +150,7 @@ " message: Maximum number of function evaluations has been exceeded.\n", " success: False\n", " status: 2\n", - " fun: -75.69448131203954\n", + " fun: -75.69448131142009\n", " x: [ 1.354e+00 9.651e-02 -1.863e-03 1.095e+00 -2.132e-01]\n", " nfev: 100\n", " maxcv: 0.0\n" diff --git a/.doctrees/nbsphinx/tutorials/06-fermion-operator.ipynb b/.doctrees/nbsphinx/tutorials/06-fermion-operator.ipynb index 1be1409fa..dc8cac7d6 100644 --- a/.doctrees/nbsphinx/tutorials/06-fermion-operator.ipynb +++ b/.doctrees/nbsphinx/tutorials/06-fermion-operator.ipynb @@ -29,10 +29,10 @@ "execution_count": 1, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.457139Z", - "iopub.status.busy": "2023-10-25T20:24:21.456721Z", - "iopub.status.idle": "2023-10-25T20:24:21.754896Z", - "shell.execute_reply": "2023-10-25T20:24:21.754301Z" + "iopub.execute_input": "2023-10-25T20:37:06.834339Z", + "iopub.status.busy": "2023-10-25T20:37:06.833983Z", + "iopub.status.idle": "2023-10-25T20:37:07.114724Z", + "shell.execute_reply": "2023-10-25T20:37:07.114192Z" } }, "outputs": [ @@ -40,9 +40,9 @@ "data": { "text/plain": [ "FermionOperator({\n", - " (cre_b(1), des_b(5), cre_a(4)): 1+1j,\n", " (cre_a(0), des_a(3)): 0.5,\n", - " (cre_a(3), des_a(0)): -0.25\n", + " (cre_a(3), des_a(0)): -0.25,\n", + " (cre_b(1), des_b(5), cre_a(4)): 1+1j\n", "})" ] }, @@ -76,17 +76,17 @@ "execution_count": 2, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.757956Z", - "iopub.status.busy": "2023-10-25T20:24:21.757656Z", - "iopub.status.idle": "2023-10-25T20:24:21.766508Z", - "shell.execute_reply": "2023-10-25T20:24:21.762905Z" + "iopub.execute_input": "2023-10-25T20:37:07.118784Z", + "iopub.status.busy": "2023-10-25T20:37:07.117777Z", + "iopub.status.idle": "2023-10-25T20:37:07.123505Z", + "shell.execute_reply": "2023-10-25T20:37:07.123048Z" } }, "outputs": [ { "data": { "text/plain": [ - "'FermionOperator({((True, True, 1), (False, True, 5), (True, False, 4)): 1+1j, ((True, False, 0), (False, False, 3)): 0.5+0j, ((True, False, 3), (False, False, 0)): -0.25+0j})'" + "'FermionOperator({((True, False, 0), (False, False, 3)): 0.5+0j, ((True, False, 3), (False, False, 0)): -0.25+0j, ((True, True, 1), (False, True, 5), (True, False, 4)): 1+1j})'" ] }, "execution_count": 2, @@ -110,10 +110,10 @@ "execution_count": 3, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.769556Z", - "iopub.status.busy": "2023-10-25T20:24:21.769352Z", - "iopub.status.idle": "2023-10-25T20:24:21.775327Z", - "shell.execute_reply": "2023-10-25T20:24:21.774828Z" + "iopub.execute_input": "2023-10-25T20:37:07.127103Z", + "iopub.status.busy": "2023-10-25T20:37:07.126199Z", + "iopub.status.idle": "2023-10-25T20:37:07.132512Z", + "shell.execute_reply": "2023-10-25T20:37:07.132066Z" } }, "outputs": [ @@ -121,17 +121,17 @@ "data": { "text/plain": [ "FermionOperator({\n", - " (cre_b(1), des_b(5), cre_a(4), des_a(3), des_b(3)): -0.25-0.25j,\n", - " (cre_b(2)): 0-0.25j,\n", + " (cre_a(0), des_a(3), cre_b(2)): 0+0.5j,\n", " (cre_a(0), des_a(3)): 1,\n", + " (cre_a(3), des_a(0)): -0.5,\n", " (cre_b(1), des_b(5), cre_a(4), cre_b(2)): -1+1j,\n", - " (cre_a(3), des_a(0), des_a(3), des_b(3)): 0.0625,\n", + " (cre_a(3), des_a(0), cre_b(2)): 0-0.25j,\n", + " (cre_b(2)): 0-0.25j,\n", + " (cre_b(1), des_b(5), cre_a(4)): 2+2j,\n", " (des_a(3), des_b(3)): 0.0625,\n", + " (cre_a(3), des_a(0), des_a(3), des_b(3)): 0.0625,\n", " (cre_a(0), des_a(3), des_a(3), des_b(3)): -0.125,\n", - " (cre_b(1), des_b(5), cre_a(4)): 2+2j,\n", - " (cre_a(0), des_a(3), cre_b(2)): 0+0.5j,\n", - " (cre_a(3), des_a(0)): -0.5,\n", - " (cre_a(3), des_a(0), cre_b(2)): 0-0.25j\n", + " (cre_b(1), des_b(5), cre_a(4), des_a(3), des_b(3)): -0.25-0.25j\n", "})" ] }, @@ -169,10 +169,10 @@ "execution_count": 4, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.777921Z", - "iopub.status.busy": "2023-10-25T20:24:21.777727Z", - "iopub.status.idle": "2023-10-25T20:24:21.783143Z", - "shell.execute_reply": "2023-10-25T20:24:21.782591Z" + "iopub.execute_input": "2023-10-25T20:37:07.136109Z", + "iopub.status.busy": "2023-10-25T20:37:07.135213Z", + "iopub.status.idle": "2023-10-25T20:37:07.140929Z", + "shell.execute_reply": "2023-10-25T20:37:07.140482Z" } }, "outputs": [ @@ -180,17 +180,17 @@ "data": { "text/plain": [ "FermionOperator({\n", - " (cre_b(1), des_b(5), cre_a(4), des_a(3), des_b(3)): -1+1j,\n", - " (cre_b(2)): -5,\n", + " (cre_a(0), des_a(3), cre_b(2)): 2,\n", " (cre_a(0), des_a(3)): 0-6j,\n", + " (cre_a(3), des_a(0)): 0+3j,\n", " (cre_b(1), des_b(5), cre_a(4), cre_b(2)): 4+4j,\n", - " (cre_a(3), des_a(0), des_a(3), des_b(3)): 0-0.25j,\n", + " (cre_a(3), des_a(0), cre_b(2)): -1,\n", + " (cre_b(2)): -5,\n", + " (cre_b(1), des_b(5), cre_a(4)): 12-12j,\n", " (des_a(3), des_b(3)): 0-1.25j,\n", + " (cre_a(3), des_a(0), des_a(3), des_b(3)): 0-0.25j,\n", " (cre_a(0), des_a(3), des_a(3), des_b(3)): 0+0.5j,\n", - " (cre_b(1), des_b(5), cre_a(4)): 12-12j,\n", - " (cre_a(0), des_a(3), cre_b(2)): 2,\n", - " (cre_a(3), des_a(0)): 0+3j,\n", - " (cre_a(3), des_a(0), cre_b(2)): -1\n", + " (cre_b(1), des_b(5), cre_a(4), des_a(3), des_b(3)): -1+1j\n", "})" ] }, @@ -219,10 +219,10 @@ "execution_count": 5, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.785979Z", - "iopub.status.busy": "2023-10-25T20:24:21.785785Z", - "iopub.status.idle": "2023-10-25T20:24:21.790767Z", - "shell.execute_reply": "2023-10-25T20:24:21.790264Z" + "iopub.execute_input": "2023-10-25T20:37:07.144466Z", + "iopub.status.busy": "2023-10-25T20:37:07.143573Z", + "iopub.status.idle": "2023-10-25T20:37:07.149049Z", + "shell.execute_reply": "2023-10-25T20:37:07.148600Z" } }, "outputs": [ @@ -231,15 +231,15 @@ "text/plain": [ "FermionOperator({\n", " (cre_b(1), cre_a(4), des_b(5), des_b(3), des_a(3)): -1+1j,\n", - " (cre_b(1), cre_a(4), des_b(5)): -12+12j,\n", - " (cre_a(3), des_b(3), des_a(3), des_a(0)): 0+0.25j,\n", - " (cre_a(0), des_a(3)): 0-6j,\n", " (cre_b(2), cre_a(0), des_a(3)): 2,\n", - " (des_b(3), des_a(3)): 0+1.25j,\n", + " (cre_b(2)): -5,\n", + " (cre_b(2), cre_b(1), cre_a(4), des_b(5)): 4+4j,\n", " (cre_b(2), cre_a(3), des_a(0)): -1,\n", + " (des_b(3), des_a(3)): 0+1.25j,\n", + " (cre_b(1), cre_a(4), des_b(5)): -12+12j,\n", " (cre_a(3), des_a(0)): 0+3j,\n", - " (cre_b(2), cre_b(1), cre_a(4), des_b(5)): 4+4j,\n", - " (cre_b(2)): -5\n", + " (cre_a(0), des_a(3)): 0-6j,\n", + " (cre_a(3), des_b(3), des_a(3), des_a(0)): 0+0.25j\n", "})" ] }, @@ -264,10 +264,10 @@ "execution_count": 6, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.793387Z", - "iopub.status.busy": "2023-10-25T20:24:21.793193Z", - "iopub.status.idle": "2023-10-25T20:24:21.797643Z", - "shell.execute_reply": "2023-10-25T20:24:21.797144Z" + "iopub.execute_input": "2023-10-25T20:37:07.152630Z", + "iopub.status.busy": "2023-10-25T20:37:07.151744Z", + "iopub.status.idle": "2023-10-25T20:37:07.156781Z", + "shell.execute_reply": "2023-10-25T20:37:07.156331Z" } }, "outputs": [ @@ -297,10 +297,10 @@ "execution_count": 7, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.800381Z", - "iopub.status.busy": "2023-10-25T20:24:21.800192Z", - "iopub.status.idle": "2023-10-25T20:24:21.805824Z", - "shell.execute_reply": "2023-10-25T20:24:21.805322Z" + "iopub.execute_input": "2023-10-25T20:37:07.160764Z", + "iopub.status.busy": "2023-10-25T20:37:07.159841Z", + "iopub.status.idle": "2023-10-25T20:37:07.166312Z", + "shell.execute_reply": "2023-10-25T20:37:07.165878Z" } }, "outputs": [ @@ -340,21 +340,21 @@ "execution_count": 8, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.808537Z", - "iopub.status.busy": "2023-10-25T20:24:21.808342Z", - "iopub.status.idle": "2023-10-25T20:24:21.816002Z", - "shell.execute_reply": "2023-10-25T20:24:21.815505Z" + "iopub.execute_input": "2023-10-25T20:37:07.170009Z", + "iopub.status.busy": "2023-10-25T20:37:07.169123Z", + "iopub.status.idle": "2023-10-25T20:37:07.176665Z", + "shell.execute_reply": "2023-10-25T20:37:07.176224Z" } }, "outputs": [ { "data": { "text/plain": [ - "array([0. +0.j , 0. +0.j ,\n", - " 0. +0.j , 0. +0.j ,\n", - " 0.14019459+0.05152728j, 0. +0.j ,\n", - " 0. +0.j , 0. +0.j ,\n", - " 0. +0.j ])" + "array([ 0. +0.j , 0. +0.j ,\n", + " 0. +0.j , 0. +0.j ,\n", + " -0.11830879-0.02112505j, 0. +0.j ,\n", + " 0. +0.j , 0. +0.j ,\n", + " 0. +0.j ])" ] }, "execution_count": 8, @@ -379,10 +379,10 @@ "execution_count": 9, "metadata": { "execution": { - "iopub.execute_input": "2023-10-25T20:24:21.818749Z", - "iopub.status.busy": "2023-10-25T20:24:21.818558Z", - "iopub.status.idle": "2023-10-25T20:24:21.831581Z", - "shell.execute_reply": "2023-10-25T20:24:21.831134Z" + "iopub.execute_input": "2023-10-25T20:37:07.180124Z", + "iopub.status.busy": "2023-10-25T20:37:07.179254Z", + "iopub.status.idle": "2023-10-25T20:37:07.190877Z", + "shell.execute_reply": "2023-10-25T20:37:07.190428Z" } }, "outputs": [ diff --git a/.doctrees/tutorials/03-double-factorized.doctree b/.doctrees/tutorials/03-double-factorized.doctree index 61df3933f..7fe9f54f4 100644 Binary files a/.doctrees/tutorials/03-double-factorized.doctree and b/.doctrees/tutorials/03-double-factorized.doctree differ diff --git a/.doctrees/tutorials/04-lucj.doctree b/.doctrees/tutorials/04-lucj.doctree index d4d778c09..841cd4f29 100644 Binary files a/.doctrees/tutorials/04-lucj.doctree and b/.doctrees/tutorials/04-lucj.doctree differ diff --git a/.doctrees/tutorials/05-entanglement-forging.doctree b/.doctrees/tutorials/05-entanglement-forging.doctree index 44de45d6f..e5d7af149 100644 Binary files a/.doctrees/tutorials/05-entanglement-forging.doctree and b/.doctrees/tutorials/05-entanglement-forging.doctree differ diff --git a/.doctrees/tutorials/06-fermion-operator.doctree b/.doctrees/tutorials/06-fermion-operator.doctree index 10f814e20..889dbcbdb 100644 Binary files a/.doctrees/tutorials/06-fermion-operator.doctree and b/.doctrees/tutorials/06-fermion-operator.doctree differ diff --git a/_modules/ffsim/hamiltonians/double_factorized_hamiltonian.html b/_modules/ffsim/hamiltonians/double_factorized_hamiltonian.html index 4e472859f..44c9c915f 100644 --- a/_modules/ffsim/hamiltonians/double_factorized_hamiltonian.html +++ b/_modules/ffsim/hamiltonians/double_factorized_hamiltonian.html @@ -106,12 +106,12 @@
The one-body tensor \(\kappa\).
+np.ndarray
+The diagonal Coulomb matrices.
+np.ndarray
+The orbital rotations.
+np.ndarray
+The constant.
+float
+Whether the Hamiltonian is in the “Z” representation rather -than the “number” representation.
+Whether the Hamiltonian is in the “Z” representation +rather than the “number” representation.
+bool
+The number of spatial orbitals.
The one-body tensor.
+np.ndarray
+The two-body tensor.
+np.ndarray
+The constant.
+float
+The number of spatial orbitals.
The one-body tensor \(\kappa\).
+np.ndarray
+The diagonal Coulomb matrices.
+np.ndarray
+The orbital rotations.
+np.ndarray
+The constant.
+float
+Whether the Hamiltonian is in the “Z” representation rather -than the “number” representation.
+Whether the Hamiltonian is in the “Z” representation +rather than the “number” representation.
+bool
+The one-body tensor.
+np.ndarray
+The two-body tensor.
+np.ndarray
+The constant.
+float
+
-Fidelity of Trotter-evolved state with exact state: 0.9999906233109686
+Fidelity of Trotter-evolved state with exact state: 0.9999906233109683
As mentioned above, ffsim already includes functionality for Trotter simulation of double-factorized Hamiltonians. The implementation in ffsim includes higher-order Trotter-Suzuki formulas. The first-order asymmetric formula that we just implemented corresponds to order=0
in ffsim’s implementation. order=1
corresponds to the first-order symmetric (commonly known as the second-order) formula, order=2
corresponds to the second-order symmetric (fourth-order) formula, and so on.
-Fidelity of Trotter-evolved state with exact state: 0.9999906233109686
+Fidelity of Trotter-evolved state with exact state: 0.9999906233109683
A higher order formula achieves a higher fidelity with fewer Trotter steps:
@@ -435,7 +435,7 @@
-Fidelity of Trotter-evolved state with exact state: 0.9999999336740067
+Fidelity of Trotter-evolved state with exact state: 0.9999999336740071
-converged SCF energy = -77.4456267643962
+converged SCF energy = -77.4456267643961
CASCI E = -77.6290254326717 E(CI) = -3.57322412553862 S^2 = 0.0000000
-E(CCSD) = -77.49387212754471 E_corr = -0.04824536314851481
-Energy at initialialization: -77.46975600021685
+E(CCSD) = -77.49387212754462 E_corr = -0.04824536314851294
+Energy at initialialization: -77.46975600021707
To facilitate variational optimization of the ansatz, UCJOperator
implements methods for conversion to and from a vector of real-valued parameters. The precise relation between a parameter vector and the matrices of the UCJ operator is somewhat complicated. In short, the parameter vector stores the entries of the UCJ matrices in a non-redundant way (for the orbital rotations, the parameter vector actually stores the entries of their generators.)
-Energy at initialialization: -75.68366174447618
+Energy at initialialization: -75.68366174447621
FermionOperator({
- (cre_b(1), des_b(5), cre_a(4)): 1+1j,
(cre_a(0), des_a(3)): 0.5,
- (cre_a(3), des_a(0)): -0.25
+ (cre_a(3), des_a(0)): -0.25,
+ (cre_b(1), des_b(5), cre_a(4)): 1+1j
})
-'FermionOperator({((True, True, 1), (False, True, 5), (True, False, 4)): 1+1j, ((True, False, 0), (False, False, 3)): 0.5+0j, ((True, False, 3), (False, False, 0)): -0.25+0j})'
+'FermionOperator({((True, False, 0), (False, False, 3)): 0.5+0j, ((True, False, 3), (False, False, 0)): -0.25+0j, ((True, True, 1), (False, True, 5), (True, False, 4)): 1+1j})'
FermionOperators support arithmetic operations. Note that when multiplying a FermionOperator by a scalar, the scalar must go on the left, i.e. 2 * op
and not op * 2
.
FermionOperator({
- (cre_b(1), des_b(5), cre_a(4), des_a(3), des_b(3)): -0.25-0.25j,
- (cre_b(2)): 0-0.25j,
+ (cre_a(0), des_a(3), cre_b(2)): 0+0.5j,
(cre_a(0), des_a(3)): 1,
+ (cre_a(3), des_a(0)): -0.5,
(cre_b(1), des_b(5), cre_a(4), cre_b(2)): -1+1j,
- (cre_a(3), des_a(0), des_a(3), des_b(3)): 0.0625,
+ (cre_a(3), des_a(0), cre_b(2)): 0-0.25j,
+ (cre_b(2)): 0-0.25j,
+ (cre_b(1), des_b(5), cre_a(4)): 2+2j,
(des_a(3), des_b(3)): 0.0625,
+ (cre_a(3), des_a(0), des_a(3), des_b(3)): 0.0625,
(cre_a(0), des_a(3), des_a(3), des_b(3)): -0.125,
- (cre_b(1), des_b(5), cre_a(4)): 2+2j,
- (cre_a(0), des_a(3), cre_b(2)): 0+0.5j,
- (cre_a(3), des_a(0)): -0.5,
- (cre_a(3), des_a(0), cre_b(2)): 0-0.25j
+ (cre_b(1), des_b(5), cre_a(4), des_a(3), des_b(3)): -0.25-0.25j
})
FermionOperator({
- (cre_b(1), des_b(5), cre_a(4), des_a(3), des_b(3)): -1+1j,
- (cre_b(2)): -5,
+ (cre_a(0), des_a(3), cre_b(2)): 2,
(cre_a(0), des_a(3)): 0-6j,
+ (cre_a(3), des_a(0)): 0+3j,
(cre_b(1), des_b(5), cre_a(4), cre_b(2)): 4+4j,
- (cre_a(3), des_a(0), des_a(3), des_b(3)): 0-0.25j,
+ (cre_a(3), des_a(0), cre_b(2)): -1,
+ (cre_b(2)): -5,
+ (cre_b(1), des_b(5), cre_a(4)): 12-12j,
(des_a(3), des_b(3)): 0-1.25j,
+ (cre_a(3), des_a(0), des_a(3), des_b(3)): 0-0.25j,
(cre_a(0), des_a(3), des_a(3), des_b(3)): 0+0.5j,
- (cre_b(1), des_b(5), cre_a(4)): 12-12j,
- (cre_a(0), des_a(3), cre_b(2)): 2,
- (cre_a(3), des_a(0)): 0+3j,
- (cre_a(3), des_a(0), cre_b(2)): -1
+ (cre_b(1), des_b(5), cre_a(4), des_a(3), des_b(3)): -1+1j
})
FermionOperator({ (cre_b(1), cre_a(4), des_b(5), des_b(3), des_a(3)): -1+1j, - (cre_b(1), cre_a(4), des_b(5)): -12+12j, - (cre_a(3), des_b(3), des_a(3), des_a(0)): 0+0.25j, - (cre_a(0), des_a(3)): 0-6j, (cre_b(2), cre_a(0), des_a(3)): 2, - (des_b(3), des_a(3)): 0+1.25j, + (cre_b(2)): -5, + (cre_b(2), cre_b(1), cre_a(4), des_b(5)): 4+4j, (cre_b(2), cre_a(3), des_a(0)): -1, + (des_b(3), des_a(3)): 0+1.25j, + (cre_b(1), cre_a(4), des_b(5)): -12+12j, (cre_a(3), des_a(0)): 0+3j, - (cre_b(2), cre_b(1), cre_a(4), des_b(5)): 4+4j, - (cre_b(2)): -5 + (cre_a(0), des_a(3)): 0-6j, + (cre_a(3), des_b(3), des_a(3), des_a(0)): 0+0.25j })@@ -271,11 +271,11 @@
-array([0. +0.j , 0. +0.j ,
- 0. +0.j , 0. +0.j ,
- 0.14019459+0.05152728j, 0. +0.j ,
- 0. +0.j , 0. +0.j ,
- 0. +0.j ])
+array([ 0. +0.j , 0. +0.j ,
+ 0. +0.j , 0. +0.j ,
+ -0.11830879-0.02112505j, 0. +0.j ,
+ 0. +0.j , 0. +0.j ,
+ 0. +0.j ])
It can also be passed into most linear algebra routines in scipy.sparse.linalg
.