Introduction to Optimization in Python
Learn to solve real-world optimization problems using Python's SciPy and PuLP, covering everything from basic to constrained and complex optimization.
Start Course for Free4 hours13 videos42 exercises2,165 learnersStatement of Accomplishment
Create Your Free Account
or
By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.Training 2 or more people?
Try DataCamp for BusinessLoved by learners at thousands of companies
Course Description
Optimization problems are ubiquitous in engineering, sciences, and the social sciences. This course will take you from zero optimization knowledge to a hero optimizer. You will use mathematical modeling to translate real-world problems into mathematical ones and solve them in Python using the SciPy and PuLP packages.
Apply Calculus to Unconstrained Optimization Problems with SymPy
You will start by learning the definition of an optimization problem and its use cases. You will use SymPy to apply calculus to yield analytical solutions to unconstrained optimization. You will not have to calculate derivatives or solve equations; SymPy works seamlessly! Similarly, you will use SciPy to get numerical solutions.Tackle Complex Problems Head-On
Next, you will learn to solve linear programming problems in SciPy and PuLP. To capture real-world complexity, you will see how to apply PuLP and SciPy to solve constrained convex optimization and mixed integer optimization. By the end of this course, you will have solved real-world optimization problems, including manufacturing, profit and budgeting, resource allocation, and more.Training 2 or more people?
Get your team access to the full DataCamp platform, including all the features.- 1
Introduction to Optimization
FreeThis chapter introduces optimization, its core components, and its wide applications across industries and domains. It presents a quick, exhaustive search method for solving an optimization problem. It provides a mathematical primer for the concepts required for this course.
Introduction to mathematical optimization50 xpUnderstanding mathematical optimization50 xpApplying an objective function100 xpExhaustive search method100 xpUnivariate optimization50 xpFinding the derivative100 xpFind the second derivative100 xpMultivariate optimization50 xpPartial derivatives with SymPy100 xpLimitations of differentiation100 xp - 2
Unconstrained and Linear Constrained Optimization
This chapter covers solving unconstrained and constrained optimization problems with differential calculus and SymPy, identifying potential pitfalls. SciPy is also introduced to solve unconstrained optimization problems, in single and multiple dimensions, numerically, with a few lines of code. The chapter goes on to solve linear programming in SciPy and PuLP.
- 3
Non-linear Constrained Optimization
FreeThis chapter introduces convex-constrained optimization problems with different constraints and looks at mixed integer linear programming problems, essentially linear programming problems where at least one variable is an integer.
Convex constrained-optimization50 xpInterpreting indifference curves50 xpVisualize the indifference curve100 xpUtility maximization100 xpConvex-constrained optimization with inequality constraints50 xpInterior or corner?50 xpLinear constrained biscuits100 xpNonlinear constrained biscuits100 xpMixed integer linear programming (MILP)50 xpAdjusting MILP100 xpUnderstanding integrality50 xp - 4
Robust Optimization Techniques
This chapter covers finding the global optimum when multiple good solutions exist. We will conduct sensitivity analysis and learn linearization techniques that reduce non-linear problems to easily solvable ones with SciPy or PuLP. In terms of applications, we will solve an HR allocation with training costs problem and capital budgeting with dependent projects.
Transforming non-linear problems50 xpSolving the capital budgeting problem100 xpAllocating resources100 xpGlobal optimization in SciPy50 xpFind the global optimum100 xpUsing callback100 xpSensitivity analysis in PuLP50 xpSlack and shadow price50 xpShadow prices with juice100 xpThe diet problem revisited100 xpCongratulations!50 xp
Training 2 or more people?
Get your team access to the full DataCamp platform, including all the features.collaborators
audio recorded by
prerequisites
Introduction to NumPyJames Chapman
See MoreData Science & AI Curriculum Manager, DataCamp
James is a Curriculum Manager at DataCamp, where he collaborates with experts from industry and academia to create courses on AI, data science, and analytics. He has led nine DataCamp courses on diverse topics in Python, R, AI developer tooling, and Google Sheets. He has a Master's degree in Physics and Astronomy from Durham University, where he specialized in high-redshift quasar detection. In his spare time, he enjoys restoring retro toys and electronics.
Follow James on LinkedIn
Follow James on LinkedIn
Jasmin Ludolf
See MoreData Science Content Developer, DataCamp
Jasmin is a Content Developer at DataCamp. After ten years as a global marketing manager in the music industry, she recently changed careers to follow her curiosity for data. Her passion is value exchange and making data science accessible to all.
What do other learners have to say?
Join over 15 million learners and start Introduction to Optimization in Python today!
Create Your Free Account
or
By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.