Skip to main content

A package for solving various optimization problems. Developed by Ramanujan Computing Centre, Anna University.

Project description

VROR

VROR is a Python package designed to solve various optimization problems. It includes implementations for Critical Path Method (CPM), graphical methods for linear programming, simplex method, transportation problems, and assignment problems. Installation

You can install VROR from PyPI using pip:

pip install vror

Usage

Graphical Method

Solve linear programming problems using graphical methods.

from vrorRCC.graphical_method import *

constraints_min = np.array([[2, 1, 10], [1, 3, 18], [3, 1, 15]])
objective_function_min = [5, 4, 0] 
graphical_method(constraints_min, objective_function_min, 'min')

Simplex Method

Solve linear programming problems using the simplex algorithm.

from vrorRCC.simplex_method import *

Objective_Function = np.array([-3, -2, 0])  
constraints = np.array([[2, 1, 0], [-4, 5, 0], [-1, -2, 0]]) 
RHS = np.array([20, -10, 5])  
simplex(Objective_Function, constraints, RHS, maximize=True, plot_3d = False)

Transportation Problems

Solve transportation problems using optimization techniques.

from vrorRCC.transportation_problem import *

cost_matrix = [
    [2, 2, 2, 1, 4],
    [10, 8, 5, 4, 6],
    [7, 6, 6, 8, 6]
]
supply = [30, 70, 50]
demand = [40, 30, 40, 20, 20]
transportation(supply, demand, cost_matrix)

Assignment Problems

Solve assignment problems, typically using the Hungarian algorithm.

from vrorRCC.assignment_problem import *

cost_matrix = np.array([
    [8, 6, 7, 3, 4, 5],
    [4, 8, 5, 7, 3, 7],
    [2, 5, 1, 6, 8, 9],
    [1, 6, 7, 8, 4, 9],
    [3, 8, 5, 7, 5, 1],
    [6, 5, 1, 5, 6, 4],  
])
assignment(cost_matrix)

Critical Path Method (CPM)

Find the critical path in a project network.

from vrorRCC.cpm import *

graph = create_graph()
add_event(graph, 'A', {})
add_event(graph, 'B', {'A': 3})
add_event(graph, 'C', {'A': 2})
add_event(graph, 'D', {'B': 1, 'C': 5})
add_event(graph, 'E', {'D': 3})
add_event(graph, 'F', {'E': 4})


visualize_graph(graph)
critical_path, length = find_critical_path(graph)
print(f"Critical Path: {critical_path} with duration {length}")

Contributing

If you'd like to contribute to VROR, please fork the repository and submit a pull request. For more details, refer to the contributing guidelines. License

VROR is licensed under the MIT License. See the LICENSE file for more details. Contact

For any questions or issues, please contact:

Author: Ragu and Team
Email: https.ragu@gmail.com

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vror-0.1.6.tar.gz (7.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

vror-0.1.6-py3-none-any.whl (9.3 kB view details)

Uploaded Python 3

File details

Details for the file vror-0.1.6.tar.gz.

File metadata

  • Download URL: vror-0.1.6.tar.gz
  • Upload date:
  • Size: 7.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.5

File hashes

Hashes for vror-0.1.6.tar.gz
Algorithm Hash digest
SHA256 338f0ae8a383bf5ae759300acf4cee668f4d7042c47627c16f4e01cb6feee3b7
MD5 d5ae766cbb9494e94e4024da306d03b9
BLAKE2b-256 f1541f9824cae4e3a8a179e459505e2ea7aa57f7d354536e67975f9d734c213f

See more details on using hashes here.

File details

Details for the file vror-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: vror-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 9.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.5

File hashes

Hashes for vror-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 c5671b7e9076e3e89d27bfb21273557c70a7c86ddcbdd04db727a1ae90b1670c
MD5 885a7dc52bc100fd2c42985c9e538a0e
BLAKE2b-256 31b4173e936e91b7b6ac9f4c573235eb551a37fde55e8c70c66fceac47438755

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page