def R_nl(n, l, r, Z=1):
 (n, l, r, Z) = (S(n), S(l), S(r), S(Z))
 n_r = ((n - l) - 1)
 a = (1 / Z)
 r0 = ((2 * r) / (n * a))
 C = sqrt(((((S(2) / (n * a)) ** 3) * factorial(n_r)) / ((2 * n) * factorial((n + l)))))
 return (((C * (r0 ** l)) * assoc_laguerre(n_r, ((2 * l) + 1), r0).expand()) * exp(((- r0) / 2)))

def R_nl ( n , l , r , Z = 1 ) : ( n , l , r , Z ) = ( S ( n ) , S ( l ) , S ( r ) , S ( Z ) ) n_r = ( ( n - l ) - 1 ) a = ( 1 / Z ) r0 = ( ( 2 * r ) / ( n * a ) ) C = sqrt ( ( ( ( ( S ( 2 ) / ( n * a ) ) ** 3 ) * factorial ( n_r ) ) / ( ( 2 * n ) * factorial ( ( n + l ) ) ) ) ) return ( ( ( C * ( r0 ** l ) ) * assoc_laguerre ( n_r , ( ( 2 * l ) + 1 ) , r0 ) . expand ( ) ) * exp ( ( ( - r0 ) / 2 ) ) )
returns the hydrogen radial wavefunction r_{nl} .