i want to divide the shape with a choosen nr. of subdivision ( NR ) but i want to distribute the witdh of each panel in order to have all panels with same aspect ratio ( i.e. proportionals )
i am trying to use the same formula used for wings in order to estimate the aspect ratio, being the shape tapered it is convenient to use the formula based on Area and width : L^2/Area to calculate aspect ratio
so far i am able only to divide the shape in equal portions with similar width and when so i do the aspect ration and different from left to right are not proportional , i.e. the dont have same aspect ratio.
can anyone help me to create a code that calculate the different L in order to have panels all with the same aspect ratio from left panel to right ? so far the values are these to follow
the left panel is thinner while the right one is fatter; i tried to calculate the values “L1,2…n” by using genetic algorithm ( galapagos ) to estimate the proper panels width but the calculation takes forever and results not as desired.
i think best way to do it is to create a loop the populate a list of values but for this i need code scripting but my small experience with python is not enough.
in short my GOAL is to decide the number of subdivision and i would like the script to calculate the values of Ls in order to have a proportional subdivision of the shape
if anyone can give me some suggestion i’d really appreciate
I wrote a 50 lines post detailing the reasons this wouldn’t work well with Galapagos, and the I put it down and look like it produces some fine results
Hello
I corrected your way of making stripes with non parallel line. For me it is an error as you measure the width with upper curve and if you use lower curve you will have another result.
I tried a geometric equation solving. The idea is to make an integral and resolve the results with geometric intersections.
but there’s one thing I can’t explain… I would expect numbers to be more and more “precise” the more initial divisions you use (and the more you of course lower Rhino Tolerance) as the initial surface is divided by more and thinner vertical slices, which means the curve representing the integrals is more and more defined by a higher number of points
I see the values of your definition “converging” when the number of divisions is increased, and I would expect the respective aspect ratios values to get “perfect”
so I’m a bit astonished seeing Galapagos to create “more similar” distribution of aspect ratios?
I agree with you. There is a glitch somewhere. Is it the Nurbs curve representing the integral ? Or is it the ratio that I integrate wrongly? I suspect the last but I was a bit lazy doing the maths.
But for fabrication things 2 or 3 decimals seems enough! I think both solutions are good and both corrected the fact that lines were not parallel.
an analytical approach would give more precise values, but then integrating nurbs equations is a nightmare.
another approach would be to use an iterative formula for approximating the sum of aspect ratios with respect to length by (ever smaller) stepwise intervals - basically a quantized integral → which for all intents and purposes it’s what you’ve done, more or less
Hi Laurent and many many thanks for your proposed solution. I am astonished by your logic , it’s a very smart and efficient logic and the results are more than good to me. In addition to this the script is very light !!!
thanks a lot , i really appreciate !!!
ps the small differences are not a problem to me yet i want to investigate on the reason for this…
HI Abel and thanks for your suggestion , yes your concept was the one i was trying to implement , i made some test with hoopsnake with a incremental loop but of course the increment need to be made through definition of a starting value , increment criteria and tolerance to be added to reach the convergence.
on the test made this solution was taking very long , yes it depend on the logic used for the iterations , a small value for the increment step was a must in order to reduce the error but this was increasing the calculation time.
I was thinking about using some written code made for example with python since the loops in python seems to be faster thatn hoopsnake but i am having a hard time to make them due to my lack of experience with written languages.
when i will have something that work i will share it. cheers