DSPRelated.com
Forums

Forgetting factor for discrete linear kalman filter

Started by adrian116 April 7, 2009
Dear all, 

       I am doing a final year project to estimate the power consumption
of a chiller plant. I have built a basic model by using Kalman Filter and
get a result with some percent of error.

For my model, I used a moving windows say 60 sets of data, then calculated
the parameters to be estimated from these data sets. Use these a,b,c,d,e
and the measurement of 61set of data to estimation the power at t=61. So
a,b,c,d,e calculated from 2-61sets of data sets and measurement of 62 set
of data are used to determine the power at t=62 and so on.

For this case, I need to handle all 60 sets in the moving windows each
time. It seems strange and time consumption.

My teacher asked me try to introduce forgetting factor to my model. But i
have searched many material in the web and didn't find any help. Do you
guys have any idea?

Thank You.


On Apr 7, 7:58&#4294967295;am, "adrian116" <adrianchang...@hotmail.com> wrote:
> Dear all, > > &#4294967295; &#4294967295; &#4294967295; &#4294967295;I am doing a final year project to estimate the power consumption > of a chiller plant. I have built a basic model by using Kalman Filter and > get a result with some percent of error. > > For my model, I used a moving windows say 60 sets of data, then calculated > the parameters to be estimated from these data sets. Use these a,b,c,d,e > and the measurement of 61set of data to estimation the power at t=61. So > a,b,c,d,e calculated from 2-61sets of data sets and measurement of 62 set > of data are used to determine the power at t=62 and so on. > > For this case, I need to handle all 60 sets in the moving windows each > time. It seems strange and time consumption. > > My teacher asked me try to introduce forgetting factor to my model. But i > have searched many material in the web and didn't find any help. Do you > guys have any idea? > > Thank You.
One possibility is to update the covariance estimate in the following manner R(n) = (1-lambda)R(n-1) + lambda * x*x' where lambda is a scalar and x is a vector and x' is the transpose of x. Hope that helps. Cheers, David
On Tue, 07 Apr 2009 06:58:30 -0500, adrian116 wrote:

> Dear all, > > I am doing a final year project to estimate the power consumption > of a chiller plant. I have built a basic model by using Kalman Filter > and get a result with some percent of error. > > For my model, I used a moving windows say 60 sets of data, then > calculated the parameters to be estimated from these data sets. Use > these a,b,c,d,e and the measurement of 61set of data to estimation the > power at t=61. So a,b,c,d,e calculated from 2-61sets of data sets and > measurement of 62 set of data are used to determine the power at t=62 > and so on. > > For this case, I need to handle all 60 sets in the moving windows each > time. It seems strange and time consumption. > > My teacher asked me try to introduce forgetting factor to my model. But > i have searched many material in the web and didn't find any help. Do > you guys have any idea? > > Thank You.
The Kalman filter that I know doesn't involve 'moving windows'; it updates it's state and covariances each iteration, and only requires that you save state and covariance. How does what you're doing compare to the construction of the Kalman filter in Wikipedia? One quick way to introduce a forgetting factor into a Kalman filter (if it's the one _I_ know, at least!) is to model your system with extra process noise. This will make the filter pay more attention to it's feedback and less to prior state estimates. If you have time, read a book on Kalman filtering. I like Dan Simon's "Optimal State Estimation" -- it's a very good text on Kalman filtering. -- http://www.wescottdesign.com
>On Apr 7, 7:58=A0am, "adrian116" <adrianchang...@hotmail.com> wrote: >> Dear all, >> >> =A0 =A0 =A0 =A0I am doing a final year project to estimate the power
cons=
>umption >> of a chiller plant. I have built a basic model by using Kalman Filter
and
>> get a result with some percent of error. >> >> For my model, I used a moving windows say 60 sets of data, then
calculate=
>d >> the parameters to be estimated from these data sets. Use these
a,b,c,d,e
>> and the measurement of 61set of data to estimation the power at t=3D61.
S=
>o >> a,b,c,d,e calculated from 2-61sets of data sets and measurement of 62
set
>> of data are used to determine the power at t=3D62 and so on. >> >> For this case, I need to handle all 60 sets in the moving windows each >> time. It seems strange and time consumption. >> >> My teacher asked me try to introduce forgetting factor to my model. But
i
>> have searched many material in the web and didn't find any help. Do
you
>> guys have any idea? >> >> Thank You. > >One possibility is to update the covariance estimate in the following >manner >R(n) =3D (1-lambda)R(n-1) + lambda * x*x' > >where lambda is a scalar and x is a vector and x' is the transpose of >x. > >Hope that helps. > >Cheers, >David >
Thanks David, what is the 3D in the equation? Is the x in the equation the state vector?
>On Tue, 07 Apr 2009 06:58:30 -0500, adrian116 wrote: > >> Dear all, >> >> I am doing a final year project to estimate the power
consumption
>> of a chiller plant. I have built a basic model by using Kalman Filter >> and get a result with some percent of error. >> >> For my model, I used a moving windows say 60 sets of data, then >> calculated the parameters to be estimated from these data sets. Use >> these a,b,c,d,e and the measurement of 61set of data to estimation the >> power at t=61. So a,b,c,d,e calculated from 2-61sets of data sets and >> measurement of 62 set of data are used to determine the power at t=62 >> and so on. >> >> For this case, I need to handle all 60 sets in the moving windows each >> time. It seems strange and time consumption. >> >> My teacher asked me try to introduce forgetting factor to my model.
But
>> i have searched many material in the web and didn't find any help. Do >> you guys have any idea? >> >> Thank You. > >The Kalman filter that I know doesn't involve 'moving windows'; it >updates it's state and covariances each iteration, and only requires that
>you save state and covariance. How does what you're doing compare to the
>construction of the Kalman filter in Wikipedia? > >One quick way to introduce a forgetting factor into a Kalman filter (if >it's the one _I_ know, at least!) is to model your system with extra >process noise. This will make the filter pay more attention to it's >feedback and less to prior state estimates. > >If you have time, read a book on Kalman filtering. I like Dan Simon's >"Optimal State Estimation" -- it's a very good text on Kalman filtering. > >-- >http://www.wescottdesign.com >
Thank for your reply. Actually i don't have much time to go through all the concept of kalman filter. Do you mind to tell me which part of the book is critical for my application?
On Tue, 07 Apr 2009 09:59:06 -0500, "adrian116"
<adrianchang116@hotmail.com> wrote:
>>One possibility is to update the covariance estimate in the following >>manner >>R(n) =3D (1-lambda)R(n-1) + lambda * x*x' >> >>where lambda is a scalar and x is a vector and x' is the transpose of >>x. >> >>Hope that helps. >> >>Cheers, >>David >> > > >Thanks David, what is the 3D in the equation?
There is no 3D in the equation. That's your news client adding some markup to the text in the post. Muzaffer Kal DSPIA INC. ASIC/FPGA Design Services http://www.dspia.com
On Tue, 07 Apr 2009 06:58:30 -0500, "adrian116"
<adrianchang116@hotmail.com> wrote:

>Dear all, > > I am doing a final year project to estimate the power consumption >of a chiller plant. I have built a basic model by using Kalman Filter and >get a result with some percent of error. > >For my model, I used a moving windows say 60 sets of data, then calculated >the parameters to be estimated from these data sets. Use these a,b,c,d,e >and the measurement of 61set of data to estimation the power at t=61. So >a,b,c,d,e calculated from 2-61sets of data sets and measurement of 62 set >of data are used to determine the power at t=62 and so on. > >For this case, I need to handle all 60 sets in the moving windows each >time. It seems strange and time consumption. > >My teacher asked me try to introduce forgetting factor to my model. But i >have searched many material in the web and didn't find any help. Do you >guys have any idea? > >Thank You. >
Normally Kalman filters run on continuous streams of data and not windows of it. To simulate a forgetting forget you can increase the system noise variance so that the kalman filter depends more on the measurement and less on its own estimate. Muzaffer Kal DSPIA INC. ASIC/FPGA Design Services http://www.dspia.com
On Tue, 07 Apr 2009 10:02:22 -0500, adrian116 wrote:

>>On Tue, 07 Apr 2009 06:58:30 -0500, adrian116 wrote: >> >>> Dear all, >>> >>> I am doing a final year project to estimate the power > consumption >>> of a chiller plant. I have built a basic model by using Kalman Filter >>> and get a result with some percent of error. >>> >>> For my model, I used a moving windows say 60 sets of data, then >>> calculated the parameters to be estimated from these data sets. Use >>> these a,b,c,d,e and the measurement of 61set of data to estimation the >>> power at t=61. So a,b,c,d,e calculated from 2-61sets of data sets and >>> measurement of 62 set of data are used to determine the power at t=62 >>> and so on. >>> >>> For this case, I need to handle all 60 sets in the moving windows each >>> time. It seems strange and time consumption. >>> >>> My teacher asked me try to introduce forgetting factor to my model. > But >>> i have searched many material in the web and didn't find any help. Do >>> you guys have any idea? >>> >>> Thank You. >> >>The Kalman filter that I know doesn't involve 'moving windows'; it >>updates it's state and covariances each iteration, and only requires >>that > >>you save state and covariance. How does what you're doing compare to >>the > >>construction of the Kalman filter in Wikipedia? >> >>One quick way to introduce a forgetting factor into a Kalman filter (if >>it's the one _I_ know, at least!) is to model your system with extra >>process noise. This will make the filter pay more attention to it's >>feedback and less to prior state estimates. >> >>If you have time, read a book on Kalman filtering. I like Dan Simon's >>"Optimal State Estimation" -- it's a very good text on Kalman filtering. >> >>-- >>http://www.wescottdesign.com >> >> > Thank for your reply. > > Actually i don't have much time to go through all the concept of kalman > filter. Do you mind to tell me which part of the book is critical for my > application?
Since my experience with Kalman filters includes no moving windows, unless you're doing some serious smoothing, all I can do is point you to the book. You may want to answer my question about how what you're doing compares to the Wikipedia article -- you don't seem to be realizing a standard Kalman filter, hence any questions you ask should have a _lot_ more background on what you really are doing. -- http://www.wescottdesign.com
On Apr 7, 11:58&#4294967295;pm, "adrian116" <adrianchang...@hotmail.com> wrote:
> Dear all, > > &#4294967295; &#4294967295; &#4294967295; &#4294967295;I am doing a final year project to estimate the power consumption > of a chiller plant. I have built a basic model by using Kalman Filter and > get a result with some percent of error. > > For my model, I used a moving windows say 60 sets of data, then calculated > the parameters to be estimated from these data sets. Use these a,b,c,d,e > and the measurement of 61set of data to estimation the power at t=61. So > a,b,c,d,e calculated from 2-61sets of data sets and measurement of 62 set > of data are used to determine the power at t=62 and so on. > > For this case, I need to handle all 60 sets in the moving windows each > time. It seems strange and time consumption. > > My teacher asked me try to introduce forgetting factor to my model. But i > have searched many material in the web and didn't find any help. Do you > guys have any idea? > > Thank You.
For get ordinary Kalman estimators and use H Infinity estimators - more robust -
On 2009-04-07, Muzaffer Kal <kal@dspia.com> wrote:
> On Tue, 07 Apr 2009 09:59:06 -0500, "adrian116" ><adrianchang116@hotmail.com> wrote: >>>One possibility is to update the covariance estimate in the following >>>manner >>>R(n) =3D (1-lambda)R(n-1) + lambda * x*x' >>> >> >>Thanks David, what is the 3D in the equation? > > There is no 3D in the equation. That's your news client adding some > markup to the text in the post.
Actually it's *your* news client doign MIME encoding and his client displaying plain text. The equals sign is the escape character, so to encode it it uses the hex value of the equal sign, 3D. So if you ever see '= 3 D' (but with no spaces) then the original text had just =. -- Ben Jackson AD7GD <ben@ben.com> http://www.ben.com/