Confusing addition behaviour

I’m confused
Looks like the 12 is matched to missing branches?
is this expected?


shouldn’t they add up to the same result?
AdditionBehaviour.gh (5.0 KB)

looks like expected behaviour to me

the very same thing happens if you create lines supplying point lists with different amount of elements:
the last element of the shortest list is used to complete the computation

Not really the same thing since your lists are flattened

1 Like

It is the same thing indeed. Try with grafted input points, it will happen as well. @inno gave you a good example.

Okay,
I expected this for a flattened list, but It surprises me that the branch index shifts when a match is missing. I’m still not convinced that this is the global behaviour for all components.

Longest list is global and those rules apply for items in branches and branches in trees.

2 Likes

I won’t dispute path master @Michael_Pryor’s word.
So… what’s the proper way to match branches before input?
Something cleaner than this?

Check this: Datatrees in Grasshopper 2.0

1 Like

I believe the component “add unmatched” is what you are looking for
it should come with the plugin TreeSloth, and creates the missing data branches comparing 2+ data inputs (the newly created branches can contain a null item or be just empty)