MAPS-TFSS: Manipulating And Perceiving Simultaneously - Tactile Force Sensor Simulator

Enumerations

Utils::Algebra3D Namespace Reference

Utility functions for 3D vector operations and affine transformations. More...

Enumerations

enum  { Trans_NR_ENTRIES = 3, Rot_NR_ENTRIES = 9, TransRot_NR_ENTRIES = 12 }
 

Numbers of entries for arrays representing 3D quantities.

More...

Functions

Combine transformations

void RotMultRotAsRot (const double Ra[], const double Rb[], double R[])
 R <-- Ra * Rb.
static void TransMultTransAsTrans (const double Ta[], const double Tb[], double T[])
 T <-- Ta + Tb.
static void TransMultRotAsTransRot (const double T[], const double R[], double TR[])
 TR <-- T * R.
static void TransMultTransRotAsTransRot (const double T[], const double TR[], double TRresult[])
 TRresult <-- T * TR.
static void RotMultTransAsTransRot (const double R[], const double T[], double TR[])
 TR <-- R * T.
static void RotMultTransRotAsTransRot (const double R[], const double TR[], double TRresult[])
 TRresult <-- R * TR.
static void TransRotMultTransAsTransRot (const double TR[], const double T[], double TRresult[])
 TRresult <-- TR * T.
static void TransRotMultRotAsTransRot (const double TR[], const double R[], double TRresult[])
 TRresult <-- TR * R.
static void TransRotMultTransRotAsTransRot (const double TRa[], const double TRb[], double TR[])
 TRresult <-- TRa * TRb.
Vector operations

static double VecDotProduct (const double v1[], const double v2[])
 Computes the dot product of vectors v1 and v2.
static void VecCrossProduct (const double v1[], const double v2[], double v[])
 Computes the cross product of vectors v1 and v2 and stores the result in v.
static double VecNormSquared (const double v[])
 Computes the norm squared of the vector v.
static double VecNorm (const double v[])
 Computes the norm of the vector v.
static void VecUnit (const double v[], double vunit[])
 Computes the unit vector of v and stores the result in vunit.
static void VecScale (const double v[], const double s, double vscaled[])
 Scales the vector v by the scalar s and stores the result in vscaled.
static void VecAdd (const double v1[], const double v2[], double v[])
 Adds vectors v1 and v2 and stores the result in v.
static void VecSubtract (const double v1[], const double v2[], double v[])
 Subtracts v2 from v1 and stores the result in v.
Identities for translations and rotations

static void IdentityAsTrans (double T[])
 T is set to the identity for translations.
static void IdentityAsRot (double R[])
 R is set to the identity for rotations.
static void IdentityAsTransRot (double TR[])
 TR is set to the identity for translations and rotations.
Determine if specified transformation represents the identity transformation

static bool IdentitySameAsTrans (const double T[])
 Determine if T is the same as the identity translation.
static bool IdentitySameAsRot (const double R[])
 Determine if R is the same as the identity rotation.
static bool IdentitySameAsTransRot (const double TR[])
 Determine if TR is the same as the identity translation and rotation.
Copy transformations

static void TransAsTrans (const double x, const double y, const double z, double Tresult[])
 Set Tresult to the translation given by (x, y, z).
static void TransAsTrans (const double T[], double Tresult[])
 Copy the translation T to Tresult.
static void RotAsRot (const double R[], double Rresult[])
 Copy the rotation R to Rresult.
static void TransRotAsTransRot (const double TR[], double TRresult[])
 Copy the transformation TR to TRresult.
Determine if specified transformations are the same

static bool TransSameAsTrans (const double Ta[], const double Tb[])
 Determine if the translations Ta and Tb are the same.
static bool RotSameAsRot (const double Ra[], const double Rb[])
 Determine if the rotations Ra and Rb are the same.
static bool TransRotSameAsTransRot (const double TRa[], const double TRb[])
 Determine if the transformations TRa and TRb are the same.
Apply transformation to point

static void TransMultPoint (const double T[], const double p[], double pnew[])
 Apply translation T to point p and store result in pnew.
static void TransMultInvPoint (const double T[], const double p[], double pnew[])
 Apply translation T to the inverse of point p and store result in pnew.
static void InvTransMultPoint (const double T[], const double p[], double pnew[])
 Apply the inverse of the translation T to point p and store result in pnew.
static void InvTransMultInvPoint (const double T[], const double p[], double pnew[])
 Apply the inverse translation T to the inverse of point p and store result in pnew.
static void RotMultPoint (const double R[], const double p[], double pnew[])
 Apply rotation R to point p and store result in pnew.
static void RotMultInvPoint (const double R[], const double p[], double pnew[])
 Apply rotation R to the inverse of point p and store result in pnew.
static void InvRotMultPoint (const double R[], const double p[], double pnew[])
 Apply the inverse of rotation R to point p and store result in pnew.
static void InvRotMultInvPoint (const double R[], const double p[], double pnew[])
 Apply the inverse or rotation R to the inverse of point p and store result in pnew.
static void TransRotMultPoint (const double TR[], const double p[], double pnew[])
 Apply transformation TR to point p and store result in pnew.
static void TransRotMultInvPoint (const double TR[], const double p[], double pnew[])
 Apply transformation TR to the inverse of point p and store result in pnew.
static void InvTransRotMultPoint (const double TR[], const double p[], double pnew[])
 Apply the inverse of the transformation TR to point p and store result in pnew.
static void InvTransRotMultInvPoint (const double TR[], const double p[], double pnew[])
 Apply the inverse of the transformation TR to the inverse of point p and store result in pnew.
Inverse transformations

static void InvTransAsTrans (const double T[], double Tresult[])
 Set Tresult as the inverse of the translation T.
static void InvRotAsRot (const double R[], double Rresult[])
 Set Rresult as the inverse of the rotation R.
static void InvTransRotAsTransRot (const double TR[], double TRresult[])
 Set TRresult as the inverse of the transformation TR.
Validity of transformation

static bool RotIsValid (const double R[])
 Determine if R represent a valid rotation.

Detailed Description

Utility functions for 3D vector operations and affine transformations.

Author:
Erion Plaku

Enumeration Type Documentation

anonymous enum

Numbers of entries for arrays representing 3D quantities.

Author:
Erion Plaku
Enumerator:
Trans_NR_ENTRIES 

Defines number of entries for representing 3D translations.

Rot_NR_ENTRIES 

Defines number of entries for representing 3D rotations in matrix form.

TransRot_NR_ENTRIES 

Defines number of entries for representing 3D translations and rotations.

Definition at line 56 of file Algebra3D.hpp.


Function Documentation

static void Utils::Algebra3D::IdentityAsRot ( double  R[]  )  [inline, static]

R is set to the identity for rotations.

Author:
Erion Plaku

Definition at line 186 of file Algebra3D.hpp.

static void Utils::Algebra3D::IdentityAsTrans ( double  T[]  )  [inline, static]

T is set to the identity for translations.

Author:
Erion Plaku

Definition at line 177 of file Algebra3D.hpp.

static void Utils::Algebra3D::IdentityAsTransRot ( double  TR[]  )  [inline, static]

TR is set to the identity for translations and rotations.

Author:
Erion Plaku

Definition at line 196 of file Algebra3D.hpp.

static bool Utils::Algebra3D::IdentitySameAsRot ( const double  R[]  )  [inline, static]

Determine if R is the same as the identity rotation.

Author:
Erion Plaku

Definition at line 228 of file Algebra3D.hpp.

static bool Utils::Algebra3D::IdentitySameAsTrans ( const double  T[]  )  [inline, static]

Determine if T is the same as the identity translation.

Author:
Erion Plaku

Definition at line 216 of file Algebra3D.hpp.

static bool Utils::Algebra3D::IdentitySameAsTransRot ( const double  TR[]  )  [inline, static]

Determine if TR is the same as the identity translation and rotation.

Author:
Erion Plaku

Definition at line 246 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvRotAsRot ( const double  R[],
double  Rresult[] 
) [inline, static]

Set Rresult as the inverse of the rotation R.

Author:
Erion Plaku

Definition at line 527 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvRotMultInvPoint ( const double  R[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply the inverse or rotation R to the inverse of point p and store result in pnew.

Author:
Erion Plaku

Definition at line 453 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvRotMultPoint ( const double  R[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply the inverse of rotation R to point p and store result in pnew.

Author:
Erion Plaku

Definition at line 439 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvTransAsTrans ( const double  T[],
double  Tresult[] 
) [inline, static]

Set Tresult as the inverse of the translation T.

Author:
Erion Plaku

Definition at line 516 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvTransMultInvPoint ( const double  T[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply the inverse translation T to the inverse of point p and store result in pnew.

Author:
Erion Plaku

Definition at line 400 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvTransMultPoint ( const double  T[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply the inverse of the translation T to point p and store result in pnew.

Author:
Erion Plaku

Definition at line 389 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvTransRotAsTransRot ( const double  TR[],
double  TRresult[] 
) [inline, static]

Set TRresult as the inverse of the transformation TR.

Author:
Erion Plaku

Definition at line 543 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvTransRotMultInvPoint ( const double  TR[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply the inverse of the transformation TR to the inverse of point p and store result in pnew.

Author:
Erion Plaku

Definition at line 497 of file Algebra3D.hpp.

static void Utils::Algebra3D::InvTransRotMultPoint ( const double  TR[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply the inverse of the transformation TR to point p and store result in pnew.

Author:
Erion Plaku

Definition at line 487 of file Algebra3D.hpp.

static void Utils::Algebra3D::RotAsRot ( const double  R[],
double  Rresult[] 
) [inline, static]

Copy the rotation R to Rresult.

Author:
Erion Plaku

Definition at line 290 of file Algebra3D.hpp.

static bool Utils::Algebra3D::RotIsValid ( const double  R[]  )  [inline, static]

Determine if R represent a valid rotation.

Author:
Erion Plaku

Definition at line 667 of file Algebra3D.hpp.

static void Utils::Algebra3D::RotMultInvPoint ( const double  R[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply rotation R to the inverse of point p and store result in pnew.

Author:
Erion Plaku

Definition at line 425 of file Algebra3D.hpp.

static void Utils::Algebra3D::RotMultPoint ( const double  R[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply rotation R to point p and store result in pnew.

Author:
Erion Plaku

Definition at line 411 of file Algebra3D.hpp.

void Utils::Algebra3D::RotMultRotAsRot ( const double  Ra[],
const double  Rb[],
double  R[] 
)

R <-- Ra * Rb.

Author:
Erion Plaku
static void Utils::Algebra3D::RotMultTransAsTransRot ( const double  R[],
const double  T[],
double  TR[] 
) [inline, static]

TR <-- R * T.

Author:
Erion Plaku

Definition at line 600 of file Algebra3D.hpp.

static void Utils::Algebra3D::RotMultTransRotAsTransRot ( const double  R[],
const double  TR[],
double  TRresult[] 
) [inline, static]

TRresult <-- R * TR.

Author:
Erion Plaku

Definition at line 611 of file Algebra3D.hpp.

static bool Utils::Algebra3D::RotSameAsRot ( const double  Ra[],
const double  Rb[] 
) [inline, static]

Determine if the rotations Ra and Rb are the same.

Author:
Erion Plaku

Definition at line 329 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransAsTrans ( const double  T[],
double  Tresult[] 
) [inline, static]

Copy the translation T to Tresult.

Author:
Erion Plaku

Definition at line 279 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransAsTrans ( const double  x,
const double  y,
const double  z,
double  Tresult[] 
) [inline, static]

Set Tresult to the translation given by (x, y, z).

Author:
Erion Plaku

Definition at line 267 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransMultInvPoint ( const double  T[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply translation T to the inverse of point p and store result in pnew.

Author:
Erion Plaku

Definition at line 378 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransMultPoint ( const double  T[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply translation T to point p and store result in pnew.

Author:
Erion Plaku

Definition at line 367 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransMultRotAsTransRot ( const double  T[],
const double  R[],
double  TR[] 
) [inline, static]

TR <-- T * R.

Author:
Erion Plaku

Definition at line 573 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransMultTransAsTrans ( const double  Ta[],
const double  Tb[],
double  T[] 
) [inline, static]

T <-- Ta + Tb.

Author:
Erion Plaku

Definition at line 562 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransMultTransRotAsTransRot ( const double  T[],
const double  TR[],
double  TRresult[] 
) [inline, static]

TRresult <-- T * TR.

Author:
Erion Plaku

Definition at line 583 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransRotAsTransRot ( const double  TR[],
double  TRresult[] 
) [inline, static]

Copy the transformation TR to TRresult.

Author:
Erion Plaku

Definition at line 299 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransRotMultInvPoint ( const double  TR[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply transformation TR to the inverse of point p and store result in pnew.

Author:
Erion Plaku

Definition at line 477 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransRotMultPoint ( const double  TR[],
const double  p[],
double  pnew[] 
) [inline, static]

Apply transformation TR to point p and store result in pnew.

Author:
Erion Plaku

Definition at line 467 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransRotMultRotAsTransRot ( const double  TR[],
const double  R[],
double  TRresult[] 
) [inline, static]

TRresult <-- TR * R.

Author:
Erion Plaku

Definition at line 634 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransRotMultTransAsTransRot ( const double  TR[],
const double  T[],
double  TRresult[] 
) [inline, static]

TRresult <-- TR * T.

Author:
Erion Plaku

Definition at line 621 of file Algebra3D.hpp.

static void Utils::Algebra3D::TransRotMultTransRotAsTransRot ( const double  TRa[],
const double  TRb[],
double  TR[] 
) [inline, static]

TRresult <-- TRa * TRb.

Author:
Erion Plaku

Definition at line 644 of file Algebra3D.hpp.

static bool Utils::Algebra3D::TransRotSameAsTransRot ( const double  TRa[],
const double  TRb[] 
) [inline, static]

Determine if the transformations TRa and TRb are the same.

Author:
Erion Plaku

Definition at line 347 of file Algebra3D.hpp.

static bool Utils::Algebra3D::TransSameAsTrans ( const double  Ta[],
const double  Tb[] 
) [inline, static]

Determine if the translations Ta and Tb are the same.

Author:
Erion Plaku

Definition at line 317 of file Algebra3D.hpp.

static void Utils::Algebra3D::VecAdd ( const double  v1[],
const double  v2[],
double  v[] 
) [inline, static]

Adds vectors v1 and v2 and stores the result in v.

Author:
Erion Plaku

Definition at line 146 of file Algebra3D.hpp.

static void Utils::Algebra3D::VecCrossProduct ( const double  v1[],
const double  v2[],
double  v[] 
) [inline, static]

Computes the cross product of vectors v1 and v2 and stores the result in v.

Author:
Erion Plaku

Definition at line 92 of file Algebra3D.hpp.

static double Utils::Algebra3D::VecDotProduct ( const double  v1[],
const double  v2[] 
) [inline, static]

Computes the dot product of vectors v1 and v2.

Author:
Erion Plaku

Definition at line 83 of file Algebra3D.hpp.

static double Utils::Algebra3D::VecNorm ( const double  v[]  )  [inline, static]

Computes the norm of the vector v.

Author:
Erion Plaku

Definition at line 114 of file Algebra3D.hpp.

static double Utils::Algebra3D::VecNormSquared ( const double  v[]  )  [inline, static]

Computes the norm squared of the vector v.

Author:
Erion Plaku

Definition at line 105 of file Algebra3D.hpp.

static void Utils::Algebra3D::VecScale ( const double  v[],
const double  s,
double  vscaled[] 
) [inline, static]

Scales the vector v by the scalar s and stores the result in vscaled.

Author:
Erion Plaku

Definition at line 135 of file Algebra3D.hpp.

static void Utils::Algebra3D::VecSubtract ( const double  v1[],
const double  v2[],
double  v[] 
) [inline, static]

Subtracts v2 from v1 and stores the result in v.

Author:
Erion Plaku

Definition at line 157 of file Algebra3D.hpp.

static void Utils::Algebra3D::VecUnit ( const double  v[],
double  vunit[] 
) [inline, static]

Computes the unit vector of v and stores the result in vunit.

Author:
Erion Plaku

Definition at line 123 of file Algebra3D.hpp.