Why both dna nad rna re produced in the 5' to 3' direction
Answers
Briefly, the energy for the formation of the phosphodiester bond comes from the dNTP, which has to be added. dNTP is a nucleotide which has two additional phosphates attached to its 5' end. In order to join the 3'OH group with the phosphate of the next nucleotide, one oxygen has to be removed from this phosphate group. This oxygen is also attached to two extra phosphates, which are also attached to a Mg++. Mg++ pulls up the electrons of the oxygen, which weakens this bond and the so called nucleophilic attack of the oxygen from the 3'OH succeeds, thus forming the phospodiester bond.
If you try to join the dNTP's 3'OH group to the 5' phosphate of the next nucleotide, there won't be enough energy to weaken the bond between the oxygen connected to the 5' phosphorous (the other two phosphates of the dNTP are on the 5' end, not on the 3' end), which makes the nucleophilic attack harder.
This process is actually quite complicated to understand. Any help, don't hesitate to ask.