Relation between the repulsion of incompatible and compatible polymers in solution and their degree of mixing in the solid state: the memory effect