I am possibly searching for the wrong thing or it is too generic but I am not seeing an existing solution for proper smart heating.
This is particularly looking at UK heating (which I think is probably similar to mainland Europe) but what I am looking to do is set schedules based on when I want to hit the target temperature not when I want to start heating.
I have a Nest which I want to get rid of but this does a pretty good of deciding when to fire the boiler up to hit the target temperature but only did this based on where the thermostat is located.
I have an old house so heating is not very consistent across the house. Most rooms have TRVs but have quite different heating characteristic (some take a lot longer than others).
Currently I have schedules on the TRVs based on whether it is a weekday, anyone is home etc. and it works OK but I will need to set the schedule to say 19C at 16:00 to try and hit that by 17:00 and then if we get a very cold snap it isn’t long enough so it is doesn’t hit 19C until much later.
What I really want is to do something that will learn the heating characteristics of each room (taking into account the weather (including the forecast),current temperature, humidity and work out what time the boiler will need to come on in order to hit the target temperature at the required time).
Are my search skills just lacking and something like this already exists or can anyone suggest any good pointers on how I might improve things.
But these are almost all a single zone and with a single sensor (I have a Nest that does that now). Even with zones these tend to be only a couple of zones which is fine if you want to control say a whole floor but not ideal for individual room levels. In a 100+ year old house with variable levels of insulation there can easily be a 4C difference between rooms.
I only want to heat certain rooms at certain times (eg. on a workday the bedrooms do not need heating during the day but the home office does). If no-one is home then nothing needs heating.
Ideally what I want to do say I want these rooms at 19C at 06:30 and then drop most the rooms to 15C at 08:00 then have the main living rooms back at 19C at 16:30. And from all of this work out when to fire up the boiler and adjust the TRVs to achieve that. With standard thermostats like the Honeywell or Nest then even if they did have multiple sensors in each room what would happen is that some rooms would hit 19C at 06:30 but others would hit it at 05:30.
In the absence of any existing HA solution I am thinking of something like
fire up the boiler if any TRV is calling for heat (already doing this)
set TRVs to 14C overnight
every 5 minutes run an automation that
picks out what the next target temperature and target time are
checks external temperature and weather forecast
uses some sort of algorithm (per room) to determine how long it will take for the room to hit target temperature
if the calculated time is after the target time then set the TRV temperature (which will trigger the boiler)
Just can’t see any easy way to do the algorithm other than manually building this outside of HA. Currently thinking of an external machine learning generated algorithm that takes all the variables and returns a time via a restful interface and using this in HA
It is not enough with the variables.
You need historic values for all the variables and probably many years worth of historic data, because they affect each other.
A ML generated algorithm is only as good as the input it gets and you will probably not be able to give it enough data points to work out a good formula, so you need to pretty much give it all the values for all the variables in different situations. You can do it with human judgement of the situation. A ML algorithm do not have that. I will be a huge task though.
I think it will be easier if you programmed it yourself.
Node Red is pretty good for such things.
It has the entire state machine copied to its Global Data register, so it is easy to access and the function nodes can do javascript code.
As you work through your design consider the failure modes. For example, if HA fails (computer bites the dust, sw crashes) or sensor / actuator failure what’s the impact - frozen pipes? Overheated house? Exploding boiler?
The more moving parts = higher likelihood of failure.
With a set of independent thermostats the probabilities of simultaneous failure is low. If HA goes out all zones may be down.
I solved this problem with these scripts. I also linked it to the alarm clock on my iPhone. Now the apartment is already at the desired temperature when I wake up.
There aren’t any more real moving parts than a standard system. Without the smarts I would have TRVs and a thermostat on a schedule. It is just that I have smart TRVs (which have some inbuilt failure resilience and can easily be switched to a manual schedule). The Nest is currently largely a switch for the boiler I will keep that or a simpler alternative to maintain manual control in parallel and probably use that to maintain a safe temperature so if it ever gets that low then that manual control would take over and if there was anything catastrophic with HA I would just use that (although in reality I have a spare HA box I keep and I have tested that I can be back up and running in about 15 minutes. (if it is more than that then I might not need any heating…)
With the age of my boiler I suspect that is far more likelihood of that packing in than issues elsewhere but I will factor failure in
I have things like toom temperatures and the like going back 18 months (albeit it is aggregated a bit) in HA so I probably have enough to make a start but I am currently thinking about ESP32 temperature humidity sensors to give me a bit more solid measurements.
Realistically I will probably start with what I have already which works OK but I know could be a lot better and then try and apply something in the morning and afternoon before the schedule kicks in. Worst case would be that the schedule kicks in as now.
Currently looking to see if I can generate stats for when the boiler it running
time of sample
room temperature
room humidity
outside temperature
time boiler started
possibly adding illuminance and sun elevation as I have them.
Annoyingly knowing whether the TRV is actually calling for heat is an attribute so there is no history. Going to have a think about how I handle that
You see the values you really need is the value for heat transfer from the radiators to the air at different temperatures, the amount of air in the room, the heat loss of all each of the surfaces at different temperatures, the wind chill factor on that heat loss of the surfaces at different temperatures.
These values can make for a really good formula, but what you have is derived values, so they can not be put into a formula as such.
a ML could probably make the formula work, but in order to do that then it needs to be able to lock some of the factors that are included in those derived values in order to calculate a single factor.
That means if you have a inside temperature scale from 16 to 24 in increments of 0.1, then you have 80 measurements there.
If you want to combine them with the outside temperature that can go from like -10 to 20 in increments of 0.1, then you have 300 measurements there and with the inside temperature then it adds up to 2400 different combinations.
If the radiator then can heat in just 30 different steps, then you get 2400 x 30 = 72000 combinations.
You can then see how it goes when you add chill factor from winds, sun heating, humidity and so on.
You will probably not need all of the values to make a good formula, but just 10% will still be a huge number with all those factors playing in.
exactly what I planned and partially did (it fully worked for me last winter). Sun elevation was in my roadmap. I know ML can be really exciting, but I believe in real science for robust control, with empirical simplifications too … Anyway I’m on pause far away from home until next year but you can still find inspiration if you prefer to develop another approach
Make a template that calculate the difference between current temperature and target temperature and give it a unit of measurement too, so you can store it in your statistics.
While technically correct, I think you are overestimating the complexity needed here. It’s not necessary to hit a target with precision of 0.1 degree and 1 minute. You just want the room to be around the right temperature at about the right time. Typically, your room will heat up with a curve where the difference between setpoint and actual temperature is of the form exp(-t/t0). All you want is a ballpark estimate of t0, since you’re looking for how long in advance to switch on the heat. This will depend on the water temperature in your radiators and the heat loss to the environment, which in turn depends on temperature of the outside and other rooms.
I think with 18 months of data, you can get a reasonable estimate. I don’t know if an ML approach is the most efficient to get that estimate.
That was sort of the point I was trying to make, but maybe failed a bit.
The ML can not really deduct that formula.
You as a human can because you can make rational assumptions.