Vector2D

class kgpy.vector.Vector2D(x=0, y=0)

Bases: Vector

Parameters
__init__(x=0, y=0)
Parameters
Return type

None

Attributes

broadcast

length

length_l1

length_squared

ndim

quantity

shape

size

x

x_final

x_index

y

y_final

y_index

Methods

__init__([x, y])

angular()

rtype

kgpy.vector.Vector2D

copy()

rtype

typing.TypeVar(CopyableT, bound= Copyable)

copy_shallow()

rtype

typing.TypeVar(CopyableT, bound= Copyable)

dimensionless()

rtype

kgpy.vector.Vector2D

from_cylindrical([radius, azimuth])

rtype

kgpy.vector.Vector2D

from_quantity(value)

from_tuple(value)

get_component(comp)

rtype

astropy.units.Quantity

max([axis, keepdims])

rtype

kgpy.vector.Vector2D

min([axis, keepdims])

rtype

kgpy.vector.Vector2D

normalize()

rtype

kgpy.vector.Vector

outer(other)

rtype

kgpy.matrix.Matrix2D

reshape(*args)

rtype

kgpy.vector.Vector2D

set_component(comp, value)

spatial()

rtype

kgpy.vector.Vector2D

sum([axis, keepdims])

rtype

kgpy.vector.Vector2D

take(indices[, axis, out, mode])

to(unit)

rtype

kgpy.vector.Vector2D

to_3d([z])

rtype

kgpy.vector.Vector3D

to_tuple()

rtype

typing.Tuple

Inheritance Diagram

Inheritance diagram of kgpy.vector.Vector2D

classmethod angular()
Return type

kgpy.vector.Vector2D

copy()
Return type

typing.TypeVar(CopyableT, bound= Copyable)

Parameters

self (CopyableT) –

copy_shallow()
Return type

typing.TypeVar(CopyableT, bound= Copyable)

Parameters

self (CopyableT) –

classmethod dimensionless()
Return type

kgpy.vector.Vector2D

classmethod from_cylindrical(radius=<Quantity 0.>, azimuth=<Quantity 0. deg>)
Return type

kgpy.vector.Vector2D

Parameters
classmethod from_quantity(value)
Parameters

value (Quantity) –

classmethod from_tuple(value)
Parameters

value (Tuple) –

get_component(comp)
Return type

astropy.units.Quantity

Parameters

comp (str) –

max(axis=None, keepdims=False)
Return type

kgpy.vector.Vector2D

Parameters
min(axis=None, keepdims=False)
Return type

kgpy.vector.Vector2D

Parameters
normalize()
Return type

kgpy.vector.Vector

outer(other)
Return type

kgpy.matrix.Matrix2D

Parameters

other (Vector2D) –

reshape(*args)
Return type

kgpy.vector.Vector2D

set_component(comp, value)
Parameters
classmethod spatial()
Return type

kgpy.vector.Vector2D

sum(axis=None, keepdims=False)
Return type

kgpy.vector.Vector2D

Parameters
take(indices, axis=None, out=None, mode='raise')
Parameters
to(unit)
Return type

kgpy.vector.Vector2D

Parameters

unit (Unit) –

to_3d(z=None)
Return type

kgpy.vector.Vector3D

Parameters

z (Optional[Quantity]) –

to_tuple()
Return type

typing.Tuple

property broadcast
property length
property length_l1
property length_squared
property ndim: int
property quantity: Quantity
property shape: Tuple[int, ...]
property size: int
x: typing.Union[typing.Sequence[typing.Sequence[typing.Sequence[typing.Sequence[typing.Sequence[typing.Any]]]]], numpy.typing._array_like._SupportsArray[numpy.dtype], typing.Sequence[numpy.typing._array_like._SupportsArray[numpy.dtype]], typing.Sequence[typing.Sequence[numpy.typing._array_like._SupportsArray[numpy.dtype]]], typing.Sequence[typing.Sequence[typing.Sequence[numpy.typing._array_like._SupportsArray[numpy.dtype]]]], typing.Sequence[typing.Sequence[typing.Sequence[typing.Sequence[numpy.typing._array_like._SupportsArray[numpy.dtype]]]]], bool, int, float, complex, str, bytes, typing.Sequence[typing.Union[bool, int, float, complex, str, bytes]], typing.Sequence[typing.Sequence[typing.Union[bool, int, float, complex, str, bytes]]], typing.Sequence[typing.Sequence[typing.Sequence[typing.Union[bool, int, float, complex, str, bytes]]]], typing.Sequence[typing.Sequence[typing.Sequence[typing.Sequence[typing.Union[bool, int, float, complex, str, bytes]]]]]] = 0
property x_final: Quantity
x_index: typing.ClassVar[int] = 0
y: typing.Union[typing.Sequence[typing.Sequence[typing.Sequence[typing.Sequence[typing.Sequence[typing.Any]]]]], numpy.typing._array_like._SupportsArray[numpy.dtype], typing.Sequence[numpy.typing._array_like._SupportsArray[numpy.dtype]], typing.Sequence[typing.Sequence[numpy.typing._array_like._SupportsArray[numpy.dtype]]], typing.Sequence[typing.Sequence[typing.Sequence[numpy.typing._array_like._SupportsArray[numpy.dtype]]]], typing.Sequence[typing.Sequence[typing.Sequence[typing.Sequence[numpy.typing._array_like._SupportsArray[numpy.dtype]]]]], bool, int, float, complex, str, bytes, typing.Sequence[typing.Union[bool, int, float, complex, str, bytes]], typing.Sequence[typing.Sequence[typing.Union[bool, int, float, complex, str, bytes]]], typing.Sequence[typing.Sequence[typing.Sequence[typing.Union[bool, int, float, complex, str, bytes]]]], typing.Sequence[typing.Sequence[typing.Sequence[typing.Sequence[typing.Union[bool, int, float, complex, str, bytes]]]]]] = 0
property y_final: Quantity
y_index: typing.ClassVar[int] = 1