An image forming apparatus includes a memory which stores test pattern
data. The test pattern data are configured for detecting a density of
image data formed on a photo conductor. The image forming apparatus
includes a laser unit which forms a plurality of test patterns on the
photo conductor by utilizing A plurality of first laser powers based on
test pattern data stored in the memory. The image forming apparatus
includes a detector which illuminates each test pattern formed on the
photo conductor by the plurality of the first laser powers, receives each
light intensity reflected by the test patterns and provides output values
corresponding to each received light intensity. The output values define
a range of output values. The image forming apparatus includes a
controller which compares each output value with a first predetermined
value. The controller determines a laser power to be used based on the
first value, when the first predetermined value falls within the range of
the output values.