Open source is not the same gratis, so there is non reason to suspect it would be lowest cost for any non-appliance product.
But open source has a free market of maintenance industry, instead of a monopoly, which pushes prices down in general.
For any significant software investment the total cost involves: initial purchase price; hardware; installation and (data) migration; integration with existing (or new) systems; ongoing support and maintenance; training and retraining.
In a lot of cases the latter dominate the initial cost.