update Substitution module, rewrite some equals function of classes in
Logic package