1. A pattern forming apparatus comprising: a sequence generating device which generates a sequence such that vectors expressed by sub-sequences have different directions for the sub-sequence constituting the generated sequence, the sub-sequence having a predetermined length, the sequence being formed by terms having M-value numeric values; an image data generating device which generates image data by converting each numeric value of the sequence into a gray-level value according to each numeric value, the sequence being generated by the sequence generating device; and an exposure device which performs exposure according to the image data generated by the image data generating device.