Code Monkey home page Code Monkey logo

computernetworkalgorithms's Introduction

ComputerNetworkAlgorithms

Graph ADT and shortest path algorithms + Polynomials ADT and CRC algorithm. Project that I created while taking course on Computer networks on faculty. I wanted to make an useful abstraction of graphs and polynomials so that algorithm implementations would be lightweight (e.g. I don't think that CRC algorithm should know how polynomial division is done. It should only ask for division and Polynomial ADT should take care of the rest.)

It can be devided into two parts:

  • Graphs and shortest path algorithms
  • Polynomials and CRC algorithm

NOTE: Do you like it? Show it by giving a โญ๏ธ. ๐Ÿš€

Graphs and shortest path algorithms

It comprises of following data structures:

๐Ÿ”Ž Data structure Description
<> Distance Simple struct that represents tuple (vertex A, vertex B, edge weight)
<> Edge Makes comparing edges and summing edge weights easier. It also makes having edges with infinit or no weight easier.
<> Graph Represents graph that can be directed or undirected.
<> GraphBuilder Class inspired by StringBuilder provides handy way to build Graph (which are immutable).
<> GraphWithTracking Wraps around Graph and provides a lists to keep track of calculated distances between vertices and to keep track which vertices are visited.

Algorithm implementations:

๐Ÿ”Ž Algorithm
<> Dijkstra
<> BellmanFord

Polynomials and CRC algorithm

It comprises of following data structures:

๐Ÿ”Ž Data structure Description
<> DecimalMonomial This class represents one part of the Polynomial. This is not an mathematical but artificial structure which is essential building block of Polynomials. In this polynomial 4x^3 + 2x - 1 monomials are [4x^3, 2x, -1].
<> DecimalPolynomial Represents decimal polynomial internaly build out of DecimalMonomials. It makes addition, multiplication, comparison, ... among decimal polynomials easy.
<> BinaryPolynomial Represents binary polynomial internaly using one uint to hold polynomial. It makes addition, division, comparison, ... among binary polynomials easy.

Algorithm implementations:

๐Ÿ”Ž Algorithm
<> CrcAlgorithm

computernetworkalgorithms's People

Contributors

miro-jelaska avatar ratokuzmanic avatar

Stargazers

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