Use bash shell arthmetic, remove redundant parameter expansion syntax.