Text this: Dynamic Spectrum Allocation For Heterogeneous Cognitive Radio Networks With Femtocells