From d5962d232258996da4969fe00b4fd117d003e479 Mon Sep 17 00:00:00 2001 From: Connor Moore Date: Sat, 25 Apr 2026 21:38:01 -0400 Subject: Finished section 2 and section 3 --- .../figures/tracy-widom-approx/plot_tracy_widom.m | 41 ++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 report/figures/tracy-widom-approx/plot_tracy_widom.m (limited to 'report/figures/tracy-widom-approx/plot_tracy_widom.m') diff --git a/report/figures/tracy-widom-approx/plot_tracy_widom.m b/report/figures/tracy-widom-approx/plot_tracy_widom.m new file mode 100644 index 0000000..c43e3f6 --- /dev/null +++ b/report/figures/tracy-widom-approx/plot_tracy_widom.m @@ -0,0 +1,41 @@ +close all; +clear; clc; + +x = linspace(-6,4,1000) + +[pdf1,~] = tracywidom_appx(x,1) +[pdf2,~] = tracywidom_appx(x,2) +[pdf4,~] = tracywidom_appx(x,4) + +% Fig. 1 Tracy-Widoms +figure(1) +hold on +plot(x,pdf1) +plot(x,pdf2) +plot(x,pdf4) + +A = [x', pdf1', pdf2', pdf4'] +save -ascii tracy_widom.txt A + +% Fig 2. Compare to Normal +normpdf = @(x,mu,sigma) 1/(sigma*sqrt(2*pi)).*exp(-0.5*((x-mu)/sigma).^2) +npdf = normpdf(x,-1.38,1.268) + +figure(2) +hold on +plot(x,pdf1) +plot(x,npdf,'--') + +B = [x', pdf1', npdf'] +save -ascii tracy_widom_normal.txt B + +% Skewness and Excess Kurtosis +x_stat = linspace(-9,9,50e3) +[pdf1_stat,~] = tracywidom_appx(x_stat,1) +npdf_stat = normpdf(x_stat, -1.38, 1.268) + +fprintf("Tracy Widom\n") +[~,~] = pdf_stats(x_stat, pdf1_stat) +fprintf("Normal Distribution\n") +[~,~] = pdf_stats(x_stat, npdf_stat) + -- cgit v1.2.3