Today I spent longer than I'd like to admit figuring out how to write a Bourne shell IF statement that tests a FLOAT value before executing a block of statements. Here's the solution I found, which invokes bc. Hope this will come in handy for someone:
value = [some floating point number]
testval = [some floating point number]
if [ `echo "if($value > $testval) 1; if($value <= $testval) 0" | bc` -eq 1 ]
then
body of if statement
fi