Robot Core Documentation
Loading...
Searching...
No Matches
edu.wpi.first.math.geometry.Twist2d Class Reference
Inheritance diagram for edu.wpi.first.math.geometry.Twist2d:
edu.wpi.first.util.protobuf.ProtobufSerializable edu.wpi.first.util.struct.StructSerializable edu.wpi.first.util.WPISerializable edu.wpi.first.util.WPISerializable

Public Member Functions

 Twist2d ()
 
 Twist2d (double dx, double dy, double dtheta)
 
boolean equals (Object obj)
 

Public Attributes

double dx
 
double dy
 
double dtheta
 

Static Public Attributes

static final Twist2dProto proto = new Twist2dProto()
 
static final Twist2dStruct struct = new Twist2dStruct()
 

Detailed Description

A change in distance along a 2D arc since the last pose update. We can use ideas from differential calculus to create new Pose2d objects from a Twist2d and vice versa.

A Twist can be used to represent a difference between two poses.

Constructor & Destructor Documentation

◆ Twist2d() [1/2]

edu.wpi.first.math.geometry.Twist2d.Twist2d ( )

Default constructor.

◆ Twist2d() [2/2]

edu.wpi.first.math.geometry.Twist2d.Twist2d ( double dx,
double dy,
double dtheta )

Constructs a Twist2d with the given values.

Parameters
dxChange in x direction relative to robot.
dyChange in y direction relative to robot.
dthetaChange in angle relative to robot.

Member Function Documentation

◆ equals()

boolean edu.wpi.first.math.geometry.Twist2d.equals ( Object obj)

Checks equality between this Twist2d and another object.

Parameters
objThe other object.
Returns
Whether the two objects are equal or not.

Member Data Documentation

◆ dtheta

double edu.wpi.first.math.geometry.Twist2d.dtheta

Angular "dtheta" component (radians).

◆ dx

double edu.wpi.first.math.geometry.Twist2d.dx

Linear "dx" component.

◆ dy

double edu.wpi.first.math.geometry.Twist2d.dy

Linear "dy" component.

◆ proto

final Twist2dProto edu.wpi.first.math.geometry.Twist2d.proto = new Twist2dProto()
static

Twist2d protobuf for serialization.

◆ struct

final Twist2dStruct edu.wpi.first.math.geometry.Twist2d.struct = new Twist2dStruct()
static

Twist2d struct for serialization.


The documentation for this class was generated from the following file: