Can Galapagos Fitness input take more than 1 input? I hold Shift key and try to connect another input and it just deleted the other input. Are there any way to put more than 1 Fitness input in Galapagos? Thank you!
No, Galapagos takes only one Fitness value. But you can “join” several values (do some math) and assign the result into a Num parameter and feed that “compound” value into Galapagos.
Galapagos only accepts one fitness funcion, however we can add multiple fitness and combine them as one. FIrst, decide if you would like to maximize or minimize your fitness function. After that, You can use an Evaluate component to create relations between multiple fitness. You can also remap the number to provide a weighted value for each fitness parameter. There is a really interesting explanation by @DavidRutten here - http://www.grasshopper3d.com/forum/topics/galapagos-multiple-fitness
Hey. I’m trying to apply David’s explanation of the multiple fitness functions to my case but somehow I believe that it is not working properly. Maybe you can point what I’m doing wrong .
The case is:
I would like to design an optimal truss. Optimal means for me: minimal weight (M), minimal deflecation (d) with the stress level ( C ) on the maximum assumed acceptable level (C=180)
So I did my parametric truss.
The genes are:
Height of the truss
Diameter of the tubular cross section
Thickness of the tubular cross section
Number of division.
In the minimum and the maximum of every slider I put a number which looked reasonable for me.
I used your guidlines to write an fitness function and it looks like this:
The output i received after analysis is
If I understand well there is a number of possibilities for which C=180.
And only for this scope of solutions galapagos should choose the solution with the minimal “d” and “M”.
Why it is not doing this ?
Thank you in advance.
truss_003_Karamba_Galapagos_Function.gh (40.3 KB)
You have to understand that Genes and Fitness are not directly translated. They go through transcription from genotype to phenotype where the Number sliders change the fitness value based upon the Gh definition and this formula will only be helpful until there is a direct correlation between the sliders and fitness values.
what is 4793? Is it the domain of the number slider or is it the domain of possible fitness values? the minimum and maximum values that David talks about is not of the slider but the fitness values itself.
I would recommend you to run the solver a lot of times and record the final data for M, d and c in 3 separate panels. Try achieving as many random solutions as possible. The goal is to get a wide spectrum of the fitness landscape.
See, what we have to achieve is Reparametrize the fitness value. Because any slight change in “c” can easily override d because they have different denominators.
Once you have the data for the 3 fitness variables. Extract the bounds so you will have an idea of maximum & minimum possible value of C,d, M. And plugin those values in the formula.
I hope I was able to explain myself properly. Good luck
Hello. Thank you very much for your response.
4793 is the values range for d (values that “d” can possibly has in this circumstances). Similarly 6502 and 11616 - these are the ranges for M and C. Not the sliders domains, not the fitness values but the actual values wich d, C and M can be.