The ``Maximum Calculation Depth Exceeded'' erro can occur when you reference other cells in calculations. For example, if you have: \texttt{G0 = Some_complicated_expression\\ X0 = G0>2?1:0} Try replacing \texttt{X0}'s contents with \texttt{[ (Some_complicated_expression) > 2]?1:0}. In other words, replace the reference to \texttt{G0} with the actual contents of \texttt{G0}. That might fix your error by removing one level of indirection that LON-CAPA must process in order to compute the result.