There is one point to which I want to draw attention. When setting up the circuit I connect the common GND pins. Some fans cannot measure the extent of trying correctly. If you encounter such a thing, you can connect GND separately. When I hooked them up separately, it was solved.
I must say also that with the relay NO, it is necessary to pay attention to NC pins. NO means "normally open" and NC means "normally closed". So, if you connect the NO pin, it stops when it reaches 0. If you connect the NC pin, it stops when it reaches 0 1 runs.
First, let me mention that it produces a value between 0 and 1 volt with LM35 value as a margin of error; but the way you work with 5V, there are values that can be high.
That's why we need to inform the Arduino to produce values between 0 and 1.1 volts. Here you
analogReference (INTERNAL) are doing with the command.
When we talk about self-assessing the degree 10mV from each LM35 that 1 ° C corresponds to, we were told to use the Arduino reference to 1,1V. In this way, it is going to have to look at each analog input value , like 1.0742 mV. i.e., 10 mV, since it corresponds to 1 ° C; 10 / 1.0742 gives us the value of approximately 9.31.