solver bugs fixed