This is a first and secind quadrant DC-DC converter or DC chopper. It's basically a step down chopper whose output voltage depends upon how fast is the switching speed. You can note the change in output voltage by changing the frequency. Just modify the "period" of the clock connected to the relay.
Higher the frequency, lower the output voltage.