src.Vec package

Submodules

src.Vec.VecE2 module

class src.Vec.VecE2.VecE2(x=0.0, y=0.0)[source]

Bases: object

VecE2 is a class to deal with 2 dimension vector

atan()[source]
hypot()[source]
rot180()[source]
rotl90()[source]
rotr90()[source]
show()[source]
src.Vec.VecE2.dist(a: src.Vec.VecE2.VecE2, b: src.Vec.VecE2.VecE2)[source]
src.Vec.VecE2.dist2(a: src.Vec.VecE2.VecE2, b: src.Vec.VecE2.VecE2)[source]
src.Vec.VecE2.lerp(a: src.Vec.VecE2.VecE2, b: src.Vec.VecE2.VecE2, t)[source]
src.Vec.VecE2.norm(v: src.Vec.VecE2.VecE2)[source]
src.Vec.VecE2.normsquared(v: src.Vec.VecE2.VecE2)[source]
src.Vec.VecE2.polar(r, theta)[source]
src.Vec.VecE2.proj(a: src.Vec.VecE2.VecE2, b: src.Vec.VecE2.VecE2, t: type)[source]
src.Vec.VecE2.proj_(a: src.Vec.VecE2.VecE2, b: src.Vec.VecE2.VecE2)[source]
src.Vec.VecE2.rot(a: src.Vec.VecE2.VecE2, theta: float)[source]

rotate counter-clockwise about the origin :param a: VecE2 :param theta: rotate angle :return: VecE2

src.Vec.VecSE2 module

class src.Vec.VecSE2.VecSE2(x=0.0, y=0.0, theta=0.0)[source]

Bases: object

VecSE2 class is to deal with a 2 dimensional vector with angle

add_E2(other: src.Vec.VecE2.VecE2)[source]
atan()[source]
convert(t: type = <class 'src.Vec.VecE2.VecE2'>)[source]
mod2pi()[source]
rot180()[source]
rotl90()[source]
rotr90()[source]
show()[source]
src.Vec.VecSE2.clamp(n, smallest, largest)[source]
src.Vec.VecSE2.clamp_euclidean(a: src.Vec.VecSE2.VecSE2, lo, hi)[source]
src.Vec.VecSE2.convert(a: src.Vec.VecSE2.VecSE2)[source]
src.Vec.VecSE2.deltaangle(a::Real, b::Real)[source]

Return the minimum δ such that a + δ = mod(b, 2π)

src.Vec.VecSE2.lerp(a: src.Vec.VecSE2.VecSE2, b: src.Vec.VecSE2.VecSE2, t)[source]
src.Vec.VecSE2.lerp_angle(a, b, t)[source]
src.Vec.VecSE2.normaliza_euclidean(a: src.Vec.VecSE2.VecSE2, p=2)[source]
src.Vec.VecSE2.rot(a: src.Vec.VecSE2.VecSE2, theta: float)[source]

rotate counter-clockwise about the origin :param a: VecSE2 :param theta: rotate angle :return: VecSE2

src.Vec.VecSE2.scale_euclidean(a: src.Vec.VecSE2.VecSE2, b)[source]

Module contents