Not sure if there are tools that will get you the result directly in an easily comprehensible form, but if not, the procedure to do so "manually" would go as follows (I'm considering you're actually coming back to the departure city):
Find out the cheapest fare for the whole trip. You can use tools such as ExpertFlyer to look up fares.
Note that in you case, it will need to be a fare from your origin to one of the two "destinations", which allows routing via the other destination, as well as at least one stopover. This will quickly eliminate a lot of the cheaper fares. You may also have a few other rules (validity dates, min/max duration...) that may further restrict which fares are applicable.
Once you have found the valid fares, check out the associated booking class for each (the first letter of the fare code).
For each of the flights, check for availability in those classes (for that airline) over a range of dates. Again, tools such as
Expertflyer will let you do this. Once you've found a sequence of flights available with the right class, you should be able to book the whole trip on those dates. If there are no availabilities, start again with the next higher fare.
Note that you may also want to consider booking the flights independently (or a combination of two tickets). In some cases, you might even save by taking a series of return flights even if you don't use the return.
All in all, quite a bit of work indeed.