def createPattern(c, numDimensions):
 v = numpy.zeros(numDimensions)
 v[c] = ((5 * numpy.random.random()) + 10)
 v[(c + 1)] = numpy.random.random()
 if (c > 0):
  v[(c - 1)] = numpy.random.random()
 return v

def createPattern ( c , numDimensions ) : v = numpy . zeros ( numDimensions ) v [ c ] = ( ( 5 * numpy . random . random ( ) ) + 10 ) v [ ( c + 1 ) ] = numpy . random . random ( ) if ( c > 0 ) : v [ ( c - 1 ) ] = numpy . random . random ( ) return v
create a sparse pattern from category c with the given number of dimensions .