🔥 JEE Main 2027 Session 1 is in January — start the JEE Mains Physics Test Series →

CLASS 12 · MATHEMATICAL TOOLS

3D Vectors & Trigonometry for EM

The dot and cross products you already met don't change in three dimensions, they just pick up a third component. What's new is where they show up: the magnetic force on a moving charge, the work an electric field does along a tilted path, and the flux through a slanted surface are all 3D dot or cross products in disguise, and a rotating vector in that same plane is exactly where sine and cosine waves come from.

01 · See it

Watch it happen

Charge sign:
60°
Angle between v, B
10.39
|v × B| (out of page)
10.39
|F| = |q|·|v×B| (out of page)

v × B always points perpendicular to the plane v and B are drawn in, which is why it shows here as a dot (toward you) or a crossed circle (away from you) rather than another arrow in the plane. Flip the charge sign from +q to −q without touching either slider and watch F flip to the opposite side, even though v, B, and the angle between them never changed.

Set v and B to any two angles and watch the force indicator at the origin switch between a dot (force toward you, out of the page) and a crossed circle (force away from you, into the page) as you sweep B past v. Then flip the charge sign and watch the indicator switch sides instantly, with neither slider moved.

02 · Derive it

Where it comes from

Quick recap first. For two vectors A and B separated by angle θ, the dot product is A⃗⋅B⃗=ABcos⁡θ\vec{A}\cdot\vec{B} = AB\cos\theta (a number) and the cross product’s magnitude is ∣A⃗×B⃗∣=ABsin⁡θ|\vec{A}\times\vec{B}| = AB\sin\theta (a vector, direction by the right-hand rule). See Vectors & Vector Mathematics for the full derivation, if you need to rebuild it.

Now a genuine 3D calculation. Take r⃗=(2i^+3j^+1k^) m\vec{r} = (2\hat{i} + 3\hat{j} + 1\hat{k})\text{ m} and F⃗=(1i^−2j^+4k^) N\vec{F} = (1\hat{i} - 2\hat{j} + 4\hat{k})\text{ N}, and find the torque τ⃗=r⃗×F⃗\vec{\tau} = \vec{r}\times\vec{F}. Unlike the 2D case, every component can be nonzero now, so we need the full determinant expansion:

r⃗×F⃗=(ryFz−rzFy)i^−(rxFz−rzFx)j^+(rxFy−ryFx)k^\vec{r}\times\vec{F} = (r_yF_z - r_zF_y)\hat{i} - (r_xF_z - r_zF_x)\hat{j} + (r_xF_y - r_yF_x)\hat{k}τx=(3)(4)−(1)(−2)=12+2=14\tau_x = (3)(4) - (1)(-2) = 12 + 2 = 14τy=−[(2)(4)−(1)(1)]=−(8−1)=−7\tau_y = -\big[(2)(4) - (1)(1)\big] = -(8 - 1) = -7τz=(2)(−2)−(3)(1)=−4−3=−7\tau_z = (2)(-2) - (3)(1) = -4 - 3 = -7
Torque in 3D
τ⃗=(14i^−7j^−7k^) N⋅m\vec{\tau} = (14\hat{i} - 7\hat{j} - 7\hat{k})\text{ N·m}

Each component is just the 2D cross-product formula applied to the pair of axes it leaves out, done three times over. Nothing new conceptually, just three bookkeeping passes instead of one.

Magnetic force needs exactly this. A charge qq moving with velocity v⃗\vec{v} through a field B⃗\vec{B} feels:

Magnetic (Lorentz) force
F⃗=q v⃗×B⃗\vec{F} = q\,\vec{v}\times\vec{B}

This is a cross product, not a dot product, precisely because the force has to be a new vector, perpendicular to both the charge’s motion and the field, rather than a single number. The right-hand rule gives the direction of v⃗×B⃗\vec{v}\times\vec{B} itself; the sign of qq then decides whether F⃗\vec{F} points that way or the exact opposite way.

Work and flux use the dot product instead. The work an electric field does moving a charge through displacement d⃗\vec{d} is W=qE⃗⋅d⃗W = q\vec{E}\cdot\vec{d}, and the flux through a surface of area vector A⃗\vec{A} (pointing along the surface’s normal) in a uniform field E⃗\vec{E} is Φ=E⃗⋅A⃗\Phi = \vec{E}\cdot\vec{A}. Both only care about how much of one vector lies along the other, which is exactly what a dot product measures, so a surface tilted 90° to the field carries zero flux no matter how large the field or the area is.

Where sine and cosine graphs come from. Picture a vector of fixed length AA (a phasor) spinning counterclockwise at a steady angular speed ω\omega, starting at angle ϕ\phi when t=0t = 0. At any later time its angle is ωt+ϕ\omega t + \phi, so by the plain definition of sine and cosine on a circle of radius AA, its two components are:

x(t)=Acos⁡(ωt+ϕ),y(t)=Asin⁡(ωt+ϕ)x(t) = A\cos(\omega t + \phi), \qquad y(t) = A\sin(\omega t + \phi)

Hold the phasor still and look only at y(t)y(t) as tt ticks forward: that single number traces out exactly a sine wave, rising from 0 to AA and back as the phasor sweeps around. This is the whole reason AC voltage and current are written as V(t)=V0sin⁡(ωt)V(t) = V_0\sin(\omega t) and I(t)=I0sin⁡(ωt+ϕ)I(t) = I_0\sin(\omega t + \phi): they’re the vertical shadow of two phasors spinning together, offset by the phase angle ϕ\phi.

03 · Break it

Where the shortcut stops working

The most common slip is applying the right-hand rule to find v⃗×B⃗\vec{v}\times\vec{B}, then forgetting the charge sign entirely and reporting that direction as the force. For a positive charge the two do coincide, but for a negative charge the actual force F⃗=qv⃗×B⃗\vec{F}=q\vec{v}\times\vec{B} points the exact opposite way. An electron and a proton moving identically through an identical field curve in opposite directions, which is the entire principle behind a mass spectrometer separating particles by charge.

A second trap: “perpendicular to both v and B” sounds like it pins down one direction, but geometrically there are always two opposite directions perpendicular to a given plane. Nothing about perpendicularity alone picks between them, only the handedness convention (right-hand rule, consistently applied) resolves the ambiguity. Switching to a left-hand rule partway through a problem, or applying it inconsistently when moving from v⃗×B⃗\vec{v}\times\vec{B} to the scaled force qv⃗×B⃗q\vec{v}\times\vec{B}, silently flips the answer without changing a single number in the calculation.

Third, it’s tempting to assume flux or work is simply EAEA or FdFd, dropping the angle entirely. That’s only true when the relevant vectors are perfectly aligned; a surface tilted at angle θ\theta to the field carries flux EAcos⁡θEA\cos\theta, not EAEA, and at θ=90∘\theta = 90^\circ that flux vanishes completely even though the field and the surface both still exist.

04 · Master it

Apply it under exam conditions

A particle carrying charge q=+2 μC=2×10−6 Cq = +2\ \mu\text{C} = 2\times10^{-6}\text{ C} moves with velocity v⃗=(3i^+4j^) m/s\vec{v} = (3\hat{i} + 4\hat{j})\text{ m/s} through a magnetic field B⃗=(2j^+5k^) T\vec{B} = (2\hat{j} + 5\hat{k})\text{ T}. Find the magnetic force on the particle, as a vector and as a magnitude.

Start with the cross product in full component form:

v⃗×B⃗=(vyBz−vzBy)i^−(vxBz−vzBx)j^+(vxBy−vyBx)k^\vec{v}\times\vec{B} = (v_yB_z - v_zB_y)\hat{i} - (v_xB_z - v_zB_x)\hat{j} + (v_xB_y - v_yB_x)\hat{k}vxBz−vzBx term: (3)(5)−(0)(0)=15  ⟹  −j^ coefficient =−15v_xB_z - v_zB_x\text{ term: } (3)(5) - (0)(0) = 15 \implies -\hat{j}\text{ coefficient } = -15v⃗×B⃗=[(4)(5)−(0)(2)]i^−15j^+[(3)(2)−(4)(0)]k^=20i^−15j^+6k^ (SI units)\vec{v}\times\vec{B} = \big[(4)(5)-(0)(2)\big]\hat{i} - 15\hat{j} + \big[(3)(2)-(4)(0)\big]\hat{k} = 20\hat{i} - 15\hat{j} + 6\hat{k}\ \text{(SI units)}

Multiply by the charge to get the force:

F⃗=q v⃗×B⃗=(2×10−6)(20i^−15j^+6k^)\vec{F} = q\,\vec{v}\times\vec{B} = (2\times10^{-6})(20\hat{i} - 15\hat{j} + 6\hat{k})
Magnetic force, as a vector
F⃗=(4.00×10−5i^−3.00×10−5j^+1.20×10−5k^) N\vec{F} = \textcolor{#e08a1e}{(4.00\times10^{-5}\hat{i} - 3.00\times10^{-5}\hat{j} + 1.20\times10^{-5}\hat{k})\text{ N}}

Its magnitude follows from the usual 3D length formula:

∣F⃗∣=(4.00×10−5)2+(3.00×10−5)2+(1.20×10−5)2|\vec{F}| = \sqrt{(4.00\times10^{-5})^2 + (3.00\times10^{-5})^2 + (1.20\times10^{-5})^2}∣F⃗∣=5.14×10−5 N|\vec{F}| = \textcolor{#e08a1e}{5.14\times10^{-5}\text{ N}}

Cross-check: ∣v⃗∣=5.00|\vec{v}| = 5.00 m/s and ∣B⃗∣=5.39|\vec{B}| = 5.39 T, and the angle between them works out to θ≈72.7∘\theta \approx 72.7^\circ, so ∣v⃗×B⃗∣=(5.00)(5.39)sin⁡(72.7∘)≈25.7|\vec{v}\times\vec{B}| = (5.00)(5.39)\sin(72.7^\circ) \approx 25.7, matching 202+152+62≈25.7\sqrt{20^2+15^2+6^2}\approx25.7 from the component calculation, and scaling by q=2×10−6 Cq = 2\times10^{-6}\text{ C} gives the same 5.14×10−55.14\times10^{-5} N found above.

05 · FAQs

Quick answers

Why does the magnetic force need a cross product instead of a dot product?+

Because the magnetic force F = qv×B is a push sideways to both the charge's velocity and the field, never along either one. A dot product only ever returns a number built from how parallel two vectors are, it can never hand you a new direction. Only the cross product produces a vector of its own, perpendicular to both inputs, which is exactly the geometry a magnetic force has.

If F is perpendicular to both v and B, how do I know which of the two perpendicular directions it's actually in?+

By computing the cross product properly in components (or using the right-hand rule) rather than just noting 'perpendicular to both.' In three dimensions there are always exactly two directions perpendicular to a given plane, pointing opposite ways, and only the right-hand-rule convention picks the correct one. Get the handedness wrong and you'll have the right magnitude but the force on the wrong side.

Does the right-hand rule change for a negative charge?+

The rule itself doesn't change, but the charge's sign still flips the final answer: F = qv×B, so for negative q the force points exactly opposite to whatever v×B itself gives. Work out v×B with the right-hand rule first, then flip it if the charge is negative, rather than trying to build the sign into the rule itself.

Why does a rotating vector trace out a sine wave?+

If a vector of fixed length sweeps around a circle at a constant angular speed ω, its vertical component at time t is simply its length times sin(ωt), by definition of sine on a unit circle. Project that single rotating arrow onto one axis and the height traces out a sine curve over time; project it onto the perpendicular axis instead and you get a cosine curve, the same motion viewed 90° later.

What does 'phase' mean physically?+

Phase is just the starting angle of that rotating vector at t = 0. Two oscillating quantities (like voltage and current in an AC circuit) can have the same frequency and amplitude yet reach their peaks at different times, because their rotating vectors start at different angles. That offset angle is the phase difference, and it's why AC power calculations need cos(phase) rather than just the peak voltage and current multiplied together.