Trigonometry and the dot product — how surface orientation affects energy receipt
2026-02-26
At solar noon on the summer solstice in Banff, Alberta, the sun stands about 60° above the southern horizon. A solar panel mounted flat on a horizontal roof intercepts a certain amount of energy. Tilt that panel to face the sun directly — perpendicular to the incoming rays — and the energy per unit area roughly doubles, because the same beam is concentrated over a smaller surface. This is why rooftop installers angle panels south at a fixed inclination, why the equator-facing slopes of mountain valleys host vineyards and meadows while north-facing slopes support dense conifer stands, and why the seasonal variation of solar energy with latitude is steeper than a naive calculation would suggest.
The mathematical tool that makes this precise is the dot product — a single operation that converts the angle between a surface’s normal vector and the direction to the sun into the fraction of maximum possible energy the surface receives. A surface facing directly at the sun gets the full beam; a surface parallel to the beam gets nothing; every other orientation falls between these extremes as a cosine function of the angle. This model introduces trigonometry and vector geometry through the practical problem of solar energy receipt on sloped terrain, building from the definition of angle through to hillshade calculation and the explanation of aspect-dependent microclimates.
Why does the same incoming solar radiation produce different heating rates on slopes of different orientations?
A horizontal surface in Denver receives a certain amount of solar energy per square meter. A south-facing slope (tilted toward the equator) receives more energy per unit area. A north-facing slope receives less. The total radiation from the sun hasn’t changed — but the effective area intercepting the light has.
This is a projection effect, and it’s fundamental to: - Topographic climate (microclimates in mountainous terrain) - Seasonal energy balance (why summer is warmer than winter) - Solar panel placement (tilt angle matters) - Glacier mass balance (north vs. south aspects)
The mathematical question: How do we quantify the relationship between surface orientation and energy receipt?
Imagine a flashlight shining on a wall: - When the flashlight is perpendicular to the wall, the beam creates a small, bright circle. - When you tilt the flashlight, the beam spreads out into an ellipse — same total light, larger area, lower intensity.
The intensity (energy per unit area) depends on the angle between the light direction and the surface orientation.
Key principle: Energy flux is maximized when the light hits the surface perpendicularly and decreases as the angle becomes more oblique.
To describe surface orientation, we use the normal vector — a unit vector pointing perpendicular to the surface, away from it.
Examples: - Horizontal surface: normal points straight up (0, 0, 1) - Vertical wall facing east: normal points east (1, 0, 0) - 30° south-facing slope: normal tilts south and up
The angle between the sun’s direction and the surface normal determines the projection factor.
Consider a surface tilted at angle \beta from horizontal, receiving light from an angle \theta from the surface normal.
The effective area intercepting the light is:
A_{\text{eff}} = A \cos \theta
Where: - A is the physical area of the surface (m²) - \theta is the angle of incidence (angle between light direction and surface normal)
Energy flux density (W/m² on the surface):
S = S_0 \cos \theta
Where S_0 is the incoming solar flux density (W/m² perpendicular to the sun’s rays).
Special cases: - \theta = 0° (sun perpendicular to surface): \cos 0° = 1 → full intensity - \theta = 45°: \cos 45° = 0.707 → 70.7% of perpendicular intensity - \theta = 90° (sun parallel to surface): \cos 90° = 0 → no energy received
We can express \cos \theta using the dot product of two unit vectors:
\cos \theta = \hat{\mathbf{n}} \cdot \hat{\mathbf{s}}
Where: - \hat{\mathbf{n}} is the unit normal vector to the surface - \hat{\mathbf{s}} is the unit vector pointing toward the sun
The dot product of two vectors \mathbf{a} = (a_x, a_y, a_z) and \mathbf{b} = (b_x, b_y, b_z) is:
\mathbf{a} \cdot \mathbf{b} = a_x b_x + a_y b_y + a_z b_z
Geometric interpretation:
\mathbf{a} \cdot \mathbf{b} = |\mathbf{a}| |\mathbf{b}| \cos \theta
For unit vectors (|\hat{\mathbf{a}}| = |\hat{\mathbf{b}}| = 1):
\hat{\mathbf{a}} \cdot \hat{\mathbf{b}} = \cos \theta
The dot product directly gives us the cosine of the angle between the vectors!
Problem: A solar panel is tilted 35° from horizontal, facing due south. At solar noon on the equinox, the sun is at an elevation angle of 50° above the horizon (also due south).
(a) Angle of incidence
Surface normal: The panel tilts 35° from horizontal toward the south. The normal tilts 35° from vertical toward the south.
In spherical coordinates (measuring from vertical): - Normal elevation from horizontal: $90° - 35° = 55°$
Sun direction: Elevation 50° above horizon, so zenith angle = 90° - 50° = 40°
Both the sun and the surface normal are in the same vertical plane (the north-south meridian). The angle between them is:
\theta = |55° - 40°| = 15°
(b) Effective flux
S = S_0 \cos \theta = 1000 \times \cos(15°)
\cos(15°) \approx 0.966
S \approx 966 \text{ W/m}^2
The panel receives 96.6% of the perpendicular solar flux — very nearly optimal!
Note: If the panel were horizontal, the flux would be:
S_{\text{horiz}} = 1000 \times \cos(40°) = 1000 \times 0.766 = 766 \text{ W/m}^2
The tilted panel receives 26% more energy than a horizontal surface.
Problem: A surface has normal vector \mathbf{n} = (0.5, 0, 0.866) (pointing northeast and upward). The sun direction is \mathbf{s} = (0.3, 0.3, 0.9) (pointing slightly south and upward). Both are unit vectors.
(a) Angle of incidence
\cos \theta = \mathbf{n} \cdot \mathbf{s} = (0.5)(0.3) + (0)(0.3) + (0.866)(0.9)
= 0.15 + 0 + 0.779 = 0.929
\theta = \arccos(0.929) \approx 21.6°
(b) Effective flux
S = 1200 \times 0.929 = 1115 \text{ W/m}^2
Below is an interactive model showing solar flux on a tilted surface.
<label>
Surface slope (β):
<input type="range" id="slope-slider" min="0" max="60" step="5" value="30">
<span id="slope-value">30</span>°
</label>
<label>
Surface aspect (0° = N, 90° = E, 180° = S, 270° = W):
<input type="range" id="aspect-slider" min="0" max="360" step="15" value="180">
<span id="aspect-value">180</span>° (S)
</label>
<label>
Solar elevation:
<input type="range" id="elevation-slider" min="10" max="90" step="5" value="45">
<span id="elevation-value">45</span>°
</label>
<label>
Solar azimuth (0° = N, 90° = E, 180° = S):
<input type="range" id="azimuth-slider" min="0" max="360" step="15" value="180">
<span id="azimuth-value">180</span>° (S)
</label>
<label>
Incoming flux (S₀):
<input type="range" id="flux-slider" min="500" max="1200" step="50" value="1000">
<span id="flux-value">1000</span> W/m²
</label>
<p id="incidence-angle"></p>
<p id="effective-flux"></p>
<p id="comparison"></p>
Try this: - Default (30° south-facing slope, sun at 45° elevation due south): Near-optimal alignment, high flux - Change aspect to 0° (north-facing): Flux drops dramatically - Set slope to 0° (horizontal): See how flux varies only with sun angle, not aspect - Solar elevation to 90° (sun directly overhead): Horizontal surface receives maximum; all slopes receive equal flux - Explore the polar plot: shows how flux varies with aspect for the current slope and sun position
In the Northern Hemisphere: - The sun is always in the southern part of the sky at midday - South-facing slopes tilt toward the sun → smaller angle of incidence → more energy - North-facing slopes tilt away from the sun → larger angle of incidence → less energy
This creates topoclimate effects: - South-facing slopes: warmer, drier, different vegetation (e.g., grassland vs. forest) - North-facing slopes: cooler, moister, more shade-tolerant species - Snowpack persists longer on north-facing slopes
The sun’s elevation changes with season: - Summer solstice: High solar elevation → even horizontal surfaces receive high energy - Winter solstice: Low solar elevation → south-facing slopes receive much more than horizontal surfaces
This is why winter heating in buildings benefits more from south-facing windows than summer cooling suffers from them.
For maximum annual energy collection at latitude \phi: - Tilt angle \approx \phi (equal to latitude) - Face south (Northern Hemisphere) or north (Southern Hemisphere)
For maximum winter energy (heating season): - Tilt angle \approx \phi + 15°
For maximum summer energy (if needed): - Tilt angle \approx \phi - 15°
Slope is how steep the surface is (0° = flat, 90° = vertical).
Aspect is which direction the surface faces (0° = north, 180° = south).
A 30° north-facing slope and a 30° south-facing slope have the same slope but opposite energy receipts.
If \theta > 90°, then \cos \theta < 0. This means the surface is tilted away from the sun (backside).
In reality, a backside surface receives zero direct solar radiation. The model should set negative values to zero:
S = S_0 \max(0, \cos \theta)
Our model assumes all radiation is direct (straight from the sun). In reality: - Diffuse radiation (scattered by atmosphere and clouds) comes from all directions - On cloudy days, diffuse radiation dominates (50–100% of total) - Diffuse radiation is less sensitive to surface orientation
Full solar models separate direct and diffuse components.
A slope may be oriented toward the sun but still in shadow due to adjacent ridges or peaks. This requires viewshed analysis (Model 9 previews this).
For a right triangle with angle \theta:
\sin \theta = \frac{\text{opposite}}{\text{hypotenuse}}
\cos \theta = \frac{\text{adjacent}}{\text{hypotenuse}}
\tan \theta = \frac{\text{opposite}}{\text{adjacent}}
On the unit circle (radius = 1): - \cos \theta is the x-coordinate - \sin \theta is the y-coordinate - \theta is measured counterclockwise from the positive x-axis
\mathbf{a} \cdot \mathbf{b} = \mathbf{b} \cdot \mathbf{a} (commutative)
\mathbf{a} \cdot (\mathbf{b} + \mathbf{c}) = \mathbf{a} \cdot \mathbf{b} + \mathbf{a} \cdot \mathbf{c} (distributive)
\mathbf{a} \cdot \mathbf{a} = |\mathbf{a}|^2 (magnitude squared)
If \mathbf{a} \cdot \mathbf{b} = 0, the vectors are perpendicular.