Following its predecessors, Pokemon Go has hidden stats for each Pokemon called Individual Values or IVs for short. For Pokemon Go, these stats are Attack, Defense, and Stamina.
You cannot readily know these stats from the game; however there are now calculators that, with a bit of science, can tell you how good or bad your Pokemon is. The idea here is to find a Pokemon with perfect stats to evolve, rather than evolving the Pokemon with a higher CP. It will produce an overall better Pokemon, but not by a large margin at its final stage:
For example, the base attributes of a Charizard are 212, 182, 156. This would be the "worst" charizard available where all IV's are zero. With max IV's, a Charizard would have 227, 197, 171. Each of these Atk, Def and Stam values for Charizard are only 7-10% better.
(Excerpt from the calculator linked above)
You are seeing different dust requirements due to the Pokemon's hidden level, where a higher level requires more dust and candies to level up further. A Pokemon with better IVs will naturally have a higher CP at a given level, and the difference is much more drastic for un-evolved Pokemon with low base stats.
CP is calculated based on a formula:
CP = (Base Atk + Atk IV) * (Base Def + Def IV)^0.5 * (Base Stam + Stam IV)^0.5 * Lvl(CPScalar)^2 / 10
(Formula from the calculator linked above)
Best Answer
If you look at the arc behind the Pokemon it tells you how close the Pokemon is to is maximum CP. The closer it is to its maximum CP the higher the stardust cost.
The Vaporeon has a higher CP than Jolteon even though it is further from its maximum CP, because the Vaporeon has a higher maximum CP than Jolteon,