Calculates the square root of a positive number and returns the result as a double.