Transformer does not covert Ac to DC or DC to Ac it only steps up or steps down the current
4) diagram for 4) connect diodes like this in the form of a quadrilateral
To covert Ac to DC
1) check what your AC input voltage is.
2)Find the voltage and needed to power the components of your electronic device
3)Use a transformer to step down the output from high-voltage AC to low-voltage AC. Electrical current enters the primary coil of the transformer and induces a current in the secondary coil which has fewer coils resulting in a lower voltage.
4)Run the low-voltage AC through a rectifier. A rectifier usually consists of 4 diodes arranged in a quadrilateral shape -- a type called a bridge rectifier. A diode only allows current to pass in 1 direction; the quadrilateral configuration allow 2 diodes to pass the positive half of the current and the other 2 diodes to pass the negative half.
5)Add a large electrolytic capacitor to smooth out the voltage. A capacitor stores an electrical charge for a short time and then releases it slowly. The input from the rectifier resembles a string of humps; the output of the "smoothing capacitor" is a somewhat steady voltage with ripples.
For devices that only need a low current you can create a regulator with a resistor and a zener diode which is designed to break down when a certain voltage is reached allowing current to pass through it. The resistor limits the current.