I'd like to see an example of when you think PID is an ideal choice? I've never found a real usecase. Whenever I've hacked one into anything, I've quickly replaced it with something simpler and better (thermostats being the most obvious example).
I'd like to see an example of when you think PID is an ideal choice? I've never found a real usecase. Whenever I've hacked one into anything, I've quickly replaced it with something simpler and better (thermostats being the most obvious example).
I did not claim PID to be optimal. It was your claim that you found ad hoc methods to be more optimal (whatever that is supposed to mean). Surely you would be able to give examples and in what quantitative way you have found them "better", or "more optimal" and in what ways you have found PID to be mathematically complex.
Simplicity is hard to quantify, but it's one of the most important properties of robust and reliable systems. That's not vapid at all: that's engineering.
I would be surprised if missile guidance, drone guidance use bang bang. My hunch would be they use something more sophisticated than PID. Same for something more banal like cruise control in a car set to some cruising speed.
> If thermostats are indeed better why doesnt chemical industry use non-PID to control the temperature of the reagents. PID seems to rule the roost there.
For the same reason they still use constant speed compressors: it's how it has been done forever, it's good enough, and all the equipment still works. We know better now, we build new ones with VFDs.
I'm not saying "let's tear down everything using PID and rewrite it", it obviously works. But if you're writing new code using PID, you're probably wrong.
Bang-bangs are just not smooth enough and does not give enough control over tracking. With tuning, PID can at least perform within the desired smoothness envelop. PID have been surprisingly robust even if the gains are set far from optimal. There are satisfactory tools and best practices for tuning PIDs.
A stuttering car on bang bang cruise control will certainly not be a pleasant ride.
Bang-bangs cannot do the job where you have a low inertia, low damping system that cannot tolerate jerks. PID introduces exactly those properties, inertia and damping, but through the controller.
> Bang-bangs cannot do the job where you have a low inertia, low damping system that cannot tolerate jerks. PID simulates exactly those properties, inertia and damping, but through the controller.
This is exactly what I'm saying: the control theory should model the actual system being controlled. Most uses I have seen of PID in the software industry do not, and consequently have to be hacked to death and are very sensitive to tuning. Old industrial stuff can be like that too sometimes.
Does datacenter load have analogous properties? Absolutely not. That's my point: it's a bad usecase for PID.
> Bang-bangs are just not smooth enough and does not give enough control over tracking
Well, in fairness it could if the timestep could be made arbitrarily small. But in practice, yes, this obviously wouldn't work.
I agree. This would essentially be pulse width modulation or control. You need sufficient inertia though, and damping that the vibration does not have any adverse effect.
> Does datacenter load have analogous properties? Absolutely not. That's my point: it's a bad usecase for PID.
I am not knowledgeable about that but I would presume there would be inertia like effects, delays. Bringing lots of servers up simultaneously may choke a contended shared resource leading to damping. In such cases one cant boot up too many servers too fast. Jerks might be better tolerated, except perhaps in high frequency trading scenario.
Sure, you can model it like that. But I can actually go measure all the physical properties of the car and calculate a tuning that will work for cruise control, because the car follows known physical laws (within the limits of my ability to measure things).
I can't "weigh" the datacenter. I must to some extent observe the system and empirically derive tuning. That tuning is basically overfitting PID to second and higher order effects in the system without taking the time to actually understand the root of them.
Can that work? Sure. That doesn't change the fact that, IMHO, there is almost always a better way.
This is probably more contraversial... but personally, I'd rather have a hacky ad hoc approach than overfit PID, because the former is so much easier to debug and understand.
Current best method for solving ODEs is PI control. (At least, when I checked it a few years ago.)