Precise Frequency Measurements in Submillimeter and Infrared Region