Signal transmission and processing for millimeter-wave and terahertz communications