Vector2d

@Serializable
data class Vector2d(val x: Double, val y: Double)

Vector \((x, y)\)

Constructors

Link copied to clipboard
constructor(x: Double, y: Double)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard

Returns the angle of this vector as a Rotation2d, normalizing this first.

Link copied to clipboard

Returns the angle of this vector as a Rotation2d, assuming this is normalized.

Link copied to clipboard
Link copied to clipboard
operator fun div(z: Double): Vector2d
Link copied to clipboard
infix fun dot(v: Vector2d): Double
Link copied to clipboard
operator fun minus(v: Vector2d): Vector2d
Link copied to clipboard
fun norm(): Double
Link copied to clipboard
operator fun plus(v: Vector2d): Vector2d
Link copied to clipboard
Link copied to clipboard
operator fun times(z: Double): Vector2d
Link copied to clipboard
operator fun unaryMinus(): Vector2d