Just wanna know how and why

Kiah
Back in July 2016 I went to the ER for bleeding (7weeks 5days pregnant). They ran a bunch of test and everything came back fine. They did an ultrasound and my baby's heartbeat was 146bpm (normal). They just ended up telling me that bleeding was normal and if it got worst to come back. The next day I ended up having a miscarriage. When I get to my check up to make sure I didn't still have the baby or anything still in me they just told me a miscarriage in the 1st trimester is normal...I don't understand how it happend the day after they said everything was fine and my babies heartbeat was normal