Problem
Using Mathematica's Solve
operator can sometimes lead to an output involving a positive and negative root (say when solving for a variable such as N^2
.
What Is Happening
Here I simply have a defined function Radial
followed by implementation (Solve
) of that function.
Radial[n_,l_,r_]:= LaguerreL[n-l-1, 2*l+1, ((2*Z)*r)/(n*a)] * ((Z*r)/(n*a))^l Exp[-((Z*r)/(n*a))];
Solve[Integrate[
N^2 Radial[1,0,r] r^2,
{r,0,\[Infinity]},
Assumptions -> {Z>0,a>0,{Z,a},Reals}
]== 1,N]
Out[1]= {{N -> -(Z^(3/2)/(Sqrt[2] a^(3/2)))}, {N -> Z^(3/2)/(Sqrt[2] a^(3/2))}}
Mathematica is kind enough to give me both positive and negative roots.
What I Want
I would like to suppress the negative root, leaving only the positive root solution, i.e. {N -> (2 Z^(3/2))/a^(3/2)}
What I've Tried
Here I include a couple things I have tried (some suggested by the kind people in chat).
- Inserting
N>=0
intoAssumptions
: Resulted in two roots. - Inserting
N>=0
andN
into theReals
section. : Resulted in two roots. - Inserting
&& N>0
following the==1
combined with all possible permutations of Tries (1) and (2). : Resulted in no answer given (nor any errors).
Hopefully there is a simple way of fixing this (and not some convoluted input syntax). However, for the benefit of the community, any suggestion is welcomed. For my particular case, the simpler the better.