News for hackers. Stuff that matters.
Re:My Ideal Array Language by skydhash on Monday August 04, 2025 @01:03PM (#44788569)
Array Programming is an acquired taste, but once you do, solutions can be extremely simple, both to write and to explain.

Think about using matrix to describe geometric transformations instead of using standard functions.

Re:My Ideal Array Language by badlibrarian on Monday August 04, 2025 @03:52PM (#44790639)
You mean abstracted stuff like this instead of two lines of code that actually uses x and y?

  [ cos(θ)  -sin(θ)  0  0  ]
  [ sin(θ)   cos(θ)  0  0  ]
  [ 0        0       1  0  ]
  [ 0        0       0  1  ]
Re:My Ideal Array Language by ssivark on Monday August 04, 2025 @11:22PM (#44793995)
Yes, absolutely. Once you've expressed data as appropriate tensors (not all languages make this super convenient, unfortunately), it makes the implementation very readable, and easy to ensure that it's bug-free. It lets you see what is going on. Much better than futzing around with tensor components!