fixed a bug in InflectionGrid.__str__