  We analyze infection spreading processes in a system where only a fraction
$p$ of individuals can be affected by disease, while remaining $1-p$
individuals are immune. Such a picture can emerge as a natural consequence of
previously terminated epidemic process or arise in formerly vaccinated
population. To this end, we apply the synchronous cellular automata algorithm
studying stationary states and spatial patterning in SI, SIS and SIR models on
a square lattice with the fraction $p$ of active sites. A concept of "safety
patterns" of susceptible agents surrounded by immune individuals naturally
arises in a proposed system, which plays an important role in the course of
epidemic processes under consideration. Detailed analysis of distribution of
such patterns is given, which in turn determine the fraction of infected agents
in a stationary state $I^*(p)$. Estimates for the threshold values of the basic
reproduction number $R_0^c$ as a function of active agents fraction $p$ are
obtained as well. In particular, our results allow to predict the optimal
fraction of individuals, needed to be vaccinated in advance in order to get the
maximal values of unaffected agents in a course of epidemic process with a
given curing rate.
