The crystal structures and phonon spectra of orthorhombic cadmium titanate with the P bnm structure and of its two possible ferroelectrically distorted phases with P bn21 and P b21m space groups were calculated from first principles within the density functional theory. The obtained structural parameters and frequencies of Raman-and infrared-active modes are in good agreement with available experimental data for the P bnm phase. Expansion of the total energy in a Taylor series of two order parameters showed that the ground state of the system corresponds to the P bn21 structure into which the P bnm phase transforms through a second-order phase transition without intermediate phases. A substantial discrepancy between the calculated and experimentally observed lattice distortions and spontaneous polarization in the polar phase was explained by quantum fluctuations as well as by existence of twinning and competing long-period structures.