Smooth out the carpet over the doorway and feel it with your hands to locate the area where it meets the other type of flooring.
Finish carpet in doorway.
Also tuck the carpet into the ends where the carpet meets the jambs.
Use your utility knife to cut the carpet to the size of the room adding an extra 4 to 6 inches on each side.
You can mill your own transition strips using hardwood lumber and a tablesaw.
Place a straightedge on top of the carpet and cut along the line using a utility knife to trim off the excess.
I use a hook bill to do this.
During the flooring installation laying laminate in a doorway perfectly is not so difficult when you start laying the floor boards at the wall that has the door in it.
Lay your carpet down and make sure it is centered and lays directly against the doorway.
If you nail one down always nail it to the subfloor and not to the pergo flooring.
Just push the edge of the carpet down into the gap all the way across the door and trim any strings off.