Code Monkey home page Code Monkey logo

transition-matrix-generator's Introduction

transition-matrix-generator

Idea

Note: Most of the text was translated via Yandex Translate

In the game "I hate this game" there was a task where it was necessary to turn the arrows in the right direction, they were fixed by themselves, but they had numbers on them that meant the number of transitions in the selected direction to another arrow.

For some crazy reason, I came up with the idea to make a generator of such a sequence, but I was faced with ignorance of algorithms in principle, so I needed a visual representation. Actually... this is one of the reasons why most of it was spent on developing a representation of this model.

Interface

Width, Height, Generate button, Scale, +, -, reset scale, reset viewport position

If the picture did not load, then here is the description from left to right:

  • Number of cells on the X axis
  • Number of cells on the Y axis
  • Generate
  • Current viewport scale
  • Zoom in
  • Zoom out
  • Reset scale
  • Reset viewport position

The viewport can be navigated by dragging with the left mouse button and zooming with the mouse wheel.

You can also turn the arrows clockwise and counterclockwise by pressing the left and right keys, respectively.

Result example

Caution: creating a grid larger than 6x6 or 7x7 can go into deep bruteforce, as the algorithm tries to go through all possible paths!

Here is a grid with arrows that are rotated 0, 90, 180, 270 degrees and there are two numbers inside every arrow: index and count

transition-matrix-generator's People

Contributors

doggyxomax avatar

Watchers

James Cloos avatar  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.