If you are performing a linear static analysis using the peak g-loading from the earthquake, and if you are calculating the steady-state thermal expansion, you can analyze the loads separately then combine the results in your post-processor. You could then determine the maximum allowable thermal expansion in order to survive the earthquake load.
pj