As you already know, to rotate the point (Px, Py) around thew centre, (0, 0) you have the traditional four main rotations:
(Px, Py) rotated 90 degrees counterclockwise gives (-Py, Px)
(Px, Py) rotated 180 degrees gives (-Px, -Py)
(Px, Py) rotated 90 degrees clockwise gives (Py, -Px)
To rotate around a point, you first have to "move" the centre to that point, perform the rotation and then "move" the centre back. To do this, you have to subtract the point of rotation from the point to rotate, rotate it as above, then add the point of rotation back again.
If you want to rotate the point (Px, Py) around the point (Rx, Ry) you get the following:
(Px, Py) rotated 90 degrees counterclockwise around (Rx, Ry) gives (Rx - (Py - Ry), Ry + (Px - Rx))
= (Rx + Ry - Py, -Rx + Ry + Px)
(Px, Py) rotated 180 degrees around (Rx, Ry) gives (Rx - (Px - Rx) , Ry - (Py - Ry)) = (2Rx - Px, 2Ry - Py)
(Px, Py) rotated 90 degrees clockwise around (Rx, Ry) gives (Rx + (Py - Ry), Ry - (Px - Rx)) = (Rx - Ry + Py, Rx + Ry - Px)
To show you one of cases, take (Px, Py) rotated 90 degrees counterclockwise around (Rx, Ry):
1. Subtract the point of rotation (Px, Py) - (Rx, Ry) = (Px - Rx, Py - Ry)
2. Rotate as you normally would, giving (-(Py - Ry), Px - Rx)
3. Add the point of rotation back (-(Py - Ry), Px - Rx) + (Rx, Ry) = (Rx - (Py - Ry), Ry + (Px - Rx)) = (Rx + Ry - Py, -Rx + Ry + Px)