The signals of glutamate (Glu) and glutamine (Gln) are often significantly overlapped in routine 1 H-MR spectra of human brain in vivo. Selectively probing the signals of Glu and Gln in vivo is very important for the study of the metabolisms in which Glu and Gln are involved. The Glu-/Gln- targeted pulse sequences are developed to selectively probe the signals of Glu and Gln. The core part of the Glu-/Gln- targeted pulse sequences lies on the preparation of the nuclear spin singlet orders (SSOs) of the five-spin systems of Glu and Gln. The optimal control method is used to prepare the SSOs of Glu and Gln with high efficiency. The Glu-/Gln- targeted pulse sequences have been applied on phantoms to selectively probe the signals of Glu and Gln. Moreover, in the in vivo experiments, the signals of Glu and Gln in human brains of healthy subjects have been successfully probed separately. The developed Glu-/Gln- targeted pulse sequences can be used to distinguish the 1 H-MR signals of Glu and Gln in human brains in vivo. The optimal control method provides an effective way to prepare the SSO of a specific spin system with high efficiency and in turn selectively probe the signals of a targeted molecule.