Random.nextGaussian() is supposed to give random no.s with mean 0 and std deviation 1. Many no.s it generated are outside range of [-1,+1]. how can i set so that it gives n
A normal distribution gives a non-zero (but "becoming extremely small") probability of seeing values outside [-1, +1] whatever variance you give - you're just squishing the curve, effectively.
You could use a small variance and then just run the results through a map which cropped anything less than -1 to -1, and anything greater than 1 to 1, but it wouldn't (strictly speaking) be a normal distribution any more.
What do you need this distribution for, out of interest?