In the genetic algorithms (GAs), maintenance of the diversity of the population is an important issue to enhance their optimization and adaptation ability. The authors have proposed the thermodynamical genetic algorithm (TDGA), which can maintain the diversity explicitly and systematically by evaluating the diversity of the population as entropy and by selecting offspring so as to minimize the free energy. In applications of the GA to problems of adaptation to changing environments, maintenance of the diversity is an essential requirement because it is a key factor of the GA in yielding novel search points continuously for adaptation. This paper discusses adaptation to changing environment by means of TDGA. The authors propose a control method of the temperature, an adjustable parameter in the TDGA. That is, the temperature is controlled by a feedback technique so as to regulate the level of the entropy of the population. The adaptation ability of the proposed method is confirmed by computer simulation taking time-varying knapsack problems as examples.