See how I made collision detection testing a circle against a box, simply for learning purposes. You can change the width and height of the box.
I shared it here for everyone to enjoy and learn a little. Used in my physics engine (Rewrite Physics)