Why we are getting opposite sign bending moments in the external and the internal longitudinal members due to Heating?

Creation date: 8/15/2018 8:47 PM    Updated: 5/16/2023 3:05 PM    beam section temperature
Answer:
Let me explain with the 'Heating' load case. 
I removed all the transverse members connected to the main girders and after running the analysis the moments are almost zero for all four girders as expected.

And the center of all girders are moving upward as shown below.

If you check the rotations about the global Y axis (RY), we can see that the rotations are larger in the external girder than the internal girder. In the grillage model, the main girders are connected to the transverse members. Thus, the difference of rotations between the internal girder and external girder is restrained by each other. Therefore, the rotations of the external girder are decreased, which leads to sagging moments. The rotations of the internal girder are increased, which leads to hogging moments.
Files