// File: /workspace/github_cpp_makefile_star2_O1/PeterDenton[P]Nu-Pert/src/Figures.cpp
// Function: Figures::Pmu2e_Precision()
void Pmu2e_Precision()
{
	std::ofstream data("data/Pmu2e_Precision.txt");
	set_ordering(true);

	int exp_num = 0; // DUNE
	double delta = 3 * M_PI / 2;
	int alpha = 1; // nu_mu
	int beta = 0; // nu_e
	double Emin = 0.1;
	double Emax = 10;
	double Einc = 1.001;

	double Yrho, L, LE, a;
	double P_exact, P_GF0, P_GF1, P_Check2, P_Mixed, P_Mixed2;
	set_experimental_parameters(exp_num, &Yrho, &L);

	data << L << " ";
	data << delta << " ";
	data << std::endl;

	Progress_Bar Pbar;
	for (double E = Emin; E <= Emax; E *= Einc)
	{
		LE = L / E;
		a = Yrho * E * Y_to_a;

		P_exact = Exact::Palphabeta(alpha, beta, a, LE, delta);
		P_GF0 = GF::Palphabeta(alpha, beta, a, LE, delta, 0);
		P_GF1 = GF::Palphabeta(alpha, beta, a, LE, delta, 1);
		P_Check2 = Check::Palphabeta(alpha, beta, a, LE, delta, 2);
		P_Mixed = Mixed::Palphabeta(alpha, beta, a, LE, delta, 0);
		P_Mixed2 = Mixed::Palphabeta(alpha, beta, a, LE, delta, 2);

		data << E << " ";
		data << P_exact << " ";
		data << std::abs(1 - P_GF0 / P_exact) << " ";
		data << std::abs(1 - P_GF1 / P_exact) << " ";
		data << std::abs(1 - P_Check2 / P_exact) << " ";
		data << std::abs(1 - P_Mixed / P_exact) << " ";
		data << std::abs(1 - P_Mixed2 / P_exact) << " ";
		data << std::endl;

		Pbar.update(Emin, Emax, E, false);
	} // E
	data.close();
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x8d0, %rsp            # imm = 0x8D0
leaq 0x2288(%rip), %rsi      # 0xff6e
leaq 0x58(%rsp), %rdi
movl $0x10, %edx
callq 0x21b0
movl $0x1, %edi
callq 0x3a4b
leaq 0x50(%rsp), %rsi
leaq 0x20(%rsp), %rdx
xorl %edi, %edi
callq 0x57b0
movsd 0x20(%rsp), %xmm0
leaq 0x58(%rsp), %rdi
callq 0x2260
leaq 0x1f37(%rip), %rsi      # 0xfc5e
movl $0x1, %edx
movq %rax, %rdi
callq 0x21c0
leaq 0x58(%rsp), %rbx
movsd 0x213f(%rip), %xmm0     # 0xfe80
movq %rbx, %rdi
callq 0x2260
leaq 0x1f0e(%rip), %rsi      # 0xfc5e
movl $0x1, %edx
movq %rax, %rdi
callq 0x21c0
movq 0x58(%rsp), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21a0
movsbl %al, %esi
leaq 0x58(%rsp), %rbx
movq %rbx, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x2100
leaq 0x258(%rsp), %rdi
callq 0xbdf4
leaq 0x1591(%rip), %rax      # 0xf330
movsd (%rax), %xmm0
movsd %xmm0, 0x28(%rsp)
movsd 0x173f(%rip), %xmm2     # 0xf4f0
leaq 0x1ea6(%rip), %r14      # 0xfc5e
leaq 0x258(%rsp), %r15
movsd 0x20(%rsp), %xmm1
divsd %xmm2, %xmm1
movsd 0x50(%rsp), %xmm0
movsd %xmm2, 0x18(%rsp)
mulsd %xmm2, %xmm0
mulsd 0x28(%rsp), %xmm0
movl $0x1, %edi
xorl %esi, %esi
movsd %xmm0, 0x10(%rsp)
movsd %xmm1, (%rsp)
movsd 0x2086(%rip), %xmm2     # 0xfe80
callq 0x5477
movsd %xmm0, 0x8(%rsp)
movl $0x1, %edi
xorl %esi, %esi
movsd 0x10(%rsp), %xmm0
movsd (%rsp), %xmm1
movsd 0x2061(%rip), %xmm2     # 0xfe80
xorl %edx, %edx
callq 0x66a0
movsd %xmm0, 0x48(%rsp)
movl $0x1, %edi
xorl %esi, %esi
movsd 0x10(%rsp), %xmm0
movsd (%rsp), %xmm1
movsd 0x203a(%rip), %xmm2     # 0xfe80
movl $0x1, %edx
callq 0x66a0
movsd %xmm0, 0x40(%rsp)
movl $0x1, %edi
xorl %esi, %esi
movsd 0x10(%rsp), %xmm0
movsd (%rsp), %xmm1
movsd 0x2010(%rip), %xmm2     # 0xfe80
movl $0x2, %edx
callq 0x35d8
movsd %xmm0, 0x38(%rsp)
movl $0x1, %edi
xorl %esi, %esi
movsd 0x10(%rsp), %xmm0
movsd (%rsp), %xmm1
movsd 0x1fe6(%rip), %xmm2     # 0xfe80
xorl %edx, %edx
callq 0xbaf9
movsd %xmm0, 0x30(%rsp)
movl $0x1, %edi
xorl %esi, %esi
movsd 0x10(%rsp), %xmm0
movsd (%rsp), %xmm1
movsd 0x1fbf(%rip), %xmm2     # 0xfe80
movl $0x2, %edx
callq 0xbaf9
movsd %xmm0, (%rsp)
movq %rbx, %rdi
movsd 0x18(%rsp), %xmm0
callq 0x2260
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x21c0
movq %rbx, %rdi
movsd 0x8(%rsp), %xmm0
callq 0x2260
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x21c0
movsd 0x48(%rsp), %xmm1
divsd 0x8(%rsp), %xmm1
movsd 0x10f8(%rip), %xmm0     # 0xf018
subsd %xmm1, %xmm0
andpd 0x1594(%rip), %xmm0     # 0xf4c0
movq %rbx, %rdi
callq 0x2260
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x21c0
movsd 0x40(%rsp), %xmm1
divsd 0x8(%rsp), %xmm1
movsd 0x10c0(%rip), %xmm0     # 0xf018
subsd %xmm1, %xmm0
andpd 0x155c(%rip), %xmm0     # 0xf4c0
movq %rbx, %rdi
callq 0x2260
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x21c0
movsd 0x38(%rsp), %xmm1
divsd 0x8(%rsp), %xmm1
movsd 0x1088(%rip), %xmm0     # 0xf018
subsd %xmm1, %xmm0
andpd 0x1524(%rip), %xmm0     # 0xf4c0
movq %rbx, %rdi
callq 0x2260
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x21c0
movsd 0x30(%rsp), %xmm1
divsd 0x8(%rsp), %xmm1
movsd 0x1050(%rip), %xmm0     # 0xf018
subsd %xmm1, %xmm0
andpd 0x14ec(%rip), %xmm0     # 0xf4c0
movq %rbx, %rdi
callq 0x2260
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x21c0
movsd (%rsp), %xmm1
divsd 0x8(%rsp), %xmm1
movsd 0x1019(%rip), %xmm0     # 0xf018
subsd %xmm1, %xmm0
andpd 0x14b5(%rip), %xmm0     # 0xf4c0
movq %rbx, %rdi
callq 0x2260
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x21c0
movq 0x58(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21a0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x2100
movq %r15, %rdi
movsd 0x1499(%rip), %xmm0     # 0xf4f0
movsd 0x1bc9(%rip), %xmm1     # 0xfc28
movsd 0x18(%rsp), %xmm2
xorl %esi, %esi
callq 0xc27a
movsd 0x18(%rsp), %xmm2
mulsd 0x1e0e(%rip), %xmm2     # 0xfe88
movsd 0x1ba6(%rip), %xmm0     # 0xfc28
ucomisd %xmm2, %xmm0
jae 0xddc0
leaq 0x58(%rsp), %rdi
callq 0x2210
leaq 0x258(%rsp), %rdi
callq 0xc054
movq 0x5f1e(%rip), %rax      # 0x13fc8
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x60(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x58(%rsp,%rcx)
callq 0x2150
leaq 0x150(%rsp), %rdi
callq 0x20a0
addq $0x8d0, %rsp            # imm = 0x8D0
popq %rbx
popq %r14
popq %r15
retq
jmp 0xe0ed
jmp 0xe0e8
jmp 0xe0e8
movq %rax, %rbx
jmp 0xe0fd
movq %rax, %rbx
leaq 0x258(%rsp), %rdi
callq 0xc054
leaq 0x58(%rsp), %rdi
callq 0x2220
movq %rbx, %rdi
callq 0x22b0