Performance Analysis and Formal Verification of Cognitive Wireless Networks