Posted 20 Mar 2012 Good Morning, i have a variable [REAL] - for example i will name it "PV" which occasionaly has a sudden changes. This variable - PV - is going to PID controller. I do not want that this "shots" of value were places in my PID loop. So i want to use LPS. For now i try to use LPS block but without success. I read a lot of LPS (there is many theoretical information about it but unfortunateley not enough connected with PLC). The most popular which i find: FV=FV(n-1)+C*(NV(n)-FV(n-1)) FV - filtered variable C - constant, range: <0,1> How can i implement FV(n-1) - previously sample? Many thanks for advice, Suseh Share this post Link to post Share on other sites
Posted 20 Mar 2012 Good Morning, i have a variable [REAL] - for example i will name it "PV" which occasionaly has a sudden changes. This variable - PV - is going to PID controller. I do not want that this "shots" of value were places in my PID loop. So i want to use LPS. For now i try to use LPS block but without success. I read a lot of LPS (there is many theoretical information about it but unfortunateley not enough connected with PLC). The most popular which i find: FV=FV(n-1)+C*(NV(n)-FV(n-1)) FV - filtered variable C - constant, range: <0,1> How can i implement FV(n-1) - previously sample? I use ControlLogix. Many thanks for advice, Suseh Share this post Link to post Share on other sites
Posted 20 Mar 2012 The same but different. FV=FV+C(NV-FV) Where: FV= Filtered value C= constant (range 0-1) The smaller the number the more dampening. NV= New Value Share this post Link to post Share on other sites
Posted 20 Mar 2012 Hi, something like that - see atachement, please. Share this post Link to post Share on other sites
Posted 20 Mar 2012 Just before performing the calculation store the current FV. The stored value is used as FV(n-1) while FV will be replaced as a result of the calculation. Share this post Link to post Share on other sites
Posted 21 Mar 2012 My previoust way does not work. When i very the project i saw that we can not connect output into the other block inputs. I do not fully understand how to save previously sample. Normally i make it in that way - see attachement, please. Any suggestions? Share this post Link to post Share on other sites