Terahertz Quantum Cascade Amplifiers and Oscillators for Heterodyne Receiver Applications