some cleaning in checking variable names, conistency in number of
parametrs being passed, and real/integer cleanup.