The Mathematics of Phase Retrieval