Abstract
We study the microphase separation transition of symmetric AB random copolymers in a gel with preferential adsorption of A monomers on the gel strands. It is shown that random copolymers in a gel are an example of the random field model. In the framework of the second Legendre transformation we have calculated the free energy and the phase diagram of the system. There are three different regimes on the phase diagram: the disordered-liquidlike phase, the replica symmetry breaking regime with broken replica symmetry for the two-replica correlation function where monomer composition fluctuations are pinned to the region with higher concentration of the cross links, and the ordered phase with short-range translational order.