Removing a little division in favor of multiplcation
Added r to density function