On the Use of Weak Automata for Deciding Linear Arithmetic with Integer and Real