项目作者: TheLokin

项目描述 :
Wire Routing solver
高级语言: Python
项目地址: git://github.com/TheLokin/Wire-Routing.git
创建时间: 2019-04-30T20:31:37Z
项目社区:https://github.com/TheLokin/Wire-Routing

开源协议:MIT License

下载


Wire Routing

Introduction

This project use telingo to solve a variant of the wire routing problem as a multi-robot planning problem. Given a rectangular
grid, the problem consists in joining pairs of points (named with the same letter {a,b,c,…}) with a continuous line that does
not intersect with lines for other pairs. Some of the grid cells are marked as obstacles.

Implementation

The input will be given as a text file where the two first lines respectively contain the number of rows and columns of the
grid. We use “.” to represent an (initially) empty cell, “#” to represent an obstacle and letters {a,b,c,…} to mark pairs of
points to be joined. The output is a text file where each “wire” is traced using the corresponding letter. As an example:

Initial configuration: two wires, a and b, are needed.

  1. 6
  2. 7
  3. .a....b
  4. .......
  5. ..b..##
  6. .##..##
  7. .##...a
  8. .....##

A possible solution.

  1. .a..bbb
  2. aa..b..
  3. a.bbb##
  4. a##..##
  5. a##.aaa
  6. aaaaa##

Execution

The examples folder contains a set of benchmarks of different sizes. Solutions are not included because several minimal
solutions can be obtained.

  1. ./wire.py [-h] [-o] input
  2. -h show this help message and exit
  3. -o calculate optimum path
  4. -input path of the wire routing instance