Star Wars Power Generation
The Galactic Republic and Galactic Empire use a variety of power generators. The most powerful of these generators is the hypermatter reactor. Information on how these reactors work is scarce, but how much power they can produce is easier to calculate.
The most extreme example of a hypermatter reactor's power-generating capacity is the Death Star. A single shot from the Death Star's superlaser unleashes 1E38 Joules of energy; more than the Sun radiates in 8,000 years. The Death Star's hypermatter reactor is capable of recharging this weapon for another planet-destroying blast within a day, indicating that it produces power on the order of 1E33 Watts, meaning it produces more energy every second than the Sun radiates in a month.
Star Trek Power Generation
The United Federation of Planets and most other Star Trek civilizations use nuclear fusion and matter-antimatter annihilation to power their starships. The primary fusion power supply is the impulse engine, and the primary matter-antimatter reactor is the warp core.
The Romulan Empire does not use matter-antimatter reactors on its starships. Instead, they collect energy from the decay of an artificial singularity.
The actual power produced by Federation power sources is unclear. Commander Riker once stated that the entire Enterprise could not generate a terawatt of power, but subsequent events have suggested greater power generation. The ship's warp core is known to have undergone some modifications and upgrades following Riker's statement, and the chief engineer subsequently said it could generate power "into the terawatt range".
At the other extreme, Commander Data once said the ship's reactor was generating "12.75 billion gigawatts per (second)". This is a nonsensical statement, since watts per second is not a unit of power. The word "second" was actually cut off by an alarm in the episode, but it does appear in the script, so we have a reasonable idea of what Data's next word would have been. To add to the inaccuracy, Data was responding to the amount of energy in the warp core, which should be in joules or watts multiplied by time, not watts divided by anything.
Despite the officers' statements, a plan to use the ship to stabilize the orbit of a small moon suggests considerably more than one terawatt of power generation, as much as 21,000 TW. Attempting to move this moon pushed the Enterprise to its limits, but it would have been a trivial task if the ship could have applied even a small fraction of 12.75 billion gigawatts (12.75 million terawatts) to the task.