Text this: Optimal Linear Controller Design for Periodic Inputs