<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def generate_phase_1(dim = 40):
 """ The first step in creating datapoints in the Poirazi & Mel model. This returns a vector of dimension dim, with the last four values set to 1 and the rest drawn from a normal distribution. """

  phase_1 = numpy.random.normal(0, 1, dim)
  for i in range(dim - 4, dim):
    phase_1[i] = 1.0
  return phase_1