should contain most of the work at least for einfinf