There are two possibilities- firstly, you could be having disturbed cycles as is usual sometimes after a miscarriage; or a threatened abortion
. You can perform a blood test
and follow it up with a sonogram in consultation with your doctor as your spotting is persisting along with pain. Do not lift weights, take bed rest
and avoid intercourse until your condition is diagnosed. Take care.