I did a little trick. I was too lazy to start the matrix multiplication function in DataGraph and didn’t have time. I tried LaTeX, Python (Mathplotlib, etc.), Mathlab, and got the wrong thing everywhere. The situation was saved by a feature of DataGraph, when there is a gap in the x&y columns, the line is not drawn. So I calculated everything in Swift, rotated source matrices by necessary angles, recorded the rotated matrices into files and then displayed them as DataGraph graphics. That turned out to be fast and of high quality. But if you have time and a powerful computer, you can do it in DataGraph. So far, ImageTank is not as good as the way I described. ))))))