Coder Social home page Coder Social logo

Hi there, I'm Alex πŸ‘‹πŸ»

I'm a former English teacher turned perpetual student of Computer Science and Software Engineering.

What's New?

Rust and The Terminal

In my most recent project, maze-tui, I explored how to stretch the capabilities of the terminal to create beautiful visualizations of common maze building and graph searching algorithms. With the help of ratatui.rs, I was able to realize my vision of interesting and unique algorithm visualizations in the somewhat constrained environment of the Terminal User Interface. Also, the maintainers for ratatui.rs were very helpful in guiding me towards best practices with their library in the Discussion section of their repository. Go check them out! Check out the rough draft C++ version that started it all.

demo

Another project on my radar is the helix-editor. After using Neovim for a few years, I learned of the helix editor project while starting my Rust learning journey. In fact, when I read that helix based their tui library off of the precursor to ratatui.rs, tui.rs, I used my maze-tui project as an opportunity to learn what tui development was all about. I'm hooked! I will keep an eye on this project as I continue to use it, looking for opportunities to contribute where I can.

What's Old?

Algorithm Exploration

I also enjoy exploring new and challenging algorithms and tweaking their core ideas to apply to new and interesting problems. That is the focus of dancing-links and dancing-links-and-planning-pokemon. What started as Stanford University assignments regarding recursion, vertex covers, and independent sets, turned into reworking these ideas to solve computationally difficult problems. This led me to connect Donald Knuth's Dancing Links algorithm to a wide variety of cover problems, even applying it to a beloved video game from my childhood. These projects are written in C++ and I am currently working on big changes for dancing-links-and-planning-pokemon, using this project as an opportunity to learn about the relatively new WebGPU API and the not so new OpenGL.

defense-links

Low Level Principles

With modern C++ practices and languages such as Rust, the direct management of the heap through new and free mechanisms is becoming a thing of the past. However, it is always good to know what is happening a few layers beneath our abstractions. I wanted to know more about how we can make an allocator flexible, efficient, fast, or any combination of these traits. I implemented eight different heap allocators in C and through the use of programs targeted at understanding their performance characteristics wrote an extensive runtime analysis. Five of these allocators are variations on a Red Black Tree allocator and I recently added Splay Trees to the mix. I chose these implementations as they were just slightly beyond my skill level to understand and implement at the time, providing a great opportunity for growth. And, most importantly, I put in place the testing framework and analysis tools for anyone else to explore and have fun implementing their own allocator ideas with this repository. Check out the heap-allocator-workshop!

rbtree-real

TCP

In the spring of 2023 I implemented a comprehensive version of the TCP Network protocol bottom to top; starting with the byte stream and ending with a peer to peer connection. The implementation and design principles I learned from the CS144 Stanford Networking course were invaluable. I won the end of quarter competition for most performant Reassembler and my combined ByteStream/Reassembler performance was second behind the course staff! Again, Stanford University requests we keep our solution private, but the repository we worked from is available publicly every year. Feel free to check it out and I'm happy to share my work upon request. Here is a teaser of a TCPReceiver/Reassembler diagram from my writeup on that section of the course.

                            \     TCPReceiver
                             \ +-------------------+
                              \|isn=0              |
                  +---+-----+                      |
>>>>>>>>>>>>>>>>>>|844|afdgh+>>>>>>>>>>>v          |
                  +---+-----+           v          |
                            \  |        v          |
                             \ |        v          |
                              \|        v          |
               +-----+------+           v
<<<<<<<<<<<<<<<|ackno|window|<<<<<<<<<<<<<<<<<<<<<<<<<<<
               +-----+------+           v              ^
                               |        v          |   ^
                               +-----   v  --------+   ^
                                        v              ^
                                 +--------+-----+      ^
                                 |844+2^32|afdgh|      ^
             \                   +--------+-----+      ^                       /
              \                         v              ^                      /
               \                        v              ^                     /
                \                                                           /
                 \                                                         /
                  |                                                       |-First Unacceptable Index-1000
                  |                                                       |
                  | Stored Segments-----------------|                     |
                  | Next Index Needed---|           |                     |
                  | Pushed Bytes--|     |           |                     |
Popped----|       |               |     |           |                     |
          |       |               |     |           |                     |
|-----------------|------------------|  |           |                     |
------------------+------------------+  |        |------------------------|
;asdkjf;laskjdls  | f8299fsdoiuosid8 |-[844+2^32] |[896+2^32]-->[940+2^32]|
------------------+------------------+                  8          s
                                                        a          8
                                                        y          l
                                                        8          n

                                                  Reassembler

What's Next?

The Operating System

By far my favorite learning opportunities from Stanford University have come out of their systems track classes. The course offerings in this track are varied, rigorous, and well organized. Next in this sequence for me is an opportunity to implement a small operating system over the course of a quarter. Here are two experiments that have already been generated from learning about development in an Operating System environment.

Alex G. Lopez's Projects

c-str-view icon c-str-view

An experiment with string fiddling in C. Is the C++ std::string_view abstraction a good fit for C?

dancing-links icon dancing-links

Various practical implementations of Donald Knuth's Algorithm X via Dancing Links.

heap-allocator-workshop icon heap-allocator-workshop

This repository is a workshop for heap allocator implementations using a variety of data structures and algorithms. The goal is to compare performance and tradeoffs of different approaches in depth.

maze-tui icon maze-tui

This repository implements various maze building and solving algorithms in Rust. Unicode characters help explore these beautiful algorithms in a TUI!

tree-lib icon tree-lib

Various data structures supported by a no heap splay tree written in C.

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.