The math.h thing is for when you are writing a program in C. If you are using shell script, you will need to use some external program, as most shells do not include a built-in square root command.
bc is probably the best bet here as it is a very small program (so it is quicker to invoke than other programs), and it can give you a lot of precision, or as little as you want.
bc reads from standard input, so you can echo an expression to evaluate like these examples:
Code:
result1=$(echo "3 + 5" | bc -l)
result2=$(echo "sqrt(3)" | bc -l)