V.Z.Panfilov. Grammar and logic