code: def GenerateGaussianNoise(PSD):
      
  
      Noise = np.zeros((N_fd),complex)
      # Generate noise from PSD 
      Real = np.random.randn(N_fd)*np.sqrt(PSD/(4.*dF))
      Imag = np.random.randn(N_fd)*np.sqrt(PSD/(4.*dF))
      Noise = Real + 1j*Imag
  
      return Noise
docs: GenerateGaussianNoise - function to generate Fourier domain Gaussian 
          detector noise colored by a detector PSD.
          
          PSD - Noise power spectral density with which to color the Gaussian
          noise.
  
          Returns Noise - complex Fourier domain Gaussian detector noise colored 
                          by a detector PSD.
  
          Sarah Gossan 2012. Last updated 02/18/14.