Skip to content

Latest commit

 

History

History
35 lines (29 loc) · 1.03 KB

File metadata and controls

35 lines (29 loc) · 1.03 KB

Transportation Problem

This Python script provides a solution to the Transportation Problem using various approximation methods such as North-West corner method, Vogel’s approximation method, Russell’s approximation method. The Transportation Problem involves optimizing the distribution of goods from multiple suppliers to multiple consumers with given supply, demand, and transportation costs.

Usage

  1. Prerequisites: Ensure you have Python 3.8+ installed on your system.
  2. Clone Repository: Clone the repository and navigate to the directory containing the script.
  3. Input File: Create a text file, e.g., test.txt, with the specified format (see below).
  4. Run Script

Input File Format

The input file should follow this format:

<supply array>
<demand array>
<cost matrix row 1>
<cost matrix row 2>
...
<cost matrix row n>

Replace <supply array>, <demand array>, and <cost matrix row i> with appropriate values.

Example Input :

160 140 170
120 50 190 110
7 8 1 2
4 5 9 8
9 2 3 6