Scalar and Vector Math Node Improvements

Backstory from an user perspective

The Shader and Geometry nodes are definitely my favorite parts of blender with their immense power and flexibility, however I find my self at times finding them the most frustrating part of blender. Simple math operations take a LONG time to do especially when you need to chain together results of other operations and use them several times. Not only does it take a long time to do it gets incredibly confusing and messy to the point where you’re not really sure what is going on anymore.

I’ve included a picture of an work in progress project where I’m using blender to create a mobius strip for use in animations for math videos. Which includes only some of the math I’m using. Overall what I’m doing is extremely simple where I’m rotating around the x axis as x increases. But the math nodes make this simple operation incredibly time consuming and complex to perform.

For most use cases sure, an user might only need to do a couple simple operations however, I believe that the math nodes can become even easier even for those users.

Improvements suggestions to the math nodes

First thing is I think that most of the operation boxes need to be removed entirely and use a more standardized way of reading math inputs. Replace these boxes with a single node that takes any amount of inputs that are named variables. IE when an user plugs an input blender assigns it a name a, b, c , etc. These variable names can be renamed by the user. Then the user types their math operation into an user field. if they wanted to multiply a and b and add it to the sine of c they would simply type “ab + sin(c)” This would remove 3 or 4 nodes in the workflow entirely which would also speed up the time required to do the operation. This way of doing math operations would also be standardized with other software, MatLab, Wolfram Alpha, GNUOctave etc.

A second suggestion would be adding test fields for problem solving. An example of this would be reading out the value of the output. Currently the only way to really test is by sending parts of your nodes to the output, which is not ideal. The reason it would be better is because you would be more easily able to narrow down where the problem is rather than having an entire set of nodes being wrong and not knowing where in that set of nodes the problem could be.

Improvements to vector math
I think one last potential improvement would be doing the same thing to the vector math operations and also adding a new feature entirely which is the ability to do matrix math. For some use cases this would be easier and cleaner than doing the separate XYZ node and combine XYZ node.

Thanks for your amazing software and I would also love to see other suggestions and ideas around improving the math nodes!

1 Like

With the logic of named variables and written expressions, you completely break the meaning of the block system…
Why can’t you always combine and group individual operations, signing input and output data, … as programmers?
This is not a mat lab
if you really need matrices now, you can create them using vectors (yes, it’s dirty, and I’m also waiting for their full-fledged version of matrix type)