RosettaCodeData/Task/Vector/00-TASK.txt
2026-04-30 12:34:36 -04:00

32 lines
863 B
Text

;Related tasks:
*   [[Arrays]]
*   [[Vector]]
**   [[Dot product]]
**   [[Vector products]]
*   [[Matrices]]
*   [[Bivector]]
*   [[Antivector]]
*   [[Tensor]]
*   [[Quaternion]]
*   [[Rotor]]
*   [[Motor]]
*   [[Sedenion]]
*   [[Octonion]]
<br>
;Task
Implement a Vector class (or a set of functions) that models a Physical Vector. The four basic operations and a ''pretty print'' function should be implemented.
The Vector may be initialized in any reasonable way.
* Start and end points, and direction
* Angular coefficient and value (length)
The four operations to be implemented are:
* Vector <big><b> + </b></big> Vector addition
* Vector <big><b> - </b></big> Vector subtraction
* Vector <big><b> * </b></big> scalar multiplication
* Vector <big><b> / </b></big> scalar division
<br>