DEV Community


Towel (C#)

zacharypatten profile image Zachary Patten ・1 min read

I have an open source library in C# that I am working on that I want to start advertising. It has generic mathematics, symbolic mathematics, generic data structures, generic algorithms, and more.

Even if you are not a C# developer, much of the code in my project is low-level code that could be useful in any language.

I want to get people to see it because nearly all the examples I see on GitHub are doing things wrong.

  • When writing generic data structures in C#, you should not use interfacing. You should use functional programming. This allows you to use any type in your data structures (even primitive types), and you can have multiple data structures of the same type that use different sorting algorithms.

  • When writing generic mathematics in C# you should not use interfacing with explicit implementations. You should use generic types, runtime compilation, and delegates.

  • When writing graph-searching algorithms you should not have to build an entire graph in order to perform an A* algorithm. You should use functional programming to build the graph as needed.

  • You do not need multiple data structures to sort along multiple dimensions. You can use my "omnitree" (and ND SPT) to perform multidimensional sorting in a single data structure (granted I need to optimize it more).

People need to break the barrier between functional programming and object oriented programming. They should be used side-by-side where appropriate.

If you give the code a look, I hope you like it. Feel free to ask me questions. :)

Discussion (0)

Editor guide