I need a light speed weapon, obviously a beam weapon, that has an impact energy of 20kt at 150k km.
The question really is, how wide that energy can be spread. A laser doesn't lose any energy in space, so the range is determined by the the distance at which it becomes so unfocussed that it no longer heats up the target.At 150 Million meters distance, a bomb-pumped laser would spread the energy over an area a few kilometres wide. Wether that still does damage, depends on the amount of output energy of the laser, and on the hardness of the target.
For comparison: Let's say we have a divergence of 20 microradians, which gives a nice round figure of 3km diameter of the laser at 150Mm. Which is an area of ~14km². Now, if we want to compare that to a spherical nuke, the distance at which we get the same energy per m² is about 1.05 km. So, the lasing rods produce the same energy/m² at 150Mm, as the unfocused nuke would at 1.05km. At perfect efficiency. At 50% efficiency, it'd be comparable to 1.48km (inverse square law).
I have 20kt of mass and 20kt of cubic volume for the "projector" and as much generating power as I really need to get the job done (in fact, the projector, when fired, generates 46% of the energy of the beam as heat - which is a HUGE problem with my internal consistency and which brings up the next question),
If the laser uses a mirror with a couple of meters in radius to focus, it'll have an effective range well in the lightseconds.
Obviously, heat is generated by the weapon's firing. How do you dump that heat safely so it doesn't affect your ship or friendlies in th near vicinity? I don't know of a single material, including superconductors that can reasonably handle that kind of energy load in a 30-second cycle time (that's the sustained rate-of-fire of the beam weapon without all kinds of fancy tech upgrades).
Yes, heat dumping is a big problem in space. There are basically two way to do it: either use a temporary heat sink. A spaceships superstructure would serve this purpose for example. Basically, just keep absorbing the heat until reaches dangerous levels, then wait for the heat radiator panels to get rid of it. This would means that one can keep firing a laser rapidly, until heat storage capacity is used up, after which the firing rate depends on the capacity of the heat radiators. Or one could break of the engagement, and wait for the radiators to cool the sink down again.
Alternatively, use a chemical laser. The heat is generated in the lasing medium, which could be quickly dumped into space after each shot, to get rid of it before the heat transfers.
Maximum range for really, really, long-ranged beam weapons is 250k km. Rates-of-fire can go up, but that requires a lot of R&D work. Most species have opted for long-ranged projectile "buses" that can be maneuvered after launch and which do not engage until they are within the effective range of beam weapons (most don't actually engage until well inside this range).
A laser with a big mirror will pretty much only be limited in range by targeting accuracy.
In one scene in the WIP I'm working on, an enemy commander launches a salvo of projectile buses early in the opening maneuvers of a battle. He programs the weapons to diverge from his course, fly to a gas giant's vicinity, then "pop up" and intercept the enemy as they close with his own force. The commander's forces are driving ahead with their drives (very bright, very fast) lit full up. The projectile's maneuver requires hours of time (it's space opera so bear with me here). Is this vaguely possible or would the salvo be spotted almost "instantly" (given the realspace time lag between the opposing forces given that the projectile buses are moving at the same speed as the engaginf force, have to make a few course corrections to veer off and then maneuver, etc.)?
Without magical stealth, there's no way no way to hide anything hot in space. A missile drive would definitly be hot. But one solution could be to supercool the projectile bus, and launch it as an inert projectile from a mass driver on a ship. It would be much harder to detect until it engages its own drive. Still not impossible, since a lot of sensors would be focused on the fleet that launches it, but pretty damn hard.
In another scene, a weapon is deployed which, essentially, fires a sustained beam of X-rays, using the heat generated by the weapon's own systems, at a populated world 3 light hours distant. The weapon is supposed to be able to track the planet's path and maneuver itself to sustain a continual bombardment of the enemy world (through a jump point, which passes energy in both directions) until the population on the world is, basically, fried. The weapon's yield is about the same 20kt at the projector, but can an object as big as a planet or even a section of a planet 3 light hours away be reasonably tracked well enough to rast it (as I think about it I think the answer is a definite Yes as we can track the ioneer spacecraft well beyond even that range and send and receive signals)?
Yes, the tracking isn't a problem. The range isn't much of a problem either, the laser mirror would need to be a couple of hundreds, possibly only dozens of meters in radius, which is technically diffcult, but possible. (We build pretty big telescopes today already. And in gravity)
Kilotons would be a useless measure for the weapon though, as it's a measure of energy (joules), while for a continuously functioning weapon, you need power (watts). Not sure what you mean by using the heat generated by the weapons own systems.
Finally, how would you go about deflecting an X-ray laser without wasting a huge amount of resources? Would a "sandcaster" work reasonably well to do it? How about a reflecting sail of some sort?
Reflective sand can work relatively well, though it's more of a temporary measure, it's only better than an actual mirror in that it's easier to deploy.
A mirror should work, depending on the energy of the laser. Since it's supposed to fry a planet over time, i'll assume the energy isn't high enough to vaporize a mirror (or it wouldn't need long to fry the planet), not to mention that deploying a mirror to stop it implies one has the time to do that,
Anyway, any surface reflective to the wavelength will do, a "sail" would just be one that's built to be pretty thin. Reasonable choice, no need to waste material for a thick mirror.