collision solver - main part
collision tests