A half wave rectifier is a circuit that converts an AC voltage to a pulsating DC voltage by allowing only one half of the AC waveform to pass through. Here is how you can build a half wave rectifier using mentioned components.
When the AC voltage is applied to the transformer, the secondary winding produces a voltage that oscillates between positive and negative peaks. The diode allows only the positive peaks to pass through and the negative runs through negative reference. This results in a pulsating DC voltage that charges the capacitor. The capacitor smooths out the voltage, reducing the ripple. The resistor limits the current flowing through the LED, and the LED illuminates when the voltage across it is sufficient.