by mrv_asura on 4/14/23, 11:38 AM with 46 comments
by bmc7505 on 4/15/23, 3:56 AM
[1]: https://papers.nips.cc/paper/2018/file/0a1bf96b7165e962e90cb...
[2]: https://www.youtube.com/watch?v=IbTRRlPZwgc
[3]: https://compcalc.github.io/public/laue/tensor_derivatives.pd...
by FabHK on 4/15/23, 5:59 AM
You want to solve Ax = b approximately. So, minimise the two-norm |Ax-b|, or equivalently, |Ax-b|^2, or equivalently (Ax-b)ᵀ(Ax-b) = xᵀAᵀAx - 2xᵀAᵀb + bᵀb.
How to minimise it? Easy, take the derivative wrt the vector x and set to zero (the zero vector):
2AᵀAx - 2Aᵀb = 0, so x = (AᵀA)⁻¹ Aᵀb.
(Note: that's the mathematical formulation of the solution, not how you'd actually compute it.)
by eachro on 4/15/23, 1:31 AM
by hgibbs on 4/15/23, 5:03 AM
by TinkersW on 4/16/23, 8:21 AM
Also the output is pretty gross, wish it had an option for a statically typed language.
Also wtf? It doesn't have sqrt? Have to write it in power form..sigh
Also seems to also not grok values with decimal points as the power, so you have to write it as a fraction..sigh..why math people..why?
Also why can you only select the output for 1 value at a time? For instance if we have a 3d position, we want gradient for x/y/z not just 1 of them..
by Aardwolf on 4/15/23, 12:13 PM
In an example they use X' for transpose and it works.
But if I try A' * A, it either becomes just A * A, or it shows nothing and says " This 4th order tensor cannot be displayed as a matrix. See the documentation section for more details."
The documentation also doesn't show how to enter the transpose operator.
by keithalewis on 4/15/23, 8:40 AM
Doesn't this cover all examples presented?
by tpoacher on 4/15/23, 12:17 PM
It should be derivatives "with" matrices, not "of", in my mind.
Not that it matters in practice, but ... if there's one field where precision of language matters, it should have been mathematics. So it bothers me.
by bobsmooth on 4/15/23, 1:55 AM
by pkoird on 4/15/23, 2:50 AM
by amelius on 4/15/23, 12:02 PM