You can buy a new main fuse at the parts department of your brand of car's dealership. It may be helpful to note the ampere rating on that fuse, and the fuse color; as these fuses usually come in different ratings.
Once you see the new one; you'll be able to tell how to get the old one out. It may just require pulling it with a big pair of pliers; but it might also involve loosening or removing some screws.
If fortune was not with you when you reversed the cable clamp orientation; the alternator diodes may have been destroyed by this incident. This often happens when jumper cables are reversed. When the connections of either the battery cables or jumper cables are reversed; the alternator effectively becomes a dead short across the battery. This will permit a massive amount of current to flow through the battery cables and the alternator wiring harness. If it were not for the protective fuse; the wiring harness would have probably melted and started an underhood fire.
If the alternator diodes are shorted; as soon as you install a new fuse, it will blow out. So here's an easy test you can make to see whether the alternator is fried, and this save the cost and hassle of having to buy a second new fuse: Locate the heavy gauge power cable connection to the alternator. If the power terminal on the alternator is covered by a rubber boot; fold or pull the boot back far enough to expose the terminal bolt and nut. If there is enough room behind the alternator to touch the terminal with a jumper cable clamp, you can proceed; otherwise, you'll need a 12 gauge or heavier jumper wire with alligator clips on the ends. Connect one end of the jumper cable or wire to the battery positive terminal (making sure the other end of that cable does not touch any metal object); and then very briefly tap the other end of that jumper cable (the end with the same color clamp) or jumper wire to the alternator power terminal. Be sure to not touch the metal body of the alternator with the cable clamp. If there is a big spark when you tap the power terminal; the alternator is toast (and will have to be replaced). But if there is no spark when you touch the terminal; then you can consider yourself very lucky: The alternator should still work; and it will be OK to install the new fuse. I recommend disconnecting the battery ground (minus) cable before replacing the fuse; just to prevent any unintended connections between the battery and ground.
If you find that the alternator must be replaced; I strongly recommend only buying a replacement at a NAPA parts store. All too many popular parts stores carry alternators which has been poorly remanufactured, and inadequately tested. The length of the guarantee will offer little comfort if you find the part keeps failing. NAPA is the one store which still maintains professional grade quality standards on their remanufactured electrical parts.