Getting sometimes "Null" error in Optimo package during genetic algorithm optimization of truss height

Hi all,

I am working on a project where I am trying to find the most suitable height for a truss that I created in Dynamo using the Optimo package and a genetic algorithm. I have defined a fitness function that calculates the results of the newly created members.

However, during the optimization process, I sometimes encounter a “null” error in the function apply section eventough sometimes it finishes the optimization without error. This error interrupts the analysis and writes “null” for other values, making it difficult to continue the optimization.

Has anyone experienced this issue before or have any information about how to fix it? Any help would be greatly appreciated. Thank you!

1 Like

@ugur_yavan_61 ,

you have to get rid of it eiter you remove or replace it!

i like very much this codeBlock

x == null ? true : false
x == null ? 9999 : x

KR

Andreas

Thank you

1 Like