The hybridization schemes for nitrogen and oxygen follow the same guidelines as for carbon. For example, sp3 hybridization for nitrogen results in formation of four equivalent sp3 orbitals, except that this time only three of them contain unpaired electrons, and one of them contains paired electrons. A similar situation holds true for oxygen, which ends up with two of the sp3 orbitals occupied with unpaired electrons, and the other two with paired electrons.
The four sp3 orbitals again orient themselves in 3-D space to be as far apart from each other as possible, but the ideal 109.5o angle becomes distorted because the orbital with two electrons repels the others more strongly than they repel themselves. However the geometry of this arrangement is still fundamentally tetrahedral. When this sp3 hybridized nitrogen bonds to hydrogen, the three unpaired electrons are used for bonding, and the remaining pair remains as nonbonding electrons.
A similar analysis for oxygen should lead to formation of two sp3 orbitals with unpaired electrons, and two with paired electrons. Thus, when sp3 oxygen bonds with hydrogen it forms water, which has a distorted tetrahedral angle, and two pairs of nonbonding electrons in the structure.
Now, what happens when nitrogen or oxygen become sp2 hybridized? The exact same thing that happened with carbon, with some minor changes. Let’s go through the process with oxygen to illustrate how it bonds to carbon to make a class of substances known as carbonyl compounds.
Three equivalent sp2 orbitals have formed, two of them containing paired electrons, and one containing a single unpaired electron. The unhybridized p orbital remains, with an unpaired electron in it. Again, VSEPR theory dictates that the three equivalent sp2 orbitals will acquire a trigonal planar arrangement, while the unhybridized p orbital will remain at right angles to the sp2 orbitals.
When an sp2 oxygen approaches an sp2 carbon for bonding, the process is analogous to that followed by two sp2 carbons that bond to form a “double bond.” Only those orbitals containing unpaired electrons can bond. In this case, the sp2 orbitals from oxygen and carbon that contain unpaired electrons will overlap head to head to form a sigma bond. At the same time, the p orbitals will overlap sideways to form a pi bond. Thus, we have the effective formation of a C=O “double bond.”
Notice that the pi bond in the C=O “double bond” appears distorted, indicating higher electron density around the oxygen than around the carbon. This is because the C=O bond is polar. The more electronegative oxygen atom attracts bonding electrons towards itself more strongly than carbon.
A similar analysis for nitrogen leads to the picture and geometry of a C=N double bond:
Some examples of compounds containing sp2 carbon, nitrogen, and oxygen are shown below. Notice that Lewis and line-angle formulas frequently neglect showing the lone pairs of electrons. Unless there is a specific purpose for showing nonbonding electrons, they are usually omitted and assumed to be present.
By going through an analogous process for sp hybridization of nitrogen and oxygen we can arrive at the molecular structure of species containing carbon-nitrogen and carbon-oxygen triple bonds. Notice that an oxygen containing a triple bond must also carry a positive charge in observance of the rules of covalent bonding.
Also notice that when two sp or sp2 atoms are bonded together to form a double or triple bond, they both must be of the same hybridization. There are some exceptions, but this is true in most common situations.