Code Monkey home page Code Monkey logo

geneticalgorithm's Introduction

#Description of the problem

image

The optimization problem is presented in figure no. 1. It is necessary to drill 263 holes on the printed circuit board shown in picture no. 1. Each hole has its own unique X and Y coordinates. A tile manufacturer is looking for an increase in the number of tiles produced per day. This result is achieved by reducing the length of the hole that the drill bit has to travel to drill 263 holes. This problem belongs to the TSP class of problems. Within the .txt file are the coordinates of the points to be loaded.

The optimization algorithm used to solve this problem is the "Genetic Algorithm".

The formation of the first generation is realized by a random combination of 263 points, until the first population of 1000 elements is created. After which the optimization function is calculated. When creating the next generation, a process of selecting the best parents is performed, followed by random crossing between the selected parents until a population size of 1000 children is reached. At each crossing, the mutation probability of a particular child is checked. If the probability is higher than a certain one, the process of mutation occurs, which ends the cycle of creating a new generation. During the creation of each next generation, the results of the optimization functions are placed in the global variable, where the smallest value for the duration of this algorithm is sought. This process is repeated until the desired number of populations. The case that gives the best solution is realized after 2000 generations.

geneticalgorithm's People

Contributors

marko1997221 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.