Fuel expenses constitute the largest part of the operating cost of a merchant ship. Integrated energy systems that cover all energy loads with low fuel consumption, while being economically feasible, are increasingly studied and installed. Due to the large variety of possible configurations, design specifications, and operating conditions that change with time, the application of optimization methods is imperative. Designing the system for nominal conditions only is not sufficient. Instead, intertemporal optimization needs to be performed that can be static or dynamic. In the present article, intertemporal static and dynamic optimization problems for the synthesis, design, and operation (SDO) of integrated ship energy systems are stated mathematically and the solution methods are presented, while case studies demonstrate the applicability of the methods and also reveal that the optimal solution may defer significantly from the solutions suggested with the usual practice. While in other works, the SDO optimization problems are usually solved by two- or three-level algorithms; single-level algorithms are developed and applied here, which tackle all three aspects (S, D, and O) concurrently. The methods can also be applied on land installations, e.g., power plants, cogenerations systems, etc., with proper modifications.