Optimal energy-efficient power control for cognitive radio based on static and dynamic features of primary users