3 ms·
I'm not talking about matrices as in linear algebra, I'm talking about functions. If you interpret a vector or a matrix as a function of its indices, then
by enriquto 3y ago
I'm not talking about matrices as in linear algebra, I'm talking about functions. If you interpret a vector or a matrix as a function of its indices, then
B = α*A + β
means just
B(t) = α*A(t) + β
for all relevant t. This broadcasting is used everywhere in signal and image processing, and it would be extremely unnatural if your language forced you to write some monstrosity that modified the constant β so that it has the same type as A.
- medo-bear 3y ago> If you interpret a vector or a matrix as a function of its indices What exactly does this mean?
- enriquto 3y agoA vector v = (v[0], v[1], v[2], ..., v[100]) is exactly the same thing as a function v taking a number i and returning a value v[i]. Since you can sum scalars to functions, it is natural to sum scalars to vectors.
- medo-bear 3y agoPerhaps this is really a personal preference, but in maths I really dislike ambiguity. There are is just way better notation for this. For example Einstein notation or Rici calculus? Besides being succint, it is explicit and well understood. Even just using plain i,j indicies is not too cumbersome. But for a b scalars and A a matrix B = aA + b is not well defined.