Vector
The term vector has multiple meanings across various fields. In mathematics and physics, a vector is a quantity with both magnitude and direction, unlike a scalar which has only magnitude. It can be represented geometrically as an arrow or algebraically as an ordered list of components in a coordinate system.[1][2][3] In biology, a vector is an organism, such as a mosquito, that transmits pathogens from one host to another (disease vector), or a DNA molecule used to deliver genetic material into cells (molecular vector).[4][5] In computing, a vector refers to a data structure resembling a dynamic array, or in graphics, to vector graphics defined by paths rather than pixels.[6] In transportation, vector may denote specific aircraft designs or vehicle models emphasizing directional efficiency. In entertainment, it can refer to fictional characters or elements in media and games. Other uses include companies, products, software, and historical terms.Mathematics and Physics
Euclidean Vectors
In Euclidean space, a vector is defined as an element of the real vector space \mathbb{R}^n, represented by an ordered tuple of n real numbers (x_1, x_2, \dots, x_n), known as its components. These components specify the vector's position relative to the origin in an n-dimensional coordinate system.[7] Geometrically, vectors in two- or three-dimensional Euclidean space are depicted as directed line segments or arrows, originating from a point (often the origin) and pointing toward another point. The magnitude, or length, of a vector \mathbf{v} = (x_1, x_2, \dots, x_n) is given by the Euclidean norm \|\mathbf{v}\| = \sqrt{\sum_{i=1}^n x_i^2}, which quantifies its size independent of direction.[8] The direction is captured by the unit vector \mathbf{v}/\|\mathbf{v}\|, obtained by scaling the vector to unit length.[9] Basic operations on Euclidean vectors include addition and scalar multiplication. Vector addition follows the parallelogram law, where the resultant vector \mathbf{u} + \mathbf{v} is the diagonal of the parallelogram formed by \mathbf{u} and \mathbf{v}, computed component-wise as (u_1 + v_1, u_2 + v_2, \dots, u_n + v_n). Scalar multiplication by a real number c scales the vector \mathbf{v} by c, yielding c\mathbf{v} = (c x_1, c x_2, \dots, c x_n), which stretches or shrinks the vector while preserving or reversing its direction depending on the sign of c.[7] The dot product provides a measure of similarity between two vectors \mathbf{v} and \mathbf{w} in \mathbb{R}^n, defined as \mathbf{v} \cdot \mathbf{w} = \sum_{i=1}^n x_i w_i, which equals \|\mathbf{v}\| \|\mathbf{w}\| \cos \theta where \theta is the angle between them.[8] This operation is used to compute projections, such as the scalar projection of \mathbf{v} onto \mathbf{w} as (\mathbf{v} \cdot \mathbf{w}) / \|\mathbf{w}\|, and to determine angles between vectors.[9] The development of Euclidean vectors as a systematic tool originated in the late 19th century, primarily through the independent work of J. Willard Gibbs and Oliver Heaviside, who formulated vector analysis to simplify quaternion-based calculations in physics and geometry.[10] Their approach emphasized three-dimensional Cartesian vectors, diverging from earlier geometric ideas in Euclid's Elements and Hamilton's quaternions.[11] Examples of Euclidean vectors include position vectors, which locate a point relative to the origin, such as \mathbf{r} = (3, 4) in \mathbb{R}^2 with magnitude 5, and displacement vectors, which represent the change from one position to another, like \Delta \mathbf{r} = \mathbf{r}_2 - \mathbf{r}_1. These concrete representations in \mathbb{R}^n form the basis for extending the concept to more abstract vector spaces.[9]Vector Spaces
A vector space V over a field F (such as the real numbers \mathbb{R} or complex numbers \mathbb{C}) is an algebraic structure consisting of a set of elements called vectors, equipped with two operations: vector addition and scalar multiplication by elements of F. These operations must satisfy a set of axioms that ensure the structure behaves consistently under linear combinations. Specifically, for all vectors \mathbf{u}, \mathbf{v}, \mathbf{w} \in V and scalars a, b \in F, the axioms are:[12]- Closure under addition: \mathbf{u} + \mathbf{v} \in V
- Closure under scalar multiplication: a \mathbf{v} \in V
- Commutativity of addition: \mathbf{u} + \mathbf{v} = \mathbf{v} + \mathbf{u}
- Associativity of addition: (\mathbf{u} + \mathbf{v}) + \mathbf{w} = \mathbf{u} + (\mathbf{v} + \mathbf{w})
- Existence of zero vector: There exists \mathbf{0} \in V such that \mathbf{0} + \mathbf{u} = \mathbf{u}
- Existence of additive inverses: For each \mathbf{u}, there exists -\mathbf{u} \in V such that \mathbf{u} + (-\mathbf{u}) = \mathbf{0}
- Distributivity of scalar multiplication over vector addition: a(\mathbf{u} + \mathbf{v}) = a\mathbf{u} + a\mathbf{v}
- Distributivity of scalar addition over vectors: (a + b)\mathbf{u} = a\mathbf{u} + b\mathbf{u}
- Associativity of scalar multiplication: a(b\mathbf{u}) = (ab)\mathbf{u}
- Multiplicative identity for scalars: $1 \cdot \mathbf{u} = \mathbf{u}
Physical Applications
In physics, vectors are essential for describing quantities that possess both magnitude and direction, distinguishing them from scalars, which have only magnitude. Examples of vector quantities include velocity, which combines speed and direction; force, as expressed in Newton's second law \vec{F} = m \vec{a}; and the electric field \vec{E} = \vec{F}/q, which exerts force on charges proportional to their magnitude and oriented by field lines.[17][18][19] Kinematics employs vectors to model motion, defining the velocity vector as the time derivative of the position vector, \vec{v} = d\vec{r}/dt, and the acceleration vector as \vec{a} = d\vec{v}/dt. These relations enable the analysis of projectile motion, where the initial velocity vector decomposes into horizontal and vertical components under constant gravitational acceleration, yielding parabolic trajectories without air resistance.[20][21] In dynamics, Newton's laws are formulated in vector form to account for directional effects. The second law states that the net force vector equals mass times acceleration, \sum \vec{F} = m \vec{a}, while linear momentum is defined as \vec{p} = m \vec{v}, conserved in isolated systems where external forces sum to zero. Torque, representing rotational tendency, arises from the cross product \vec{\tau} = \vec{r} \times \vec{F}, with magnitude \|\vec{\tau}\| = \|\vec{r}\| \|\vec{F}\| \sin \theta and direction given by the right-hand rule, perpendicular to both position and force vectors.[22][23][24] Electromagnetism relies on vectors for field interactions, as in the Lorentz force law \vec{F} = q (\vec{E} + \vec{v} \times \vec{B}), where the magnetic component is perpendicular to both velocity and magnetic field \vec{B}. Vector calculus operators further describe these fields: the gradient \nabla \phi points in the direction of steepest increase of a scalar potential; divergence \nabla \cdot \vec{A} quantifies net flux through a surface, indicating sources or sinks; and curl \nabla \times \vec{A} measures local rotation, essential for magnetic field generation from currents.[25][26] Conservation of linear momentum in vector form, \vec{p}_\text{initial} = \vec{p}_\text{final}, holds for isolated systems, underpinning collision analyses and rocket propulsion by ensuring total vector momentum remains invariant.[27] Twentieth-century extensions incorporate vectors into relativity, using four-vectors in spacetime to unify space and time under Lorentz transformations, such as the position four-vector (ct, \vec{r}) and energy-momentum four-vector (E/c, \vec{p}), preserving invariance in special relativity.[28][29]Biology
Disease Vectors
Disease vectors are living organisms, such as arthropods or rodents, that transmit infectious pathogens from infected hosts to susceptible ones without themselves becoming diseased by the pathogen.[30] These vectors play a central role in the epidemiology of numerous diseases, facilitating the spread of bacteria, viruses, and parasites that cause significant global morbidity and mortality. Vector-borne diseases account for more than 17% of all infectious diseases, causing more than 700,000 deaths annually (as of 2024).[30][31] Transmission by disease vectors occurs through two primary mechanisms: mechanical and biological. In mechanical transmission, the vector passively carries the pathogen on its body parts, such as legs or mouthparts, without the pathogen replicating within the vector; for example, houseflies can mechanically transfer bacteria like those causing typhoid fever by contaminating food or surfaces.[32] In contrast, biological transmission involves the pathogen undergoing development, multiplication, or both inside the vector, often requiring an extrinsic incubation period before the vector can infect a new host; a classic case is the Anopheles mosquito biologically transmitting Plasmodium parasites in malaria after the parasites replicate in the mosquito's salivary glands.[32][30] Key examples include the Aedes aegypti mosquito, which serves as a vector for dengue, Zika, and chikungunya viruses through biological transmission, and Ixodes ticks, which biologically transmit Borrelia burgdorferi, the bacterium causing Lyme disease. Rodents like rats and their fleas, such as Xenopsylla cheopis, act as vectors for Yersinia pestis in plague, where fleas biologically transmit the bacterium after feeding on infected rodent blood.[33] Transmission cycles involving disease vectors typically include reservoir hosts—often wild or domestic animals that maintain the pathogen in nature—and vector competence, defined as the vector's intrinsic ability to acquire, sustain, and transmit the pathogen after exposure.[34] For instance, in the sylvatic cycle of yellow fever, non-human primates serve as reservoirs, with Aedes africanus mosquitoes maintaining transmission in forested areas before spillover to humans via domestic vectors like Aedes aegypti.[35] Control measures focus on interrupting these cycles through insecticide application to kill vectors, habitat modification to eliminate breeding sites (e.g., removing standing water for mosquitoes), and vaccination of human or reservoir hosts where feasible.[30] Historically, vector control efforts dramatically reduced yellow fever incidence; in Havana, Cuba, during the early 1900s, targeted mosquito eradication campaigns led by the U.S. Army, including fumigation and water source treatment, decreased deaths from an annual average of 462 to near zero within months.[36] Modern challenges to vector control include climate change, which expands vector geographic ranges and prolongs transmission seasons by altering temperature and precipitation patterns suitable for vector survival and pathogen development.[30] Additionally, widespread insecticide resistance in vectors, such as pyrethroid resistance in Anopheles mosquitoes, compromises the efficacy of chemical interventions and necessitates integrated strategies like those outlined in the WHO Global Vector Control Response.[37][38] These issues underscore the need for ongoing surveillance and innovative approaches to mitigate the resurgence of vector-borne diseases.[39]Molecular Vectors
In molecular biology, a vector is a DNA molecule, such as a plasmid or virus, used to carry foreign genetic material into a host cell to enable its replication or expression.[5] These tools are essential in genetic engineering, allowing scientists to insert, amplify, or express specific genes within host organisms like bacteria or mammalian cells.[40] Cloning vectors, such as the pBR322 plasmid, facilitate the propagation of inserted DNA fragments by incorporating an origin of replication for autonomous copying and selectable markers, like antibiotic resistance genes, to identify successful transformants.[41] In contrast, expression vectors are engineered with strong promoters to drive the transcription and translation of the inserted gene, enabling high-level production of recombinant proteins in host cells.[42] Viral vectors, including adenoviruses and lentiviruses, are modified viruses that deliver therapeutic genes into target cells for gene therapy applications.[43] Adeno-associated virus (AAV) vectors, in particular, are widely used due to their low immunogenicity and ability to achieve long-term gene expression, such as in delivering CRISPR-Cas9 components for genome editing.[44] Key components of these vectors include a multiple cloning site (MCS), a short DNA segment containing numerous restriction enzyme recognition sites for precise insertion of foreign DNA. Many cloning vectors also feature insertional inactivation mechanisms, such as disruption of a reporter gene like lacZ, which allows screening of recombinant clones through phenotypic changes, such as blue-white colony selection in bacteria.[45] The development of molecular vectors traces back to the 1970s, when Stanley Cohen and Herbert Boyer's pioneering work on recombinant DNA technology demonstrated the construction of biologically functional bacterial plasmids in vitro, laying the foundation for modern genetic engineering.[40] This breakthrough enabled the first gene cloning experiments and spurred the creation of versatile vectors like pBR322.[41] In the 21st century, advancements have led to numerous regulatory approvals for gene therapies. For example, Luxturna (voretigene neparvovec-rzyl) in 2017 was the first FDA-approved AAV-based treatment for inherited retinal dystrophy caused by RPE65 mutations, followed by others such as Zolgensma for spinal muscular atrophy in 2019 and Elevidys for Duchenne muscular dystrophy in 2023 (as of August 2025, over 30 cell and gene therapies have been approved).[46] Applications of molecular vectors span gene cloning for research and industrial production, creation of transgenic organisms like genetically modified crops for enhanced yield and pest resistance, and vaccine development, exemplified by adenoviral vector-based COVID-19 vaccines that deliver SARS-CoV-2 spike protein genes to elicit immune responses.[47][48] These tools have transformed biotechnology, enabling precise genetic modifications while minimizing risks through engineered safety features.[49]Computing
Data Structures
In computer science, a vector is a dynamic array data structure that supports random access to elements and automatic resizing to accommodate growing or shrinking collections of data. It maintains a contiguous block of memory for its elements, enabling efficient indexing and iteration.[50] Typical implementations distinguish between the vector's current size (number of elements) and its capacity (allocated memory size), with resizing triggered when the size exceeds capacity, often by doubling the capacity to achieve amortized constant-time append operations. For example, in C++, thestd::vector class from the Standard Template Library (STL) allocates memory on the heap and stores elements contiguously, except for the specialized std::vector<bool>.[50] In Java, the ArrayList class provides a similar resizable-array implementation of the List interface, backed by an internal array that grows automatically, typically increasing capacity by 50% when full.[51]
Core operations on vectors include constant-time indexing via operator[] or at() in C++ and get() in Java, allowing O(1) random access due to the contiguous layout. Appending elements with push_back in C++ or add in Java has amortized O(1) time complexity, as occasional reallocations copy elements to a larger array. Insertions or deletions in the middle, such as insert or erase in C++ and add(index, element) or remove in Java, require shifting subsequent elements, resulting in O(n) worst-case time where n is the number of elements affected.[50][51]
Vectors offer significant advantages over linked lists, particularly in cache performance due to spatial locality: contiguous storage allows processors to prefetch multiple elements into cache lines, reducing misses and improving iteration speed. For instance, summing elements in a large array can be over five times faster than in a linked list because of this locality.[52] Vectors are commonly used as the underlying structure for stacks and queues, leveraging their efficient end-based operations. To optimize performance and avoid frequent reallocations, methods like reserve in C++ or ensureCapacity in Java allow pre-allocating capacity, ensuring subsequent push_back or add operations remain strictly O(1) until the reserved limit.[50][51]
The concept of vectors as dynamic arrays evolved from static arrays introduced in early programming languages like Fortran in the 1950s, where the DIMENSION statement declared fixed-size arrays for scientific computing.[53] Dynamic resizing capabilities emerged in later languages, with C++'s std::vector formalized in the STL during the early 1990s by Alexander Stepanov at Hewlett-Packard, emphasizing generic programming for reusable data structures.[54] In modern computing, vector data structures benefit from SIMD (Single Instruction, Multiple Data) vectorization, where hardware instructions process multiple elements in parallel registers, accelerating numerical computations on CPUs with wide vector units, such as 512-bit registers holding up to 16 single-precision floats.[55]