question: public static double sampleStandardDeviation ( int size , double sampleVariance ) { double s , Cn ; int n = size ; s = Math . sqrt ( sampleVariance ) ; if ( n > 30 ) { Cn = 1 + 1.0 / ( 4 * ( n - 1 ) ) ; } else { Cn = Math . sqrt ( ( n - 1 ) * 0.5 ) * Gamma . gamma ( ( n - 1 ) * 0.5 ) / Gamma . gamma ( n * 0.5 ) ; } return Cn * s ; }
target:  Returns the sample standard deviation. Ref: R.R. Sokal, F.J. Rohlf, Biometry: the principles and practice of statistics in biological research (W.H. Freeman and Company, New York, 1998, 3rd edition) p. 53.