3 ms·
All physical systems have time delay, but software doesn’t necessarily. I bumped into PID controllers writing software for video games where I had the option to
by dahart 3y ago
All physical systems have time delay, but software doesn’t necessarily. I bumped into PID controllers writing software for video games where I had the option to not have a time delay in the system, if I wanted to do something less physically realistic. In a game, you can (and I often did) use a proportional-only controller for certain things. Then I got surprised when that didn’t work, after a time delay was introduced. I mainly called out the time delay because the delay is what causes the problem that needs solving, so it seems reasonable and important to state. But I wouldn’t argue with anyone who said the delay part seems obvious. ;)
- entropie 3y ago> but software doesn’t necessarily. Is this true? I mean the delay may be inconsiderable but there is a delay, right?
- dahart 3y agoIt depends entirely on what you’re doing in software, but yes it’s true that you don’t always have a delay. Your simulation doesn’t have to involve time at all, so that’s one way you might not have delays. But if you do have a simulation involving time, and your update of some entity in the system can change it’s behavior instantaneously, then there’s no delay. Like I said, in a game you can choose whether your AI has to follow physics or not. It is easy to make a non-physical car that can turn instantaneously. When you do that, a P-controller works just fine. As soon as you make it follow physics, which adds time delay between input and response, then you have to have the I & D terms, otherwise your car will be unstable. In video games it’s very common for cameras to try to follow something (like your avatar) smoothly using a P controller, they are a good example of a very common bit of software that has no delay - they can follow and turn without being subject to physics, and thus they generally don’t need the I & D terms of a PID controller.
- bgnn 3y agonot necessarily. feedforward path delay can be zero. typical mistake done while modeling feedback systems in SW.