in the beta, the only place to get gems (whether cash or gold) was trough the trading post (Anet store). They apparently have a formula that varies the (gold) price per gem depending on the demand and availability.
The devs indicated that they will have a set amount coming into the economy so this will make the gold costs of gems (exchange rate - gold -> gems or gems -> gold) constantly fluctuate.
The cash option is set, however.
»
wiki.guildwars2.com/wiki/Gem