wow you are crazy! This is genuinely impressive - thank you for putting so much work into it. The table is also very useful for me as a balance diagnostic. At the moment, city supply and demand preferences are fairly stable, so the economy can indeed be mapped and optimised. but in future versions I plan to make profitability less predictable through seasons, wars, festivals, market saturation and other world events. Your table should still remain useful as a baseline, but the best route will not always stay the best route
Viewing post in Medieval Merchant Simulator comments
Thanks! I'm glad you find it useful. It may sound weird but this is me being lazy. I didn't want to calculate profitability each and every time I decided to trade, so I figured it'd be easier to do this. I added the pseudo-formula above, which is fairly simple as you'll see.
For the sake of precision, there's an implicit assumption that a "Supplies_1 + Look_for_2" profit is equal to two "Supplies_1 <> Supplies_2" or "Looking_for_1 <> Looking_for_2" profits. It might need some weighing to properly adjust it (just a single parameter), but I haven't paid much attention to that proportion yet.
My goal was to find some circular trade route, but I think it may need to be done programmatically. Or maybe with some matrices product... Something I never thought I'd need.
Edit: Actually, I realized it's an ant colony optimization sort of problem, which is solved programmatically.