Normalize lira smtaffineterm to int if possible.

Renamed toReal in typecast, since it is also used for integer cast.
Convert real SMTAffineTerm to int in createEqualityProxy, if all coefficients
are of type int.