Nice plots for ontop
This commit is contained in:
parent
d2c52787d3
commit
3ebf2a6fb7
2002
Data/H2O.density
2002
Data/H2O.density
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
2002
Data/H2O_0.5.density
2002
Data/H2O_0.5.density
File diff suppressed because it is too large
Load Diff
2002
Data/H2O_1.0.density
2002
Data/H2O_1.0.density
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
2002
Data/H2O_1e6.density
2002
Data/H2O_1e6.density
File diff suppressed because it is too large
Load Diff
2002
Data/H2O_2.0.density
2002
Data/H2O_2.0.density
File diff suppressed because it is too large
Load Diff
2002
Data/H2O_5.0.density
2002
Data/H2O_5.0.density
File diff suppressed because it is too large
Load Diff
@ 6336,8 +6336,146 @@ to_kcal < 627.502164882


library(ggplot2)


library(latex2exp)


library(extrafont)


library(RColorBrewer)


loadfonts()


#+end_src




#+RESULTS:


#+begin_example




More than one version of regular/bold/italic found for Cannam Codec Fixed. Skipping setup for this font.


More than one version of regular/bold/italic found for Cannam Codec Proportional. Skipping setup for this font.


aakar already registered with pdfFonts().


Abyssinica SIL already registered with pdfFonts().


Ani already registered with pdfFonts().


AnjaliOldLipi already registered with pdfFonts().


Chandas already registered with pdfFonts().


Chilanka already registered with pdfFonts().


DejaVu Math TeX Gyre already registered with pdfFonts().


DejaVu Sans already registered with pdfFonts().


DejaVu Sans Light already registered with pdfFonts().


DejaVu Sans Condensed already registered with pdfFonts().


DejaVu Sans Mono already registered with pdfFonts().


DejaVu Serif already registered with pdfFonts().


DejaVu Serif Condensed already registered with pdfFonts().


Droid Sans Fallback already registered with pdfFonts().


Dyuthi already registered with pdfFonts().


FontAwesome already registered with pdfFonts().


FreeMono already registered with pdfFonts().


FreeSans already registered with pdfFonts().


FreeSerif already registered with pdfFonts().


Gargi already registered with pdfFonts().


Garuda already registered with pdfFonts().


Gubbi already registered with pdfFonts().


Jamrul already registered with pdfFonts().


JetBrains Mono already registered with pdfFonts().


JetBrains Mono ExtraBold already registered with pdfFonts().


JetBrains Mono Medium already registered with pdfFonts().


JetBrains Mono NL already registered with pdfFonts().


JetBrains Mono NL ExtraBold already registered with pdfFonts().


JetBrains Mono NL Medium already registered with pdfFonts().


KacstArt already registered with pdfFonts().


KacstBook already registered with pdfFonts().


KacstDecorative already registered with pdfFonts().


KacstDigital already registered with pdfFonts().


KacstFarsi already registered with pdfFonts().


KacstLetter already registered with pdfFonts().


KacstNaskh already registered with pdfFonts().


KacstOffice already registered with pdfFonts().


KacstOne already registered with pdfFonts().


KacstPen already registered with pdfFonts().


KacstPoster already registered with pdfFonts().


KacstQurn already registered with pdfFonts().


KacstScreen already registered with pdfFonts().


KacstTitle already registered with pdfFonts().


KacstTitleL already registered with pdfFonts().


Kalapi already registered with pdfFonts().


Kalimati already registered with pdfFonts().


Karumbi already registered with pdfFonts().


No regular (nonbold, nonitalic) version of Keraleeyam. Skipping setup for this font.


Khmer OS already registered with pdfFonts().


Khmer OS System already registered with pdfFonts().


More than one version of regular/bold/italic found for Kinnari. Skipping setup for this font.


Laksaman already registered with pdfFonts().


Lato Black already registered with pdfFonts().


Lato already registered with pdfFonts().


Lato Hairline already registered with pdfFonts().


Lato Heavy already registered with pdfFonts().


Lato Light already registered with pdfFonts().


Lato Medium already registered with pdfFonts().


Lato Semibold already registered with pdfFonts().


Lato Thin already registered with pdfFonts().


More than one version of regular/bold/italic found for Liberation Mono. Skipping setup for this font.


More than one version of regular/bold/italic found for Liberation Sans. Skipping setup for this font.


Liberation Sans Narrow already registered with pdfFonts().


More than one version of regular/bold/italic found for Liberation Serif. Skipping setup for this font.


Likhan already registered with pdfFonts().


LKLUG already registered with pdfFonts().


Lohit Assamese already registered with pdfFonts().


Lohit Bengali already registered with pdfFonts().


Lohit Devanagari already registered with pdfFonts().


Lohit Gujarati already registered with pdfFonts().


Lohit Gurmukhi already registered with pdfFonts().


Lohit Kannada already registered with pdfFonts().


Lohit Malayalam already registered with pdfFonts().


Lohit Odia already registered with pdfFonts().


Lohit Tamil already registered with pdfFonts().


Lohit Tamil Classical already registered with pdfFonts().


Lohit Telugu already registered with pdfFonts().


Loma already registered with pdfFonts().


Material Design Icons already registered with pdfFonts().


Meera already registered with pdfFonts().


Mitra Mono already registered with pdfFonts().


mry_KacstQurn already registered with pdfFonts().


Mukti Narrow already registered with pdfFonts().


Nakula already registered with pdfFonts().


Navilu already registered with pdfFonts().


More than one version of regular/bold/italic found for Norasi. Skipping setup for this font.


Noto Mono already registered with pdfFonts().


OpenSymbol already registered with pdfFonts().


Padauk already registered with pdfFonts().


Padauk Book already registered with pdfFonts().


More than one version of regular/bold/italic found for padmaa. Skipping setup for this font.


No regular (nonbold, nonitalic) version of padmaaBold.1.1. Skipping setup for this font.


Pagul already registered with pdfFonts().


Phetsarath OT already registered with pdfFonts().


Pothana2000 already registered with pdfFonts().


Purisa already registered with pdfFonts().


Rachana already registered with pdfFonts().


RaghuMalayalam already registered with pdfFonts().


Rekha already registered with pdfFonts().


Saab already registered with pdfFonts().


Sahadeva already registered with pdfFonts().


Samanata already registered with pdfFonts().


Samyak Devanagari already registered with pdfFonts().


Samyak Gujarati already registered with pdfFonts().


Samyak Malayalam already registered with pdfFonts().


Samyak Tamil already registered with pdfFonts().


Sarai already registered with pdfFonts().


Sawasdee already registered with pdfFonts().


Source Code Pro Black already registered with pdfFonts().


Source Code Pro already registered with pdfFonts().


Source Code Pro ExtraLight already registered with pdfFonts().


Source Code Pro Light already registered with pdfFonts().


Source Code Pro Medium already registered with pdfFonts().


Source Code Pro Semibold already registered with pdfFonts().


Suruma already registered with pdfFonts().


Tibetan Machine Uni already registered with pdfFonts().


TlwgMono already registered with pdfFonts().


TlwgTypewriter already registered with pdfFonts().


Tlwg Typist already registered with pdfFonts().


Tlwg Typo already registered with pdfFonts().


Ubuntu already registered with pdfFonts().


Ubuntu Light already registered with pdfFonts().


Ubuntu Condensed already registered with pdfFonts().


Ubuntu Mono already registered with pdfFonts().


More than one version of regular/bold/italic found for Umpush. Skipping setup for this font.


No regular (nonbold, nonitalic) version of Uroob. Skipping setup for this font.


utkal already registered with pdfFonts().


Vemana2000 already registered with pdfFonts().


Waree already registered with pdfFonts().


#+end_example




** Read csv


#+begin_src R :results output :session *R* :exports both


mad = function(x) { mean(abs(x)) }


@ 6652,27 +6790,119 @@ dev.off()


#+end_src




** Ontop pair density


#+begin_src gnuplot :file output.png


#set terminal pdf


#set output "ontopmu.pdf"


set xlabel "distance from O"


set ylabel "ontop pair density"


plot "H2O_1.e6.density" w l title "n2(r,r), {/Symbol m}=0", \


"H2O_0.25.density" w l title "n2(r,r), {/Symbol m}=0.25", \


"H2O_0.5.density" w l title "n2(r,r), {/Symbol m}=0.5", \


"H2O_1.0.density" w l title "n2(r,r), {/Symbol m}=1.0", \


"H2O_1e6.density" w l title "n2(r,r), {/Symbol m}=10^6", \


"H2O.density" w l title "n2(r,r), Jastrow"




#+begin_src R :results output graphics :file (orgbabeltempfile "figure" ".png") :exports both :width 600 :height 400 :session *R*


breaks < c("0.00", "0.25", "0.50", "1.00", "$\\infty$", "Jastrow")




tmp_data < read.csv("H2O_1.e6.density")


data.0 < data.frame(mu=breaks[1], x=tmp_data$X..distance, n=tmp_data$on.top)




tmp_data < read.csv("H2O_0.25.density")


data.0.25 < data.frame(mu=breaks[2], x=tmp_data$X..distance, n=tmp_data$on.top)




tmp_data < read.csv("H2O_0.5.density")


data.0.5 < data.frame(mu=breaks[3], x=tmp_data$X..distance, n=tmp_data$on.top)




tmp_data < read.csv("H2O_1.0.density")


data.1.0 < data.frame(mu=breaks[4], x=tmp_data$X..distance, n=tmp_data$on.top)




tmp_data < read.csv("H2O_1e6.density")


data.inf < data.frame(mu=breaks[5], x=tmp_data$X..distance, n=tmp_data$on.top)




tmp_data < read.csv("H2O.density")


data.J < data.frame(mu=breaks[6], x=tmp_data$X..distance, n=tmp_data$on.top)






data < rbind(data.0, data.0.25, data.0.5, data.1.0, data.inf)




labels= TeX(breaks)




p < ggplot(data, aes(x=x, y=n, col=mu))


p < p + geom_line(lwd=1.5)


p < p + geom_line(data=data.J, lwd=1, col=1, linetype="dashed")


p < p + scale_colour_discrete(name = TeX("$\\mu$"), breaks = breaks,


labels = labels)


#p < p + scale_color_brewer(palette = "Paired")


p < p + scale_x_continuous(name=TeX("$r_{OH}$ (bohr)"))


p < p + scale_y_continuous(name = "Integrated ontop pair density (a.u.)")


p < p + theme(text = element_text(size = 20, family="Times"), legend.position=c(.85,.75), legend.text.align = 0)


p




#+end_src






#+RESULTS:


[[file:output.png]]


[[file:/tmp/babeleZHQur/figurey8Ummd.png]]




#+begin_src R :results output :session *R* :exports both


pdf("../Manuscript/ontopmu.pdf", family="Times", width=8, height=5)


p


dev.off()


#+end_src


#+RESULTS:


:


: png


: 2




** Onebody density




#+begin_src gnuplot :file output.png


#+begin_src R :results output graphics :file (orgbabeltempfile "figure" ".png") :exports both :width 600 :height 400 :session *R*


breaks < c("0.00", "0.25", "0.50", "1.00", "$\\infty$", "Jastrow")




tmp_data < read.csv("H2O_1.e6.density")


data.0 < data.frame(mu=breaks[1], x=tmp_data$X..distance, n=tmp_data$density)




tmp_data < read.csv("H2O_0.25.density")


data.0.25 < data.frame(mu=breaks[2], x=tmp_data$X..distance, n=tmp_data$density)




tmp_data < read.csv("H2O_0.5.density")


data.0.5 < data.frame(mu=breaks[3], x=tmp_data$X..distance, n=tmp_data$density)




tmp_data < read.csv("H2O_1.0.density")


data.1.0 < data.frame(mu=breaks[4], x=tmp_data$X..distance, n=tmp_data$density)




tmp_data < read.csv("H2O_1e6.density")


data.inf < data.frame(mu=breaks[5], x=tmp_data$X..distance, n=tmp_data$density)




tmp_data < read.csv("H2O.density")


data.J < data.frame(mu=breaks[6], x=tmp_data$X..distance, n=tmp_data$density)






data < rbind(data.0, data.0.25, data.0.5, data.1.0, data.inf)




labels= TeX(breaks)




p < ggplot(data, aes(x=x, y=n, col=mu))


p < p + geom_line(lwd=1.5)


p < p + geom_line(data=data.J, lwd=1, col=1, linetype="dashed")


p < p + scale_colour_discrete(name = TeX("$\\mu$"), breaks = breaks,


labels = labels)


p < p + scale_x_continuous(name=TeX("$r_{OH}$ (bohr)"))


p < p + scale_y_continuous(name = "Density (a.u.)")


p < p + theme(text = element_text(size = 20, family="Times"), legend.position=c(.85,.75), legend.text.align = 0)


p




#+end_src




#+RESULTS:


[[file:/tmp/babeleZHQur/figureJZB5vg.png]]




#+begin_src R :results output :session *R* :exports both


pdf("../Manuscript/densitymu.pdf", family="Times", width=8, height=5)


p


dev.off()


#+end_src




#+RESULTS:


:


: png


: 2








#+begin_src gnuplot :file output2.png


#set terminal pdf


#set output "density.pdf"


reset


set xlabel "distance from O"


set ylabel "Density"


plot "H2O_1.e6.density" u 1:3 w l title "n2(r,r), {/Symbol m}=0", \


@ 6684,7 +6914,6 @@ plot "H2O_1.e6.density" u 1:3 w l title "n2(r,r), {/Symbol m}=0", \


#+end_src




#+RESULTS:


[[file:output.png]]




** Optimal mu


*** Table



Binary file not shown.
BIN
Manuscript/h2o200dmc.pdf
Normal file
BIN
Manuscript/h2o200dmc.pdf
Normal file
Binary file not shown.
Binary file not shown.
@ 512,7 +512,7 @@ but also the nonhermitian transcorrelated eigenvalue problem\cite{many_things}


which is much easier to handle despite its nonhermicity.


Of course, the FNDMC energy of $\Phi$ depends therefore only on the nodes of $\Psi^J$.


In a finite basis set and with a quite accurate Jastrow factor, it is known that the nodes


of $\Psi^J$ are better than that of the FCI wave function, and therefore, we would like to compare $\Psi^J$ and $\Psi^\mu$.


of $\Psi^J$ may be better than that of the FCI wave function, and therefore, we would like to compare $\Psi^J$ and $\Psi^\mu$.




To do so, we have made the following numerical experiment.


First, we extract the 200 determinants with the largest weights in the FCI wave


@ 558,10 +558,50 @@ with that of $\Psi^\mu$ with $0.5 < \mu < 1$~bohr$^{1}$. This confirms that


introducing shortrange correlation with DFT has


an impact on the CI coefficients similar to the Jastrow factor.




In order to refine the comparison between $\Psi^\mu$ and $\Psi^J$,


we report several quantities related to the one and twobody density


of $\Psi^J$ and $\Psi^\mu$ with different values of $\mu$.


First, we report in table~\ref{table_on_top} the integrated ontop pair density $\expval{ n_2({\bf r},{\bf r}) }$


\begin{table}


\caption{\ce{H2O}, doublezeta basis set. Integrated ontop pair density $\expval{ n_2({\bf r},{\bf r}) }$


for $\Psi^J$ and $\Psi^\mu$ with different values of $\mu$. }


\label{table_on_top}


\begin{ruledtabular}


\begin{tabular}{cc}


$\mu$ & $\expval{ n_2({\bf r},{\bf r}) }$ \\


\hline


0.00 & 1.443 \\


0.25 & 1.438 \\


0.50 & 1.423 \\


1.00 & 1.378 \\


2.00 & 1.325 \\


5.00 & 1.288 \\


$\infty$ & 1.277 \\


\hline


$\Psi^J$ & 1.404 \\


\end{tabular}


\end{ruledtabular}


\end{table}




\begin{figure}


\centering


\includegraphics[width=\columnwidth]{ontopmu.pdf}


\caption{\ce{H2O}, doublezeta basis set. Ontop pair


density $n_2({\bf r},{\bf r})$ along the OH axis,


for $\Psi^J$ (dashed curve) and $\Psi^\mu$ with different values of $\mu$. }


\label{fig:n2}


\end{figure}




\begin{figure}


\centering


\includegraphics[width=\columnwidth]{densitymu.pdf}


\caption{\ce{H2O}, doublezeta basis set. Density $n({\bf r})$ along


the OH axis, for $\Psi^J$ (dashed curve) and $\Psi^\mu$ with different values of $\mu$. }


\label{fig:n1}


\end{figure}






In order to refine the comparison between $\Psi^\mu$ and $\Psi^J$, we


report several quantities related to the one and twobody density of


$\Psi^J$ and $\Psi^\mu$ with different values of $\mu$. First, we


report in table~\ref{table_on_top} the integrated ontop pair density


$\expval{ n_2({\bf r},{\bf r}) }$


\begin{equation}


\expval{ n_2({\bf r},{\bf r}) } = \int \text{d}{\bf r} \,\,n_2({\bf r},{\bf r})


\end{equation}


@ 581,11 +621,15 @@ are much more important than that of the onebody density, the latter


being essentially unchanged between $\mu=0$ and $\mu=\infty$ while the


former can vary by about 10$\%$ in some regions.


%TODO TOTO


The values of the ontop pair density in $\Psi^\mu$ are closer for


certain values of $\mu$ to those of $\Psi^J$ than the FCI wave


function.


In the highdensity region of the OH bond, the value of the ontop


pair density obtained from $\Psi^J$ is superimposed with


$\Psi^{\mu=0.5}$, and at a large distance the ontop pair density is


the closest to $\mu=\infty$. The integrated ontop pair density


obtained with $\Psi^J$ lies between the values obtained with


$\mu=0.5$ and $\mu=1$~bohr$^{1}$, constently with the FNDMC energies


and the overlap curve.




These data suggest that the wave functions $\Psi^{\mu=0.5}$ and $\Psi^J$ are similar,


These data suggest that the wave functions $\Psi^{0.5 \le \mu \le 1}$ and $\Psi^J$ are close,


and therefore that the operators that produced these wave functions (\textit{i.e.} $H^\mu[n]$ and $e^{J}He^J$) contain similar physics.


Considering the form of $\hat{H}^\mu[n]$ (see Eq.~\eqref{H_mu}),


one can notice that the differences with respect to the usual Hamiltonian come


@ 605,53 +649,23 @@ Therefore, one can understand the similarity between the eigenfunctions of $H^\m


they both deal with an effective nondivergent interaction but still


produce a reasonable onebody density.




\begin{table}


\caption{\ce{H2O}, doublezeta basis set. Integrated ontop pair density $\expval{ n_2({\bf r},{\bf r}) }$


for $\Psi^J$ and $\Psi^\mu$ with different values of $\mu$. }


\label{table_on_top}


\begin{ruledtabular}


\begin{tabular}{cc}


$\mu$ & $\expval{ n_2({\bf r},{\bf r}) }$ \\


\hline


0.00 & 1.443 \\


0.25 & 1.438 \\


0.50 & 1.423 \\


1.00 & 1.378 \\


2.00 & 1.325 \\


5.00 & 1.288 \\


$\infty$ & 1.277 \\


\hline


$\Psi^J$ & \\


\end{tabular}


\end{ruledtabular}


\end{table}




\begin{figure}


\centering


\includegraphics[width=\columnwidth]{ontopmu.pdf}


\caption{\ce{H2O}, doublezeta basis set. Integrated ontop pair density $\expval{ n_2({\bf r},{\bf r}) }$ along the OH axis, for $\Psi^J$ and $\Psi^\mu$ with different values of $\mu$. }


\label{fig:n2}


\end{figure}


\begin{figure}


\centering


\includegraphics[width=\columnwidth]{densitymu.pdf}


\caption{\ce{H2O}, doublezeta basis set. Density $n({\bf r})$ along the OH axis, for $\Psi^J$ and $\Psi^\mu$ with different values of $\mu$. }


\label{fig:n1}


\end{figure}






As a conclusion of the first part of this study, we can notice that:


i) with respect to the nodes of a KS determinant or a FCI wave function,


one can obtain a multi determinant trial wave function $\Psi^\mu$ with a smaller


fixed node error by properly choosing an optimal value of $\mu$


in RSDFT calculations, ii) the value of the optimal $\mu$ depends


on the system and the basis set, and the larger the basis set, the larger the optimal value of $\mu$,


iii) numerical experiments (such as computation of overlap, FNDMC energies) indicates


that the RSDFT scheme essentially plays the role of a simple Jastrow factor,


\textit{i.e.} mimicking shortrange correlation effects.


The latter statement can be qualitatively understood by noticing that both RSDFT


and transcorrelated approach deal with an effective nondivergent electronelectron interaction, while keeping the density constant.




\begin{itemize}


\item with respect to the nodes of a KS determinant or a FCI wave function,


one can obtain a multi determinant trial wave function $\Psi^\mu$ with a smaller


fixed node error by properly choosing an optimal value of $\mu$


in RSDFT calculations,


\item the optimal value of $\mu$ depends on the system and the


basis set, and the larger the basis set, the larger the optimal value


of $\mu$,


\item numerical experiments (overlap $\braket{\Psi^\mu}{\Psi^J}$,


onebody density, ontop pair density, and FNDMC energy) indicate


that the RSDFT scheme essentially plays the role of a simple Jastrow factor,


\textit{i.e.} mimicking shortrange correlation effects. The latter


statement can be qualitatively understood by noticing that both RSDFT


and transcorrelated approaches deal with an effective nondivergent


electronelectron interaction, while keeping the density constant.


\end{itemize}






\section{Energy differences in FNDMC: atomization energies}



Loading…
Reference in New Issue
Block a user