Text this: Optimization and Security Challenges in Smart Power Grids