Vectors – Definition and Coordinate System Representation
1. Vector
A vector is a quantity that has both magnitude and direction. It is commonly represented using arrows or ordered sets of numbers.
- Has magnitude and direction
- Different from scalar quantity
- Widely used in graphics
2. Vector Representation
Vectors can be represented graphically as arrows or mathematically using coordinates.
- 2D Vector: (x, y)
- 3D Vector: (x, y, z)
- Direction shown by arrow
3. Coordinate System
A coordinate system provides a reference framework to represent vectors and points in space.
- Cartesian coordinate system
- 2D and 3D coordinate axes
- Defines position and direction
4. Vector Magnitude
The magnitude (length) of a vector represents the distance covered in the given direction.
|V| = √(x² + y²) (2D) |V| = √(x² + y² + z²) (3D)
5. Unit Vector
A unit vector is a vector with magnitude equal to 1. It represents direction only.
- Used for direction normalization
- Denoted as V̂
6. Vector Addition
Vector addition combines two or more vectors to produce a resultant vector.
- Head-to-tail method
- Component-wise addition
7. Vector Subtraction
Vector subtraction finds the difference between two vectors and determines relative direction.
- Subtract corresponding components
- Used for displacement
8. Dot Product
The dot product of two vectors results in a scalar value and is used to find angles and projections.
A · B = |A||B| cosθ
9. Cross Product
The cross product of two vectors results in a vector perpendicular to both input vectors.
- Used in 3D graphics
- Determines surface normals
10. Importance of Vectors in Computer Graphics
- Object movement and direction
- Lighting and shading calculations
- Animation and physics simulation
Practice Questions
- Define vector.
- What is a unit vector?
- Explain vector addition.
- Define dot product.
- Why are vectors important in graphics?