This covers potions, scrolls, and rituals. The calculation is: (base×2 + wage×time)/chance of success
For example, assuming a formula, a rank 1 potion has a base 250 gp. We double that to 500 gp to take into account the special components. The wage for a fifth-level mage is 400 gp, and it takes 3.5 days (11.66% of a month), so the total wage cost is 46.66 gp.
The mage’s research throw is 12+. If we assume that his workshop is the minimum, he has INT +1, and another +1 bonus swiped from somewhere (such as Magical Engineering), his total chance of success is 55%. 546.66 gp / 0.55 yields 993.94 gp for the average cost per success.
The cost to successfully manufacture the potion, including paying the mage’s wages, is roughly 1,000 gp. A guild might invoke a surcharge on that (20% seems reasonable), but would also guarantee the cost—commissioning a lone mage could cost as low as 550 gp (if he succeeded on the first try), but could easily balloon to 1,100 gp, 1,650 gp, or more if he failed several times in a row.
Without a formula, the cost is more than double×the underlying price is the same, but the % chance of success decreases, so the number of attempts, on average, increases, ballooning the cost.
The expected chance of success by caster level (my numbers, please adjust as desired): 55% for rank 1, 50% for ranks 2 and 3, 60% for rank 4, 75% for rank 5, 90% for rank 6, 70% for rank 7, 65% for rank 8, and 60% for rank 9. All of these include a penalty of 1/2 rank for potions and full rank for rituals, and assume the minimum possible caster level.
Based on the above, the pre-surcharge cost, by underlying spell rank (and rounded off a bit):
1: 1,000 gp. Sales price (ACKS, p. 227) is 1,000 gp, so that works out nicely.
2: 2,200 gp. Sales price is 2,000 gp, which means a mage crafting this item won’t make back the time put into it.
3: 3,300 gp. Sales price 3,000 gp. It only gets worse.
4: 4,600 gp. Sales price 4,000 gp.
5: 9,000 gp. Sales price 5,000 gp.
6: 31,000 gp. Sales price 6,000 gp.
6 divine: 75,000 gp. Sales price 12,000 gp.
7: 92,000 gp. Sales price 14,000 gp.
8: 115,000 gp. Sales price 16,000 gp.
9: 140,000 gp. Sales price 18,000 gp.
It is a waste of a caster’s time to make a potion or scroll higher than rank 1, unless the caster intends to use it. The market price for higher rank potions and scrolls means that the caster makes less than expected wage on average.
This is not unexpected: Alex has stated explicitly that the intent of the magic crafting rules was to make them financially unviable outside of conspicuous consumption, personal use, and the rare moneybags with a specific need who doesn’t care about the market cost.
There are some interesting implications, however. Two that I noticed off-hand:
Harvest—at full price!—is profitable at 3,200 families in a domain and above.
Ravage, on the other hand, is guaranteed to cost the caster more than the damage dealt to the realm (hiring a 14th level cleric to make a one-use item of remove curse, a profligate expense, is only 15,000 gp, plus one month of damage brings that up to a maximum of 40,000 gp, compared to the 75,000 gp it cost to cast ravage). It might make a good statement of intent, but as a financial act of war, it is severely lacking.