GithubHelp home page GithubHelp logo

mycodelib's Introduction

MyCodeLib

My own library of useful code and functions It consists of five modules:

  • Data Structures:
    • Fully functional min-max heap structure (Used in implementation of A* and Dijkstra's algorithms)
    • Functional discrete sets structure (with optimized Union-Find algorithm)
  • Functions:
    • Efficient and expandable RPN (reverse polish notation) parser and solver
    • Expression Tree structure for simplifying equations
    • Derivative algorithm for computing analytical derivatives from Expression Tree or RPN parser.
  • PathFinding:
    • Interfaces to standarize any graph concept to algorithms in this section.
    • Created special class for quick start in 2d grid graph (Manhattan2DNode)
    • A* Algorithm implementation for finding the quickest route from A to B
      • Optimized using HashSets instead of lists
      • Optimized using Heap for Open set to be even more efficient
      • Uses generics to adapt to any needs
      • Can be used to find route to any of goals in the set
    • Dijkstra's Algorithm implementation for finding the nearest node meeting given predicate
      • Based on A* implementation (and using it's optimizations)
      • Possibility of specifying distance limit for search
    • Area recognization algorithm for 2D grids using Flood Fill
      • Using iteration instead of recursion, guaranting stability even for big grids
      • Id byte property allowing up to 255 different cell types
      • O(n) time and space complexity
  • Plotting:
    • Classes for plotting complex graphs in 2D and 3D using GDI's Bitmap class
      • Specifying formula in form f(x)=y and f(x,y)=z
      • Specifying parametric formulas for x(t) and y(t) ( and z(t) )
      • Specyfing true/false formula for entire regions of space
    • Transformations - interface allowing you to transform points on plots
      • Invertible and Noninvertible transformations interfaces
      • Ready classes with most common transformations (scaling, translation, rotation etc.)
      • Some advanced transformations (Mobius, Spherical, Normalization)
      • Transformation lists to effectively use a series of transforms
      • All transformations are calculated using multi-threading, guaranting fast work
    • Projections, allowing you to convert your plots from 2D to 3D and vice-versa
    • Figures class to plot simple polygons on plots (cubes, spheres, etc.)
  • Other:
    • Bmp class as alternative for GDI's SaveToBitmap function
    • Hashing class using Pearson hashing as the base, allowing you to make hashes in byte, short, int and long formats
    • ISendable interface for Net server-client system
    • Logger class with automatic date-time addition, console writing, log saving and deep-log functionality
    • MMath static class with useful functions:
      • Converting from HSV colors to RGB
      • Clamping ints/floats to range
      • Quickly checking if object is Numeric
      • Cutting bytes from byte array
      • Extracting null-terminated 2-byte-char strings from byte array
      • Function to return 2 to the power of n (allowed negative numbers)
      • Calculating Modulo of two double numbers
      • Random numbers with gaussian (normal) distribution
      • Function for threading-safe double/float addition
    • Net Server/Client:
      • Full socket and connection handling
      • Server can manage connection to multiple clients
      • Sending and receiving simple data types (from byte to double)
      • Sending string as byte arrays
      • Sending raw byte arrays
      • Sending objects using ISendable interface
      • Server has the ability to send data to all connected clients

This library will be updated and expanded as my experience in programming gets higher.

mycodelib's People

Watchers

Michał Isalski 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.