The two dimensional CP1 model with a theta term is simulated. We compu
te the topological charge distribution P(Q) by employing the ''set met
hod'' and ''trial function method'', which are effective in calculatio
ns for a very wide range of Q and large volume. The distribution P(Q)
exhibits Gaussian behavior in the small beta (inverse coupling constan
t) region and deviates from this in the large beta region. The free en
ergy and its moment are calculated as a function of theta. For small b
eta, the partition function is given by the elliptic theta function, a
nd the distribution of its zeroes on the complex theta plane leads to
a first order phase transition at theta=pi. In the large beta region,
on the other hand, this first order phase transition disappears, but d
efinite conclusion concerning the transition is not reached due to lar
ge errors.