Exception has been thrown by the target of an invocation

Cryptic message when I use mass addition.

what could be the problem?
thanks

Have you examined all the numbers? What is the output of MA? It might still be accurate, even if one or more lines cause the error. What about trying Average?

I could answer these questions myself if you had posted a GH file. :roll_eyes:

3. Attach minimal versions of all the relevant files

1 Like

hi @Joseph_Oster ,
The output of MassAddition is incorrect.
Average works ok

Here’s the GH file
target invocation 250207.gh (52.3 KB)

Large numbers :interrobang:


yeah, well, i calculate numbers like this all the time. Sometimes it works sometimes not ??.. It becomes totally unreliable…

Is there any way to use expression ?

Measuring in millimeters? Ridiculously large numbers as far as I’m concerned, switch to meters?
Or use Python instead of MA to add them up.

Do I win a prize :question:

1 Like

No @Joseph_Oster you don’t win the prize.

Because I’m not looking for a workaround. I’m sure there are many ways to solve this.
This is not what I’m after.

I simply want to know why do I get the error on large numbers with this component.

seems like it’s an error given by the bounds of signed int32 type. That component should be updated to use 64bit integers and double precision floats, i reckon

a few items in, and it’s already past the maximum a signed int32 can handle ( It has a minimum value of -2,147,483,648 and a maximum value of 2,147,483,647)

there are other weird thing going on, like some sort of automatic type conversion. in any case, there’s nothing you can do. it’s simply a bug

Why doesn’t matter. What are you going to do about it :question:

Thank you @adel.albloushi for your explanation…
This is indeeed a bug and I would be happy to see it fixed. Maybe @DavidRutten can do somehting about it.

Since buildings are usually designed in mm , and architects are usually concerned with GFAs and NLAs , mass addition is used alot, with large numbers.

And having the wrong area of a building is quite a serious issue.

housing price in my city is around 2000€ per m2, which is absolutely crazy…
but now that you made me notice, 0.2 cents per squared mm is not that bad

imagine all the square mm you can buy with one coffee

around 600 mm2, which is just about the area of the bottom surface of an expresso cup

1 Like

One cent for 5 mm2? 500 mm2 for one euro?

So 600 / 500 is 1.2 euros for a cup of coffee? Just checking…

One million square millimeters (1000 * 1000) per square meter makes measuring buildings in square millimeters even more ridiculous than I realized.

Quick search:

most houses in Italy measure less than 100 square meters, with 61% of listings falling under this size category. […] The average residential property sold in North-East Italy measured 114.5 square meters in 2023.

So it makes only slightly more sense in Italy where houses are smaller (114.5 million mm2) than the USA where average new houses are 242 million mm2. :roll_eyes:

The average size of American houses , currently being built, is about 2,600 square feet (242 square meters)

1 Like

correct, that’s the average price for an espresso coffe :+1:

it’s so funny to think for the same amount of money you can either get an espresso, or the real estate equivalent area of the base of the cofee cup lol

1 Like

meaning you’re drinking real estate
figuratively, of course.

1 Like

please, don’t get it wrong; while the buildings are drawn in mm, the areas are calculated in m².

So the 50 surfaces average 25421 meters on each side? Sounds unlikely.

Or is it 34000+ meters on each side?

Python is correct Mass Addition is not.
That’s the only point I want to make. There’s a bug in Mass Addition.

Yes, there appears to be a bug in MA, but you would have never encountered it if your surface areas used square meters instead of square millimeters.