Move `variable_indices` into the `Variables` object
Use a specific `Constant` class, use `Variable` only as a super class to avoid redundancy.