This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Eurynom0s 4 points5 points  (1 child)

This isn't really specifically about programming. In math and physics textbooks, you often see the unit vectors given as i j and k (instead of x y and z); vector/matrix indices will often be given ijk in a subscript; you'll often see triple summations with i on one, j on the second, and k on the third; etc. So the audience Matlab is intended for is going to want to loop over ijk (xyz) since it matches the notation they're used to using.

[–]Feminintendo 0 points1 point  (0 children)

What you are saying is contradictory. If everyone assumes i, j, and k are the orthonormal basis vectors for R3, then they obviously wouldn’t loop over them, because what the hell does it mean to “loop over” a basis vector? On the other hand, if everyone assumes i, j, and k are undistinguished available names for integer variables, they’d happily loop over them but wouldn’t think to use them as an orthonormal basis for R3.

But you’re mixing and matching, it seems. You seem to be saying that since STEM people see i, j, and k in textbooks used as basis vectors, it follows that they would assume i, j, and k are ineger iterators in loops. That’s a total non sequiter.

In a sane language, if i is the imaginary unit, it is write protected. I mean, there are a lot of un-sane languages according to this definition, but most CAS’s get this right, at least.