top of page
Inaugurated by IN-SPACe
ISRO Registered Space Tutor

S6-SA1-0439

What is the Integer Programming (basic intro)?

Grade Level:

Class 10

AI/ML, Physics, Biotechnology, Space Technology, Chemistry, Engineering, Medicine

Definition
What is it?

Integer Programming is a special type of mathematical problem-solving where you need to find the best solution, but the answers must be whole numbers (integers). It's like finding the maximum profit, but you can only make a whole number of products, not half a product.

Simple Example
Quick Example

Imagine you are a cricket team selector. You need to pick the best 11 players from a squad of 15. You can't pick 10.5 players, right? You must pick a whole number of players. Integer Programming helps find the best combination of 11 players to maximise winning chances.

Worked Example
Step-by-Step

Problem: A bakery makes two types of cakes: Gulab Jamun Cake and Rasgulla Cake. Each Gulab Jamun Cake needs 2 eggs and 1 hour to bake. Each Rasgulla Cake needs 3 eggs and 2 hours to bake. You have 12 eggs and 8 baking hours. If a Gulab Jamun Cake sells for Rs. 100 and a Rasgulla Cake for Rs. 150, how many of each cake should you make to maximise profit, assuming you can only make whole cakes?

Step 1: Define variables. Let 'x' be the number of Gulab Jamun Cakes and 'y' be the number of Rasgulla Cakes.
---Step 2: Write the objective function (what you want to maximise). Profit = 100x + 150y.
---Step 3: Write the constraints (limitations). Eggs: 2x + 3y <= 12. Baking hours: 1x + 2y <= 8.
---Step 4: Add the integer constraint: x and y must be whole numbers (integers) and cannot be negative (x >= 0, y >= 0).
---Step 5: Plot these constraints on a graph or use trial and error with integer values. For example, if x=0, 3y <= 12 (y <= 4) and 2y <= 8 (y <= 4). Max profit for x=0 is 150*4 = 600.
---Step 6: If x=1, 2 + 3y <= 12 (3y <= 10, y <= 3.33) and 1 + 2y <= 8 (2y <= 7, y <= 3.5). So y can be 0, 1, 2, 3. Max profit for x=1, y=3 is 100*1 + 150*3 = 100 + 450 = 550.
---Step 7: If x=2, 4 + 3y <= 12 (3y <= 8, y <= 2.66) and 2 + 2y <= 8 (2y <= 6, y <= 3). So y can be 0, 1, 2. Max profit for x=2, y=2 is 100*2 + 150*2 = 200 + 300 = 500.
---Step 8: Continue this for other integer values. The best solution is often found at the 'corners' of the feasible region. In this case, making 6 Gulab Jamun cakes (x=6) and 0 Rasgulla cakes (y=0) uses 12 eggs and 6 hours, giving profit 600. Making 0 Gulab Jamun cakes and 4 Rasgulla cakes gives profit 600. So, there are two optimal solutions.
Answer: You can make 6 Gulab Jamun Cakes and 0 Rasgulla Cakes OR 0 Gulab Jamun Cakes and 4 Rasgulla Cakes to get a maximum profit of Rs. 600.

Why It Matters

Integer Programming is crucial for making smart decisions in various fields. From planning the most efficient delivery routes for Zomato to scheduling flights for airlines, it helps optimise resources. Engineers use it to design efficient systems, and even doctors use it to plan radiation therapy for cancer patients.

Common Mistakes

MISTAKE: Assuming the answer will always be whole numbers even if you don't specifically add the integer constraint. | CORRECTION: Always explicitly state that variables must be integers (e.g., x, y are integers) if the problem requires whole number solutions.

MISTAKE: Rounding off fractional answers from standard linear programming to the nearest integer. | CORRECTION: Rounding off can lead to a solution that is not optimal or even not feasible (doesn't satisfy constraints). You must solve it specifically as an Integer Programming problem.

MISTAKE: Forgetting that variables like 'number of items' cannot be negative. | CORRECTION: Always include non-negativity constraints (e.g., x >= 0, y >= 0) for real-world problems.

Practice Questions
Try It Yourself

QUESTION: A farmer wants to plant mango and guava trees. Each mango tree needs 2 sq m of land, and each guava tree needs 3 sq m. He has 10 sq m of land. He wants to plant exactly 4 trees in total. How many of each type of tree (whole numbers) can he plant? | ANSWER: Let 'm' be mango trees and 'g' be guava trees. Constraints: 2m + 3g <= 10 and m + g = 4. Possible integer solutions: (m=2, g=2) or (m=3, g=1).

QUESTION: A mobile game developer needs to create two types of characters: 'Warrior' and 'Mage'. Each Warrior takes 3 hours to design and costs Rs. 500. Each Mage takes 4 hours to design and costs Rs. 700. The developer has a maximum of 20 design hours and a budget of Rs. 3000. If they want to maximise the number of characters, how many of each (whole numbers) should they make? | ANSWER: Let 'w' be Warriors and 'm' be Mages. Maximize w + m. Constraints: 3w + 4m <= 20 (hours), 500w + 700m <= 3000 (budget). Integer constraints: w, m >= 0 and are integers. The optimal solution is w=4, m=2 (total 6 characters).

QUESTION: A school canteen sells samosas for Rs. 15 and vada pav for Rs. 20. They have ingredients for a maximum of 10 samosas and 8 vada pavs. They want to earn at least Rs. 150. If they can only sell whole items, what is one possible combination of samosas and vada pavs they can sell to meet their target? | ANSWER: Let 's' be samosas and 'v' be vada pavs. Constraints: s <= 10, v <= 8, 15s + 20v >= 150. Integer constraints: s, v >= 0 and are integers. One possible solution is s=6, v=3 (earns 15*6 + 20*3 = 90 + 60 = 150). Many other solutions are possible.

MCQ
Quick Quiz

Which of the following is a key characteristic of Integer Programming?

The variables can take any real number value.

The objective is always to minimise cost.

The decision variables must be whole numbers.

It only applies to problems with two variables.

The Correct Answer Is:

C

The defining feature of Integer Programming is that its decision variables must be integers (whole numbers). Options A, B, and D are incorrect as variables can't be any real number, the objective can be maximisation, and it can handle many variables.

Real World Connection
In the Real World

Think about how Amazon or Flipkart plans their delivery routes. They have to decide which warehouses to use, which trucks to load, and which path each truck should take to deliver thousands of packages. They can't deliver half a package or send half a truck. Integer Programming is used extensively by these logistics giants, and even by ISRO for mission planning, to find the most efficient whole-number solutions for complex problems.

Key Vocabulary
Key Terms

INTEGER: A whole number (positive, negative, or zero) without any fractional or decimal parts. | CONSTRAINT: A limitation or restriction that must be satisfied by the solution. | OBJECTIVE FUNCTION: The mathematical expression that you want to either maximise (e.g., profit) or minimise (e.g., cost). | OPTIMISATION: The process of finding the best possible solution under given conditions.

What's Next
What to Learn Next

Great job understanding Integer Programming! Next, you can explore 'Linear Programming', which is similar but allows fractional answers. This will help you see how the integer constraint changes problem-solving and open doors to more advanced optimisation techniques used in AI and data science!

bottom of page