But if I developed a really effective method of teaching the course, could the university compel me to not accept employment at another university for a few years, upon resignation or retirement?
The answer is: it depends. (Is it ever not it depends?) Corporations, particularly corporations dealing in trade secrets, have an interest in keeping their creative employees from decamping to competitors and selling those secrets. Thus the non-compete clause.
Noncompete clauses usually ban employees from going to work for a competitor or starting a competing firm for some pre-determined period of time. Such agreements have been around since at least the 1400s, with proponents defending them as a way to encourage employers to develop new technologies and invest in worker training (because they have less reason to fear losing their secrets and their valuable employees to a competitor) and critics depicting them as an unfair restraint of trade that hurts workers.Like everything else in political economy, it comes with tradeoffs. The buyer of a business is going to insist on protection from the seller taking the proceeds from sale and going back into the same business in competition with the buyer. On the other hand, the secret of agglomeration economies creating clusters of innovation is the presence of opportunities for ideas to have sex. And the article suggests that Californian treatment of non-compete clauses allowed the ideas to be in freer intercourse with one another than was the case in Massachusetts, where you'd think all those universities encircled by Route 128 would have been perfect for a spiky world. (Make whatever pop-culture comparisons you want.) Thus, the companies that protect their proprietary knowledge more aggressively damage their futures.. "They make it harder to create another Silicon Valley."