Linear equation and expression evaluation