A bit more progress on adding functionals and re-organizing as I go.