The research activity described in this work is focused mainly on the study of finite-element techniques applied to thermo-fluid dynamic problems of plant components and on the study of dynamic simulation techniques applied to integrated building design in order to enhance the energy performance of the building. The first part of this book is a broad dissertation on second law analysis of thermodynamic processes with the purpose of including the issue of the energy efficiency of buildings within a wider cultural context which is usually not considered by professionals in the energy sector.In particular, the first chapter includes a rigorous deduction of the expressions for molar exergy and molar flow exergy of pure chemical fuels. The second chapter presents a study of borehole heat exchangers, that is, a polyethylene piping network buried in the soil which allows a ground-coupled heat pump to exchange heat with the ground. Finally, in the third chapter a thorough process is presented for the plant design of a zero carbon building complex.