ts (that should make whole structure rigid body, right?).
Questions
1
In KarambaManual there is component called "BeamJoint" but i dont have it is it available only in pro version?
2
Is there other method form makeing my structure rigid body?
3
Should all lines be flatter before going to "LineToBeam" component. Unfortunately my system crash when i try to do that
Best,
karol…
road axis. Polyline
Algorithm:
Contour line on a Mesh(A).(RCE: Contour line on Mesh)
MultiOffset on a Polyline.(RE: Multi-Offset)
Search for intersections between the axis of the road and primary contours lines.(RCE: Search Curve to Curve)
Axis interpolation on the points of intersection.(RCE: Curve Interpolation)
Divide curve on a vertical plane.(RCE : Plane on Curve)
For a open curve t parameter is 0 and 1(default).
Road Profile.(RCE: Road Profile)
Cut & Fill Profile(RCE :Cut & Fill Profile)
Join curve cut and fill profile.
Closed curve profile.(RCE: Closed Curve)
3D Modeling Cut & Fill Road .
Bounding box of a main project.(RCE :Bounding box)
Creating base of a mesh in main project.
Boolean operation to the cut & fill road.
Volume and display.
Optimization with Galapagos .
Study A
Parameter= Radius on Multi-Offset component.
Study B
Parameter= Radius on Multi-Offset component.
Move Interpolation point on Search Curve to Curve component.
Add a new components for move interpolation points with gene pool.
Optimization.
Study C
Parameter= Radius on Multi-Offset component.
Move Interpolation point on Search Curve to Curve component.
Length of road on Road Profile component
Add a Tree Repetition component(RCE).
Optimization.
Example available in bottom of this post...
[EXEMPLE_Français] Optimisation Route Déblais & Remblais avec Galapagos.
But:
Dans cet exemple nous allons voir comment utiliser RCE(RhinoCivil Engineering) dans une étude d'optimisation de déblais et de remblais sur une route.
Données:
Maillage représentant le terrain. Mesh (A)
Courbe représentant l'axe de la route. Polyline
Algorithme :
Courbe de niveaux sur le maillage du terrain Mesh (A).(RCE :Courbes de Niveaux Maillage)
Multiple conges sur l’axe de la route Polyline.(RCE :Multi-Conges)
Recherche d ‘intersections entre l’axe de la route et les courbes de niveaux primaires.(RCE :Recherche d’intersection Courbe sur Courbe)
Interpolation de l’axe sur les points d’intersections.(RCE :Interpolation de Courbe)
Division de la courbe par un plan vertical.(RCE : Plan sur Courbe)
Pour une courbe ouverte le paramètre t est 0 et 1.
Dessin de profils routier.(RCE :Profil Routier)
Dessin de profils déblais et remblais.(RCE :Profil déblais & remblais simple)
Joindre courbe de profils déblais et de remblais.
Fermer courbe de profil.(RCE : Fermer Courbe)
Modélisation de la route en déblais et en remblais.
Création de la boite de contour du projet.(RCE :Boîte)
Création du socle du Terrain dans la zone du projet.
Opération booléenne pour la route en déblais et en remblais.
Calcul de volume et affichage.
Optimisation avec Galapagos .
Etude A
Paramètre= Rayon du composant Multi-Conges
Etude B
Paramètre= Rayon du composant Multi-Conges
Déplacement des points d'interpolations.
Ajouts de nouveau composant pour le déplacement des points.
Optimisation.
Etude C
Paramètre= Rayon du composant Multi-Conges
Déplacement des points d'interpolations.
Largeur de la route sur le composant Profil routier
Ajout du composant répétition d'arbre (RCE).
Optimisation.
EXEMPLE_RCE OptimisationRoute[Demo A] FR.gh
EXEMPLE_RCE OptimisationRoute[Demo B] FR.gh
EXEMPLE_RCE OptimisationRoute[Demo C] FR.gh…
nkels bei Zerlegung in 2 Dreiecke'Zeichnen der Zerlegung nach dem kleineren Winkel 'Eingabe: 4 Punkte im Raum 'Peter Mayrhofer 05-2007'==================================================Sub Main() Dim arrPts 'Array der 4 Eingabepunkte Dim arrN1, arrN2 'Normalvektoren einer Zerlegung in 2 Dreiecke Dim winkel1, winkel2, wmin, wmax 'Winkel bei gemeinsamer Kante Dim pi, grad pi = 4*Atn(1): grad = 180/pi 'Eingabe arrPts = GetPoints(,, "4 Punkte eingeben..." ,, 4)'Punkte 0,1,2,3 'Berechnung Winkel1 bei Zerlegung mit gemeinsamer Kante [1,3] arrN1 = VectorUnitize(VectorCrossProduct(VectorCreate(arrPts(0), arrPts(1)),VectorCreate(arrPts(0), arrPts(3)))) arrN2 = VectorUnitize(VectorCrossProduct(VectorCreate(arrPts(2), arrPts(3)),VectorCreate(arrPts(2), arrPts(1)))) If VectorCompare (arrN1, arrN2) Then winkel1 = 180 'Das Viereck ist planar! MessageBox "*Viereck ist planar*" Exit Sub Else winkel1 = Arccos(VectorDotProduct(arrN1, arrN2))*grad End If 'Berechnung Winkel2 bei Zerlegung mit gemeinsamer Kante [0,2] arrN1 = VectorUnitize(VectorCrossProduct(VectorCreate(arrPts(1), arrPts(2)),VectorCreate(arrPts(1), arrPts(0)))) arrN2 = VectorUnitize(VectorCrossProduct(VectorCreate(arrPts(3), arrPts(0)),VectorCreate(arrPts(3), arrPts(2)))) winkel2 = Arccos(VectorDotProduct(arrN1, arrN2))*grad 'Winkelvergleich und Ausgabemeldung If winkel1 <= winkel2 Then wmin = winkel1 : wmax = winkel2 AddLine arrPts(0), arrPts(2) 'Dreieckszerlegung bei kleinerem Winkel Else wmin = winkel2 : wmax = winkel1 AddLine arrPts(1), arrPts(3) 'Dreieckszerlegung bei kleinerem Winkel End If wmin = Fix(wmin*100)/100: wmax = Fix(wmax*100)/100 MessageBox "*Viereck nicht planar*"&vbNewLine& _ " Minimalwinkel = "&wmin&"°"&vbNewLine& _ " Maximalwinkel = "&wmax&"°"End SubMain 'Aufruf des Hauptprogramms
'================================='Funktionen aus der Vector-Library'================================='Make a vector from two 3D pointsPublic Function VectorCreate(p1, p2) VectorCreate = Null If Not IsArray(p1) Or (UBound(p1) <> 2) Then Exit Function If Not IsArray(p2) Or (UBound(p2) <> 2) Then Exit Function VectorCreate = Array(p2(0) - p1(0), p2(1) - p1(1), p2(2) - p1(2))End Function
'Unitize a 3D vectorPublic Function VectorUnitize(v) VectorUnitize = Null If Not IsArray(v) Or (UBound(v) <> 2) Then Exit Function Dim dist, x, y, z, x2, y2, z2 x = v(0) : y = v(1) : z = v(2) x2 = x * x : y2 = y * y : z2 = z * z dist = x2 + y2 + z2 If (dist < 0.0) Then Exit Function dist = Sqr(dist) x = x / dist y = y / dist z = z / dist VectorUnitize = Array(x, y, z)End Function
'Return the dot product of two 3D vectorsPublic Function VectorDotProduct(v1, v2) VectorDotProduct = Null If Not IsArray(v1) Or (UBound(v1) <> 2) Then Exit Function If Not IsArray(v2) Or (UBound(v2) <> 2) Then Exit Function VectorDotProduct = v1(0) * v2(0) + v1(1) * v2(1) + v1(2) * v2(2)End Function
'Return the cross product of two 3D vectorsPublic Function VectorCrossProduct(v1, v2) VectorCrossProduct = Null If Not IsArray(v1) Or (UBound(v1) <> 2) Then Exit Function If Not IsArray(v2) Or (UBound(v2) <> 2) Then Exit Function Dim x, y, z x = v1(1) * v2(2) - v1(2) * v2(1) y = v1(2) * v2(0) - v1(0) * v2(2) z = v1(0) * v2(1) - v1(1) * v2(0) VectorCrossProduct = Array(x, y, z)End Function
'Function: ArccosFunction Arccos(x) Arccos = Atn(-x / Sqr(-x * x + 1)) + 2 * Atn(1)End Function
'Compare two 3D vectors for equalityPublic Function VectorCompare(v1, v2) VectorCompare = False If Not IsArray(v1) Or (UBound(v1) <> 2) Then Exit Function If Not IsArray(v2) Or (UBound(v2) <> 2) Then Exit Function If v1(0) = v2(0) And v1(1) = v2(1) And v1(2) = v2(2) Then VectorCompare = True End IfEnd Function
…