Hi everybody. Please, I have to solve a system of equations with respect to a parameter and to take the only solution that is independent of another variable. This is the code. I think i had to better define the parameter k but i don't know how. This is the code
W[r_, l_] := e^2/(2*(l + 1)) - (l + 1)/r
V1[r_, l_] := W[r, l]^2 - D[W[r, l], r]
V2[r_, l_] := W[r, l]^2 + D[W[r, l], r]
a1 := l
a2[a1_] := a1 + k
Solve[D[V2[r, l] - V1[r, a2[a1]], r] == 0 && l >= 0 && r > 0 &&
D[k[a1], a1] == 0, k[a1], Reals]
Thank you for your attention.