From 3003d96dbd16e1d9911486b1ea5634c73832f2b5 Mon Sep 17 00:00:00 2001 From: noah Date: Mon, 1 May 2023 00:33:12 -0500 Subject: [PATCH] test model --- Schrick-Noah_Project-2.R | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/Schrick-Noah_Project-2.R b/Schrick-Noah_Project-2.R index 7c77b20..f6aedb0 100644 --- a/Schrick-Noah_Project-2.R +++ b/Schrick-Noah_Project-2.R @@ -111,7 +111,6 @@ fun.2c <- function(x) {3-2*exp(-x)} fun.2c.fx <- function(x) {x+2*exp(-x)-3} fun.2c.string <- "x+2*exp(-x)-3" fun.2c.estimate <- findZeroRelax(fun.2c,-.5) -fun.2c.estimate[1] # Find the other root with bisection fun.2c.bisect <- findZeroBisect(fun.2c,-1,0,1e-6) # Plot 2c @@ -212,7 +211,10 @@ ggplot(data.frame(x=seq(1,80,.1)), aes(x)) + geom_hline(aes(yintercept=0, col = "y=0"), show.legend=TRUE)+ geom_vline(aes(xintercept=func.five.estimate[1], col = "bisection estimate"), show.legend=TRUE)+ - ggtitle("zeroth-order dimensional perturbation theory approximation for the chemical potential of the Gross-Pitaevskii equation in d dimensions") + + ggtitle("zeroth-order dimensional + perturbation theory approximation + for the chemical potential of the + Gross-Pitaevskii equation in d dimensions") + xlab("x") + ylab("y") + theme(text = element_text(size=20), plot.title = element_text(hjust = 0.5)) @@ -237,6 +239,9 @@ ggplot(data.frame(x=seq(5,80,.1)), aes(x)) + geom_hline(aes(yintercept=0, col = "y=0"), show.legend=TRUE)+ geom_vline(aes(xintercept=func.five.estimate[1], col = "bisection estimate"), show.legend=TRUE)+ - ggtitle("zeroth-order dimensional perturbation theory approximation for the chemical potential of the Gross-Pitaevskii equation in d dimensions") + + ggtitle("zeroth-order dimensional + perturbation theory approximation + for the chemical potential of the + Gross-Pitaevskii equation in d dimensions") + xlab("x") + ylab("y") + theme(text = element_text(size=20), plot.title = element_text(hjust = 0.5))