That's all true, but it still doesn't follow that patents themselves prevent competition on cost. For example, if a non-practicing patent holder licensed their patent to all interested parties, then the licensees must also compete on cost. So far as I can tell, patents were explicitly designed to allow that scenario, among others.