Saw this -
https://news.ycombinator.com/item?id=16572793
Linked to a paper talking about “tree hashing” -
The blake2 docs also talk about “tree hashing” here -
https://blake2.net/
BLAKE2 offers these algorithms tuned to your specific requirements, such as keyed hashing (that is, MAC or PRF), hashing with a salt, updatable or incremental tree-hashing, or any combination thereof.
Currently in the Grin MMR implementation we simply concatenate two nodes together and hash the result. We also include the position of the leaf element in the MMR as part of the value being hashed.
The links above suggest there may be a better way of doing this (or at least a standard way?) in a tree like structure?
Seems like something that may be worth exploring and investigating some more.