A method and apparatus for determining a best focus position of an object relative to a reference position of a dark-field optical imaging system, with an effective focusing range up to 10 times of the depth of field of the system. The board holding device includes a framework that has a plurality of vertical rails. To compensate for a voltage imbalance across the capacitors, an imbalance compensation coefficient is derived from the difference in voltages across the first and second capacitors and from the direction of current between the neutral node and the inverter.