I think this has everything except some error analysis plots

It would be nice to not use inline functions