4 ms·
I don't know if Nim would be my first choice for a future scientific computing language. I think I'd be more focused on Julia or, recently, Crystal. Julia has
by gravypod 9y ago
I don't know if Nim would be my first choice for a future scientific computing language. I think I'd be more focused on Julia or, recently, Crystal.
Julia has some extreme magic that it can do to make your life easy. Crystal will attract the Ruby-like crowd of people who will create very neat and effective libraries.
- dom96 9y agoI disagree (but then again I am biased). I think Nim has a chance of attracting the Python-like crowd of people (plus Python has some very good scientific libraries like pandas) and I would be willing to bet that Nim's ability to perform magic surpasses that of Julia (or at least is equivalent). Edit: Shameless plug. My book, Nim in Action, is 50% off today with code HalloweenPB50 (From Manning). Perfect opportunity to grab a copy and learn Nim :) https://book.picheta.me/ https://book.picheta.me/
- dnautics 9y agoDoes Nim have first class distributed computing primitives? For embarrassingly parallel operations, I can deploy on a slurm provisioned cluster on a supercomputer in about 5 lines of native Julia. There's a lot of really nice "magic" in Julia. I implemented an experimental numerical system (a binary representation of real numbers) and after generating the +-x/ operations, I had complex numbers, Fourier transforms, and lu decomposition for free. With the macro system I then wrote a library that let's me generate verilog code and built a hardware implementation of the number system and deployed comprehensive tests cross correlating the results of all operations across native Julia, hardware simulation in Julia,and verilog version transpiled through verilator. I wanted to play around with Mary Wootters' discoveries about Reed Solomon encoding, so getting working Reed Solomon code over arbitrary galois fields was as simple as building the type rules and basic +-x/ and then again using matrix solving to solve erasures (in this case you can tell the type system there is no order to the type so it doesn't do partial pivoting). Then I needed to do some brute force searching of a large parameter space. The core program for this search is about 25 lines of code in the main loop, which reads like simple math statements out of a well written text, and the backing galois field and Reed Solomon libraries are about 100 and 50 lines, respectively.