Our aim is to give the readers a solid understanding of the basics and help them develop innovative solutions to problems that vary in subtle ways from country to country, from market to market and from company to company. The plan of this book is simple, we discuss the concepts from microeconomics that are essential for the understanding of electricity markets. We then move on to the analysis of the operation of power systems in a competitive environment. To keep matters simple, we begin by ignoring the transmission network and we consider the operation of pure energy markets.