The story
Coined by an author of Battlestar Galactica (TV series). It was English frack in the original series. Changed to frak in the later series to be a four-letter word. (Compare English fraked (“evil, wicked”) and English frakel (“vile, foul, wretched, worthless”))
Etymology from Wiktionary, CC BY-SA 4.0.