## Problem Description and Formulation

The problem is a classic example of a linear programming problem. The factory has two machines: a meat-grinder and a meat-packer, and two products: sausages and burger patties. The goal is to maximize profit by determining the optimal number of batches of each product to produce.

Let's define the decision variables:

* $x_s$: number of batches of sausages to produce
* $x_b$: number of batches of burger patties to produce

The objective function is to maximize profit:

* Profit per batch of sausages: $200
* Profit per batch of burger patties: $250
* Total profit: $200x_s + 250x_b$

The constraints are:

* Meat-grinder machine runs for at most 3000 hours per year:
	+ 2 hours per batch of sausages: $2x_s$
	+ 4 hours per batch of burger patties: $4x_b$
	+ Total hours: $2x_s + 4x_b \leq 3000$
* Meat-packer machine runs for at most 3000 hours per year:
	+ 3 hours per batch of sausages: $3x_s$
	+ 1.5 hours per batch of burger patties: $1.5x_b$
	+ Total hours: $3x_s + 1.5x_b \leq 3000$
* Non-negativity constraints: $x_s \geq 0, x_b \geq 0$

## Gurobi Code

```python
import gurobipy as gp

# Create a new model
m = gp.Model("Sausage_Burger_Optimization")

# Define decision variables
x_s = m.addVar(name="x_s", lb=0, ub=None, obj=200)  # batches of sausages
x_b = m.addVar(name="x_b", lb=0, ub=None, obj=250)  # batches of burger patties

# Meat-grinder constraint
m.addConstr(2 * x_s + 4 * x_b <= 3000, name="meat_grinder")

# Meat-packer constraint
m.addConstr(3 * x_s + 1.5 * x_b <= 3000, name="meat_packer")

# Solve the model
m.optimize()

# Print the results
if m.status == gp.GUROBI_OPTIMAL:
    print("Optimal solution found.")
    print(f"Batches of sausages: {x_s.varValue}")
    print(f"Batches of burger patties: {x_b.varValue}")
    print(f"Max profit: ${m.objVal:.2f}")
else:
    print("No optimal solution found.")
```