Move serial arithmetic into the plugin