We report on a novel approach to the realization of nematic liquid-crystal (LC) phase correctors to form spherical and cylindrical wave fronts. A LC cell with a distributed reactive electrical impedance was driven by an ac voltage applied to the cell boundary to yield the desired spatial distribution of the refractive index. The two-dimensional function of the phase delay introduced into the light beam depends on the frequency of the ac control voltage, the geometry of the boundary electrode surrounding the LC cell, and the electrical parameters of the cell. We realized a cylindrical adaptive lens with a clear aperture of 15 mm x 4mm and a spherical adaptive lens with circular aperture of 6.5 mm. Both devices are capable of focusing collimated light in the range infinity...0.5 m.