How to control the house temperature using a fan system?

5 Ansichten (letzte 30 Tage)
hunter manana
hunter manana am 16 Jul. 2023
Beantwortet: Sam Chak am 17 Jul. 2023
I am modeling a fan system that is able to reduce the temperature of the house when it exceeds a certain set temperature.
The idea is to use the difference between the set temperature and the house temperature to tune and control whether the fan system comes on to cool down the house temperature in case it's too high and vice versa. It should be able to control and maintain a certain temperature in the house.
This is where I am stuck, I don't know how to control the house temperature to a desired set temperature using the fan system.
Attached is the simulink file.
All the help is appreciated thanks.
  3 Kommentare
hunter manana
hunter manana am 17 Jul. 2023
Lets say the say the set internal temperature is 25 degrees C, when the internal temperature temperature is 30 degrees C, the fan will extract the hot air from inside until the temperatures drop to 25 degrees C. When the temperatures are lower, the stored heat during the day for instance will be used to increase the temperatures to 25 degrees C.
DGM
DGM am 17 Jul. 2023
Bearbeitet: DGM am 17 Jul. 2023
If the indoor temperature is decreasing naturally, it's because heat is being lost to the outdoors. Ventilation only accelerates the process. It's not clear to me where you're storing heat otherwise, but then again, I can't open the .slx file. Latest version of simulink I have installed is R2015b.

Melden Sie sich an, um zu kommentieren.

Antworten (1)

Sam Chak
Sam Chak am 17 Jul. 2023
I'm unsure of how your house temperature control mechanism works. But if based on the thermal dynamics provided, then this is probably how the math produces magic (see User-defined parameters section). I also do not know how your PID works. Perhaps you can translate the given math into something that your PID control block recognizes.
tspan = linspace(0, 1, 10001);
T0 = 30; % Initial house temperature
[t, T] = ode45(@odefcn, tspan, T0);
% Solution Plot
plot(60*t, T, 'linewidth', 1.5),
ylim([18 32]), grid on,
xlabel('Time / min'), ylabel('Temperature / °C')
yline(23, '--', '23°C', 'LabelVerticalAlignment', 'Bottom')
% Ordinary Differential Equation function
function Tdot = odefcn(t, T) % (T = Thouse)
% Thermal Resistance of the House
Req = 0.0000004; % C/J-hr
% Mass of air present in the house
M = 5987.7684; % kg
% Specific heat capacity of air
c = 1005.4; % J/kg-C
% Outside temperature (assumed to be measurable)
Tout = 23 + 5*sin(2*pi/24*t);
% User-defined parameters (set the values as indicated, the rest are 'laws')
ts = 20/60; % desired settling time (hr) <-- set this one
k = 5/ts; % thermal control rate <-- maybe related to the heater's capacity
Tref = 23; % reference temperature <-- and this one
Tgain = (- Req*M*c*k*(T - Tref) + T - Tout)/Req;
% Thermal dynamics
Tloss = (T - Tout)/Req;
Tdot = (Tgain - Tloss)/(M*c);
end

Kategorien

Mehr zu General Applications finden Sie in Help Center und File Exchange

Produkte


Version

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by