Benutzer-Werkzeuge

Webseiten-Werkzeuge


modellingcomponents:functions

Unterschiede

Hier werden die Unterschiede zwischen zwei Versionen angezeigt.

Link zu dieser Vergleichsansicht

Beide Seiten der vorigen RevisionVorhergehende Überarbeitung
Nächste Überarbeitung
Vorhergehende Überarbeitung
Nächste ÜberarbeitungBeide Seiten der Revision
modellingcomponents:functions [2021/06/09 09:39] – [Special fuction useful for 3D geometric calculations] olivermodellingcomponents:functions [2021/09/28 15:52] – [normalize()] oliver
Zeile 233: Zeile 233:
  
    dist(A,B)    dist(A,B)
 +   
 +==== ddist() ====
 +
 +Directed distance between two points.
 +The first two arguments define the start point and the end point of a vector. The distance of the two points is calculated. The third argument defines a vector. If the vector defined by the first two points and this reference vector includes an angle less-90 or more than 90 degree than the result is negative else positive.
 +
 +Types:
 +
 +^ Argument 1 ^ Argument 2 ^ Argument 3 ^ Result ^
 +| 3d vector | 3d vector | 3d vector | double |
 +
 +=== Examples ===
 +
 +   ddist(A,B, ref)
 ==== vec() ==== ==== vec() ====
  
Zeile 295: Zeile 309:
 If the argument is a tuple with 3 elements, it is interpreted as a vector and the result is the normalized vector (length of the vector is set to 1). If the argument is a tuple with 3 elements, it is interpreted as a vector and the result is the normalized vector (length of the vector is set to 1).
  
-^ Argument  Result +^ Argument ^ Type ^ Description
-| 3d vector | real |+^ 1 | 3d vector | Normalize the vector. |
  
 ==== mid() ==== ==== mid() ====
Zeile 327: Zeile 341:
 ^ 4 | Direction to define the second line | VECTOR_3D | ^ 4 | Direction to define the second line | VECTOR_3D |
  
-==== pocL() ====+==== PocL() ====
  
 Point of contact straight line: The first two arguments define a straight line. The first is a point on this line and the second defines the direction of the line. A perpendicular is dropped from the point defined by the third point to this line and the result value is the point of contact in the straight line. Point of contact straight line: The first two arguments define a straight line. The first is a point on this line and the second defines the direction of the line. A perpendicular is dropped from the point defined by the third point to this line and the result value is the point of contact in the straight line.
Zeile 341: Zeile 355:
    pocL(A,B,C)    pocL(A,B,C)
 </code>    </code>   
-==== pocP() ====+==== PocP() ====
  
 Point of contact plane: The first two arguments define a plane. The first is a point in this plane and the second defines the direction of a normal to this plane. A perpendicular is dropped from the point defined by the third point to this plane and the result value is the point of contact in the plane. Point of contact plane: The first two arguments define a plane. The first is a point in this plane and the second defines the direction of a normal to this plane. A perpendicular is dropped from the point defined by the third point to this plane and the result value is the point of contact in the plane.
Zeile 353: Zeile 367:
  
 <code> <code>
-   pocP(A,B,C)+   PocP(A,B,C)
 </code>  </code> 
  
Zeile 465: Zeile 479:
 ==== t() ==== ==== t() ====
 ==== mat4() ==== ==== mat4() ====
 +
 +==== R() ====
 +
 +Get a double component from a matrix defined by row and column index.
 +
 +**Arguments:**
 +
 +^ Argument ^ Type ^ Description ^
 +^ 1 | MATRIX_3X3D | Matrix to get double components from. |
 +^ 2 | INTEGER| row [0|1|2] |
 +^ 3 | INTEGER| column [0|1|2] |
 +
 +<code>
 +   R(TCPQ,0,1,2)
 +</code> 
 +===== Robotics functions =====
 +==== mdho() ====
 +Determines the Origin of a coordinate based on the modified Denavit-Hartenberg convention.
 +
 +**Arguments:**
 +
 +^ Argument ^ Type ^ Description ^
 +^ 1 | VECTOR_3D | Origin the previous coordinate system |
 +^ 2 | VECTOR_3D | Direction of the previous joint axis |
 +^ 3 | REAL| Displacement on the previous joint axis of the origin. Typically this is 0. |
 +^ 4 | VECTOR_3D | Point on the joint axis where the origin should be determined |
 +^ 5 | VECTOR_3D | Direction ofthe joint axis where the origin should be determined |
 +
 +=== Examples ===
 +
 +<code>
 +   mdhO(o1,v1,0.0,o2,v2)
 +</code> 
 +==== dhm() ====
 +Determines the 4x4 Matrix of the Denavit Hartenberg convention based the DH parameters.
 +
 +**Arguments:**
 +
 +^ Argument ^ Type ^ Description ^
 +^ 1 | REAL| theta |
 +^ 2 | REAL| alpha |
 +^ 3 | REAL| d |
 +^ 4 | REAL| r |
 +
 +
 +=== Examples ===
 +
 +<code>
 +   dhm(theta1, alpha1, d1, r1)
 +</code> 
modellingcomponents/functions.txt · Zuletzt geändert: 2021/11/09 11:22 von oliver

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki