From a52e2e1ff6b80ca5b6b695e1950b01c72e9a9539 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andrius=20=C5=A0tikonas?= Date: Sat, 25 Apr 2015 02:47:55 +0100 Subject: [PATCH] Initial commit. --- CMakeLists.txt | 6 +++ scrambling.cpp | 99 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 105 insertions(+) create mode 100644 CMakeLists.txt create mode 100644 scrambling.cpp diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 0000000..b99aec4 --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,6 @@ +cmake_minimum_required(VERSION 2.8) +project(Scrambling) + +add_definitions(-std=gnu++11) + +add_executable(scrambling scrambling.cpp) diff --git a/scrambling.cpp b/scrambling.cpp new file mode 100644 index 0000000..f9fb774 --- /dev/null +++ b/scrambling.cpp @@ -0,0 +1,99 @@ +/************************************************************************* + * Copyright (C) 2015 by Andrius Štikonas * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 3 of the License, or * + * (at your option) any later version. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program. If not, see .* + *************************************************************************/ + +// Calculation of mutual information in the setup of http://arxiv.org/abs/1503.08161 + +#include +#include +#include +#include + +static double alpha, beta; +std::complex crossRatio (std::complex, std::complex, std::complex, std::complex); +double Fitzpatrick(std::complex, std::complex, double); + +int main() +{ + // Parameters that can be changed: + double tPlus = 0; // time on the left boundary + double tMinus = 0; // time on the right boundary + alpha = 0.4; // encodes the conformal dimention of local operator h_Psi + double y = 1; // endpoint of interval A + double L = 5; // length of interval A + double epsilon = 0.01; // smearing parameter + beta = 10; // inverse temperature + double tOmega = 5.4418; // thermal state is perturbed by operator inserted at time -tOmega + double c = 600; // central charge. Must be large in our approximation + // End of parameters + + // Operator insertion points: Left boundary + std::complex x1 (0, -epsilon), x4 (0, epsilon), x1bar, x4bar; + x1bar = conj(x1); + x4bar = conj(x4); + double x2 = y - tOmega - tMinus; + double x2bar = y + tOmega + tMinus; + double x3 = L + x2; + double x3bar = L + x2bar; + + // Operator insertion points: Right boundary + std::complex x6 (y - tPlus - tOmega, beta/2); + std::complex x6bar (y + tPlus + tOmega, -beta/2); + std::complex x5 = L + x6; + std::complex x5bar = L + x6bar; + + // Cross-ratios for S_A + std::complex zA = crossRatio(x1, x2, x3, x4); + std::complex zAbar = crossRatio(x1bar, x2bar, x3bar, x4bar); + + // Cross-ratios for S_B + std::complex zB = crossRatio(x1, x5, x6, x4); + std::complex zBbar = crossRatio(x1bar, x5bar, x6bar, x4bar); + + // Cross-ratios for S_{A union B} + std::complex z2 = crossRatio(x1, x2, x6, x4); + std::complex z2bar = crossRatio(x1bar, x2bar, x6bar, x4bar); + std::complex z5 = crossRatio(x1, x5, x3, x4); + std::complex z5bar = crossRatio(x1bar, x5bar, x3bar, x4bar); + + // Now we calculate entanglement entropies using Fitzpatrick, Kaplan, Walters formula. + double S_A = c/6 * log(Fitzpatrick(zA, zAbar, 2*M_PI)); + double S_B = c/6 * log(Fitzpatrick(zB, zBbar, 0)); + double S_union = c/6 * log(Fitzpatrick(z2, z2bar, 2*M_PI) * Fitzpatrick(z5, z5bar, 0)); + double S_thermal = 2*c/3 * log(sinh(M_PI*L/beta)/cosh(M_PI/beta*(tMinus-tPlus))); + double I = S_A + S_B - S_union + S_thermal; + std::cout << I << std::endl; + return 0; +} + +std::complex crossRatio (std::complex x1, std::complex x2, std::complex x3, std::complex x4) +{ + double pb = M_PI/beta; + return sinh(pb*(x1-x2))*sinh(pb*(x3-x4))/sinh(pb*(x1-x3))/sinh(pb*(x2-x4)); +} + +double Fitzpatrick(std::complex z, std::complex zbar, double phase) +{ + // phase is necessary to take into account nontrivial monodromy + std::complex c1(1, 0); // one as a complex number + std::complex i(0,1); // imaginary unit + double alphaExpr = 0.5-alpha/2; + std::complex exponent1 = exp(phase*i*alphaExpr); + std::complex exponent2 = exp(phase*i*alpha); + return real(exponent1 * pow(z, alphaExpr) * pow(zbar, alphaExpr) + * (c1 - exponent2 * pow(z, alpha)) * (c1 - pow(zbar, alpha)) + / ( alpha*alpha * (c1-z) * (c1-zbar) ) ); +}