simplified as much as possible.