18double WaveFunction(
double x,
double y) {
27void schroedinger_hydrogen() {
28 TH2F *h2D =
new TH2F(
"Hydrogen Atom",
29 "Hydrogen in n = 2, l = 0, m = 0 state; Position in x direction; Position in y direction",
30 200, -10, 10, 200, -10, 10);
32 for (
float i = -10; i < 10; i += 0.01) {
33 for (
float j = -10; j < 10; j += 0.01) {
34 h2D->
Fill(i, j, WaveFunction(i, j));
44 auto c1_1 =
c1->cd(1);
45 c1_1->SetRightMargin(0.14);
52 TLatex *
l =
new TLatex(-10, -12.43,
"The Electron is more likely to be found in the yellow areas and less likely to be found in the blue areas.");
57 auto c1_2 =
c1->cd(2);
61 h2Dc->
SetTitle(
"3D view of probability amplitude;;");
R__EXTERN TStyle * gStyle
virtual void SetLabelSize(Float_t size=0.04)
Set size of axis labels.
virtual void SetTitle(const char *title)
See GetStatOverflows for more information.
TAxis * GetXaxis()
Get the behaviour adopted by the object about the statoverflows. See EStatOverflows for more informat...
TObject * Clone(const char *newname=0) const
Make a complete copy of the underlying object.
virtual void SetContour(Int_t nlevels, const Double_t *levels=0)
Set the number and values of contour levels.
virtual void Draw(Option_t *option="")
Draw this histogram with options.
2-D histogram with a double per channel (see TH1 documentation)}
2-D histogram with a float per channel (see TH1 documentation)}
Int_t Fill(Double_t)
Invalid Fill method.
To draw Mathematical Formula.
void SetOptStat(Int_t stat=1)
The type of information printed in the histogram statistics box can be selected via the parameter mod...
void SetPalette(Int_t ncolors=kBird, Int_t *colors=0, Float_t alpha=1.)
See TColor::SetPalette.
VecExpr< UnaryOp< Sqrt< T >, VecExpr< A, T, D >, T >, T, D > sqrt(const VecExpr< A, T, D > &rhs)
constexpr Double_t E()
Base of natural log: