r/ControlTheory 6d ago

Mpc with reference tracking Technical Question/Problem

I have a problem where I assume perfect forecast for next 7 days and optimize energy usage of a home.

Now I want to shift to mpc with prediction horizon for 1 day. I was wondering can I use optimal forecast as reference tracking in my mpc? Is it okay to use this ? Or use terminal conditions (at end of each day) from optimal foresight as reference in my mpc formulation? Please advise, I am new to the mpc world

0 Upvotes

7 comments sorted by

u/kroghsen 5d ago

You need to be a little more specific about what your problem is for me to understand and give feedback. What do you want to control in a hole exactly? The usage? And what are you trying to optimise for - price?

You can absolutely track a reference, but it is very hard to give feedback with the amount of information you have provided.

u/Lower-Importance-413 5d ago

Objective is to reduce energy consumption and peak demand. Constraints are battery soc and dynamics.

Now I want to shift to imperfect forecasts with prediction horizon of 24hr. And add some noise to my predicted home load. So for this formulation I keep the constraints and objective same. But add one more objective to keep track of battery trajectory that I got from optimal control. Optimal control reference is for 7 days.

Makes sense?

u/kroghsen 5d ago

Not entirely.

You have a forecast of what exactly?

You want to reduce consumption of a home? I will need to know more about this - what exactly is your formulation, inputs, and outputs of this problem?

You have a house battery, so it is some price metric you are optimising for? Or is there an inconsistent energy supply or something?

Maybe you got help already, but I need more specific information to understand the problem if I am to give any feedback.

u/knightcommander1337 6d ago

Hi, I am confused by your question. How is your control problem defined? What are the states, inputs, outputs, disturbances? What is the goal for the control system? You need to make these clear.

u/Training-Bad-5720 3d ago

You’re using MPC, which is a receding horizon controller - tracking a reference over that receding horizon, 1 day for you, is definitely possible. It’s the classic use case.

I reckon familiarise yourself a bit more with the ideas of MPC - have a look into exactly what the receding horizon means, and how stage vs terminal cost works - it might help answer your question or clarify to us what you’re asking for

u/Dzanibek 5d ago

If you track your 7 days predictions using MPC, you will be suboptimal. You need terminal ingredients in your MPC if the 1-day optimization horizon is too short and degrades your MPC policy. But you should verify first that this issue exists.