Thanks for your query.
Pain arising from ovaries which are about to ovulate, cannot last for 12 weeks, but maximum for 2- 3 days.
So you need to find out some other causes of your pain.
If trying to conceive, avoid a CT scan
But you can go for ultrasound
of the whole abdomen alongwith pelvis.
Even the abortion
three months back should not be painful now.
If trying to conceive, after an abortion, you should avoid it for atleast 3 months, take folic acid
and keep yourself healthy and fit.
ALso consult a gynecologist, specializing in Subfertililty after that, so that you do not leave out any investigation / cause for your prior miscarriage