stable after lots of tweaking