Logistics systems lie at the heart of modern economies and its decisions that range from production planning and inventory management to transportation, routing and facility location shape the efficiency, resilience and competiveness of organizations. These decisions are increasingly complex, data intensive and interdependent, which require rigorous analytical tools capable of transforming information into actionable insights. This book equips students and logistics professionals with the tools to turn complex real life challenges into precise, solvable models that drive measurable results. Step by step, the reader will learn to formulate logistics problems, builds models, and deploy solutions that work optimally in real life environment, not just in textbooks. Essentially, the reader will use AMPL and Pyomo, two of the most powerful and industry proven optimization framework, to move beyond spreadsheets and suboptimal solutions into a new level of decision making confidence. Beyond cost minimization, the book also addresses uncertainty and risk, introducing stochastic optimization and modern risk measures such as the superquantile, which help to efficiently implement agile or leagile supply chain systems. Finally, the textbook provides a framework of integrating optimization with machine learning and digital twins in logistics and supply chain management.