smooth-endpoint version of gaussian