URGENT: Please solve Question 4 by
Formulate an integer programming model to solve the problem
Code the integer programming model in CPLEX. Please provide the code (either take screenshot or link to tutorial)
Report the optimal solution.
Part III Q.4) Consider the undirected graph below. Node 1 Node 4 Node 2 Node 3 Node 6 Node 7 Node 5 Node 8 You will find that some nodes are adjacent (or, directly connected) to each other, e.g., Nodes 1 and 2, Nodes 2 and 6, as well as Nodes 5 and 8. Some nodes are distance 2 from each other, that is, the shortest path between these two nodes has two edges. For example, Node 3 and Node 1 are connected via Node 2, but Nodes 3 and 1 are not directly connected. The shortest path between Nodes 3 and 1 has two edges. Node 7 and Node 1 are also distance 2 away from each other. You are given the task to allocate non-negative integers to these nodes, such that: 1. For nodes that are adjacent to each other, the difference between the allocated integers must be at least 2. For example, if the number "3" is allocated to Node 5, then none of the numbers "2", "3", or "4" can be allocated to Node 8 or Node 1. 2. For nodes that are distance 2 away from each other, the allocated integers must be different. For example, the numbers allocated for Nodes 1 and 3 must be different. Assuming that the smallest integer we can use is 0, our objective for this optimization problem is to minimize the largest integer used. • Formulate an integer programming model to solve the problem. Hint 1: you can use a non-negative integer decision variable y, to represent the integer used for node i. Hint 2: revisit Topic 7 Integer Programming, Part 1-Modelling Techniques, Either-or constraints. [8 marks] • Code the integer programming model in CPLEX. Please provide the code. [10 marks] . Report the optimal solution. [2 marks]
URGENT: Please solve Question 4 by Formulate an integer programming model to solve the problem Code the integer programm
-
- Posts: 43759
- Joined: Sat Aug 07, 2021 7:38 am