world.java
来自「遗传算法求解TSP问题」· Java 代码 · 共 27 行
JAVA
27 行
/*******************************************************************************
* This is a simple JAVA-Applet to demonstrate algorithms solving the Traveling
* Salesman problem. Feel free to use or modify it. If you do so, please send me
* a copy.
* Tim Stockheim (tim@stockheim.net)
* 1995 (programmed) & 2001 (updated)
*
* Please do not delete my name from this program.
* The following files contain to the applet:
* Knoten.java Main.java Map.java Map1.java Map2.java Tour.java World.java
*******************************************************************************/
// Class World contains all parameters to construct the Tour
public class World {
// width and height of the ordinate and absziss
static int width = 1000;
static int height = 1000;
// to get a larger picture use the parameter
static double scaling = 0.3;
// number of initially created points
static int points = 50;
/* distance beetween 2 point
attention if distance is to large not all points fit on the map --> deadlock */
static int minDist = 25;
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?