Vectors as arrows, lists, and embeddings
Assistance allowed only after prediction and observed evidence are recorded.
Prerequisites
Complete Day 21 review; use the listed recovery link if any concept below is missing.
Learning Objective
Represent a vector both as an arrow in the plane and as an ordered list of numbers; compute addition, scalar multiplication, and linear combinations component-wise, then connect a token embedding to a vector in d dimensions.
Instructions
A vector v = (v1, v2, ..., vd) is both an arrow in d-dimensional space and a row of numbers. Addition and scalar multiplication act component-wise. A linear combination a*v + b*w mixes two vectors; the span is every point reachable by such mixes. In a language model, each token id selects one row of an embedding table E of shape V x d, so that row is a vector in R^d.
Practice & Prediction Log
Let v = (1, 2) and w = (3, -1). Before computing anything, predict: (a) v + w; (b) 2*v; (c) the linear combination 2*v - w. Then verify by hand and in code.
Work component by component: (v+w)_i = v_i + w_i and (c*v)_i = c*v_i. Sketch the arrows on grid paper to see the parallelogram for v + w.
(a) v + w = (1+3, 2-1) = (4, 1). (b) 2*v = (2, 4). (c) 2*v - w = (2-3, 4+1) = (-1, 5). The parallelogram rule places v + w at the far corner of the parallelogram built from v and w. An embedding row E[token_id] is exactly such a vector with d coordinates.
Your prediction table matches every computed coordinate, you can describe the parallelogram geometry of v + w, and you can state in one sentence why an embedding-table row is a vector.
Authoritative Source Resources & Provenance
Essence of Linear Algebra
Relevant Section / Range: Chapters 1-2: Vectors and linear combinations, span and basis vectors
Verified Version & Date: 2016-2023 (Verified: 2026-10-30)
Unequaled geometric and visual intuition for vectors, linear transformations, matrix multiplication, and inverses before tensor operations.
High-school coordinate geometry
Geometric explanations, worked formulas, and coordinate exercises are fully provided as original lesson text.
Compared Candidate Sources & Selection Analysis (2)
Established textbook/lecture approach, strong mathematical rigor alongside 3Blue1Brown visual intuition.
Theoretical determinant-free proof structure is mathematically elegant but less aligned with computational tensor engineering.
18.06 Linear Algebra (Prof. Gilbert Strang)
Relevant Section / Range: Lecture 1: The geometry of linear equations (row and column pictures)
Verified Version & Date: Spring 2010 (Verified: 2026-10-30)
Established row-picture and column-picture treatment of linear systems, matrix products, and invertibility; rigorous complement to the 3Blue1Brown visual series.
High-school algebra and coordinate geometry
All row/column-picture derivations and worked examples are written as original lesson text and run offline.
Compared Candidate Sources & Selection Analysis (3)
Selected as co-primary: geometric visualizations paired with Strang's algebraic rigor.
Determinant-free theoretical treatment is elegant but further from the computational shape accounting required here.
Interactive figures are attractive, but the absence of a declared open license makes rights disposition unclear; kept out of the resource set.