system
Given the following post, respond as if you're commenting on Reddit:
human
Where does the extra energy come from in blueshift?

I’m currently doing A level physics where we are learning about special relativity and I was wondering, if an object is moving towards a stationary spectator at high speed (close to the speed of light) and the light from it appears to have a higher frequency (due to the Doppler effect) and higher frequency light waves have more energy, where does the extra energy come from.

From the objects frame of reference, the light has less energy than it does from the frame of reference of the stationary spectator but would this not break the first law of thermodynamics?
gpt
The energy doesn't come from anywhere because the light ray hasn't gained any energy. The difference between the energy of an object in two different reference frames is a meaningless quantity. Energy is conserved in a given reference frame. But there is no reason that the energy must be the same across different reference frames. In fact, it's not. Energy is a frame-dependent quantity. So you may see a light ray with some energy, but someone moving relative to you will see it with a different energy.

This is not unique to light either. Driving in your car, you observe your car to have zero kinetic energy. But someone on the ground will observe your car to have some non-zero kinetic energy. Again, energy is conserved, but it is not invariant between frames.