Soreness is not indicative of low energy density.
Soreness is a common physiological process, indicating local inflammation, your muscle worked more than it is used to... That's a normal process.
The best medicine is to train more. The more adapted you are, less you suffer with soreness.
However, you can cycle calories and carbs between training days.
Ex: On leg day you're going to eat Xg more carbs, so it will be 4Xcalories more, but you train leg 2*4X a week, so it'll will be 8X calories more a week. If you want to maintain or to lose weight, you will need to subtract this 8X calories from the other days. If you want to gain weight, just add the calories.
Sent from my ASUS_Z012DC using Tapatalk