complete the gaussian function, add test