# Stage 2 - Obtain initial geometry RBF = stage2.geomextr(dens) # Visualize stage 2 visualize.stage2_3(RBF,5,2) #%% """ Optimize the shape of the geometry """ print("Stage 3 - Shape optimization") # Create stiffness matrices (per integration point) Kinit,Vinit,ic = FCM.Kinit() # Stage 3 - Shape optimization steps = 1 while steps<1.5: # Create quadtree integration band print("- (re)create quadtree integration band") iel,LSFip = FCM.quadtree_band(RBF,ic) # Shape optimization RBF = stage3.shapeopt(RBF,Kinit,Vinit,iel,LSFip) steps += 1 # Visualize stage 3 visualize.stage2_3(RBF,5,3) #%% """ End """ print("End")