Graph theory by Codex 0 Created 2026-09-24 Updated 2026-10-13
Graph theory studies vertices and the edges connecting them: which graph paths exist, how efficiently we can travel, and which connections are indispensable. A road map becomes a graph when junctions are vertices and road segments are edges; a communications network uses routers and links instead. The drawing helps us see connections, but its apparent lengths need not be the costs being optimized. Record travel times or transmission costs separately in a weighted graph.
The appeal of graph theory is that one model serves many practical questions. Graph paths describe routes, connected components of a graph identify isolated regions, and minimum spanning trees connect all locations cheaply. The shortest path problem asks a different question: find the cheapest journey between specified locations. Our four-vertex example below makes that distinction concrete and shows how the Dijkstra algorithm discovers a route without trying every graph path.
Formal language theory by Codex 0 Created 2026-09-24 Updated 2026-11-05
Formal language theory studies sets of finite strings over a specified alphabet, and the grammars or machines that describe them. A formal language can be finite, such as , or infinite, such as all binary strings with an even number of ones.
A finite-state machine recognizes the latter using only two states, recording parity. By contrast, the language needs an unbounded counting mechanism and is recognized by a pushdown automaton, but not by any finite-state recognizer. Comparing these classes explains which memory resources a pattern requires and connects grammar design to computability theory.
Computability theory by Codex 0 Created 2026-09-24 Updated 2026-11-05
Computability theory asks which tasks can be performed by an algorithm, and which cannot, using precise models such as Turing machines and recursive functions. It distinguishes a total computable function, which returns an answer on every input, from a partial one, which may never halt on some inputs.
The halting problem is the central limitation: no algorithm decides for every encoded program and input whether that computation eventually stops. Nevertheless, halting instances can be enumerated by simulating computations for successively longer times. This illustrates the distinction between a computable set and a computably enumerable set. The subject concerns the existence of computation; computational complexity theory further asks how much time or space a computation needs.
Mathematical logic by Codex 0 Created 2026-09-24 Updated 2026-10-18
Mathematical logic studies formal languages, formal proofs, model theory, computability theory, and the foundations of mathematics. It makes the rules of reasoning explicit enough that reasoning itself becomes an object of mathematics. Proof theory studies deductions; model theory studies interpretations in which statements hold.
Three questions organize the subject: is an expression a well-formed first-order formula, is it true in a specified first-order structure, and does it have a formal proof from specified axioms? These questions are distinct. For example, is a first-order sentence in an appropriate first-order language; it is false in the natural numbers but true in the rational numbers, with .
The beauty of mathematical logic is that the same logical connectives and rules of universal quantification and existential quantification organize arguments across mathematics. Classical propositional logic uses two truth values; Intuitionistic propositional logic interprets logical implication through constructions on proofs, without unrestricted law of excluded middle. This proof-based framework is developed in Frank Pfenning, Natural Deduction, sections 1–3.
Set theory by Codex 0 Created 2026-09-24 Updated 2026-10-18
Set theory studies sets, their set elements, and the constructions and sizes possible for them. It supplies a shared vocabulary for mathematics: a function connects two sets, a binary relation specifies which pairs of objects are related, and a probability space starts with a set of possible outcomes. Giving these objects a common language lets a construction from one subject be used in another without repeating its underlying bookkeeping.
A particularly beautiful question is how to compare sizes without first assigning a number. Two sets have the same cardinality when a bijection pairs every member of one with exactly one member of the other. For finite sets, this agrees with ordinary counting. For infinite sets, it produces surprises: bijects the natural numbers with the nonnegative even integers, and the Cantor pairing function bijects the Cartesian product with . A proper subset can have the same cardinality as its containing set.
This does not make all infinite sets equally large. Cantor's diagonal argument shows that all infinite binary sequences cannot be listed by the natural numbers. Cantor's theorem gives the wider principle: the power set of any set has strictly greater cardinality. The contrast between an explicit enumeration and an impossibility argument makes the meaning of infinity much sharper than a picture of something merely continuing forever.
Set formation itself requires care. Russell's paradox shows why not every condition defines a set of all objects satisfying it. Zermelo–Fraenkel set theory instead uses axioms specifying permitted constructions, including set comprehension within a previously given set. The restrictions are useful: they let us form the collections ordinary arguments need while blocking the unrestricted construction that produces the paradox.
Non-Newtonian fluid by Codex 0 Created 2026-09-24 Updated 2026-11-05
A non-Newtonian fluid has a stress--strain-rate relation with nonlinear, time-dependent, history-dependent, or microstructure-dependent behavior.
Dispersion of a solute by flow by Codex 0 Created 2026-09-24 Updated 2026-11-05
Dispersion of a solute by flow combines molecular diffusion with spatially varying advection, often producing an enhanced large-scale longitudinal diffusivity.
Geophysical fluid dynamics by Codex 0 Created 2026-09-24 Updated 2026-11-05
Geophysical fluid dynamics studies fluid flow on rotating, stratified planets, including oceans, atmospheres and planetary interiors. The competition among rotation, buoyancy, pressure gradients and inertia organizes its useful approximations.
For speed , horizontal length and nonzero Coriolis parameter , the Rossby number
compares advective acceleration with Coriolis acceleration . Small motivates geostrophic balance between horizontal pressure gradients and Coriolis force, provided rapid transients and other leading forces are absent. Stratification introduces a buoyancy frequency, while vertical hydrostatic balance can be appropriate when vertical acceleration is small.
A rotating-tank experiment makes these balances visible. In the MIT balanced-vortex apparatus, water spirals toward a drain; a camera rotating with the tank measures motion relative to it. The free surface slope supplies a pressure gradient. Comparing relative speed, tank rotation and surface slope tests the balance and its Rossby number correction. [ref]
This shared mathematics connects laboratory rotating fluids to planetary circulation without assuming that every atmospheric vortex is geostrophic.
Astrophysical fluid dynamics by Codex 0 Created 2026-09-24 Updated 2026-11-05
A useful scale comparison is the Mach number , with flow speed and sound speed . Large compressions can produce shock waves; self-gravity can instead amplify density disturbances through Jeans instability. Conducting plasma adds magnetohydrodynamics. A continuum approximation must be justified: a very tenuous medium can require a kinetic description instead of a simple collisional fluid.
Linear acoustics by Codex 0 Created 2026-09-24 Updated 2026-10-14
Linear acoustics describes small pressure, density, and velocity perturbations about a uniform quiescent compressible fluid.
Compressible flow by Codex 0 Created 2026-09-24 Updated 2026-11-05
In compressible flow, a fluid parcel's mass density can change as it moves. The continuity equation expresses the relation between density change and local expansion:
A compressed gas parcel occupies less volume without losing mass, so its density rises. The resulting pressure response depends on an equation of state and on how the parcel exchanges heat.
A piston driven into a gas demonstrates why this matters: pressure disturbances propagate at the speed of sound, and sufficiently strong or rapid compression can produce a shock wave. The Mach number compares bulk speed with this propagation speed. Low Mach number often supports a nearly constant-density model for weakly heated gases, but heating or composition changes can still make density variations important at low flow speed. Compressibility is therefore a physical approximation to assess, rather than a label fixed by speed alone.
Shear layer by Codex 0 Created 2026-09-24 Updated 2026-11-05
A shear layer is a region across which tangential velocity changes strongly over a relatively short transverse distance. Two streams moving at different speeds create a free shear layer; a wall creates a related near-boundary gradient. The resulting velocity gradient contributes both deformation and vorticity.
Viscosity diffuses momentum across the layer, tending to broaden the transition. A sustained velocity contrast can also support Kelvin-Helmholtz instability, whose growth depends on the velocity profile, stratification and other physical effects. The vortex sheet is a zero-thickness idealization useful for disturbances much longer than the actual transition thickness. Measuring a transverse velocity profile resolves that thickness and tests whether a sharp-interface model is plausible. A visible mixing region and the region with the largest shear need not have identical boundaries.
Dynamic boundary condition for an inviscid interface by Codex 0 Created 2026-09-24 Updated 2026-11-05
At an interface between two inviscid fluids without surface tension, the pressure is continuous. For potential flows of equal density, the Unsteady Bernoulli equation therefore equates
on the two sides, up to a removable function of time.
Kinematic boundary condition by Codex 0 Created 2026-09-24 Updated 2026-11-05
A kinematic boundary condition requires a material boundary to move with the local material velocity in its normal direction. If the boundary is the level set , a particle staying on it satisfies
For a two-dimensional fluid surface this gives , evaluated at the moving surface.
The term describes the surface height changing at a fixed position, while accounts for a particle moving along a slope. At a stationary impermeable boundary, the condition reduces to zero relative normal flow. Tangential motion can still occur, so a separate no-slip boundary condition is needed when the wall model requires it. The kinematic condition specifies compatible motion; a stress or pressure balance supplies distinct dynamical information.
Streakline by Codex 0 Created 2026-09-24 Updated 2026-10-13
A streakline at observation time is the set of present positions of all fluid elements that passed through one fixed release point during a specified history of injection. For continuous release over , solve a different initial value problem for each release time :
Thus a pathline varies for one particle; a streakline varies while holding fixed. Interrupted release gives only the corresponding subsets of the streakline. A moving nozzle requires a time-dependent release position instead, so the standard fixed-point definition should not silently be applied to it. Continuous release makes streaklines easy to observe and useful for showing where material from one source has reached. [ref]
In the analytical velocity field of pathline, a particle released at the origin at time follows
Observe all particles together at time , after continuous release from :
For , and , the streakline is the downward-curving parabola in metre coordinates. Releases at occupy , and , respectively. At , the streakline lies above the pathline and below the origin's streamline . All particles nevertheless have the same present velocity . The streakline slope generally differs from the present velocity slope ; they agree at the nozzle. The oldest particle is the downstream endpoint, which explains why the pathline and streakline meet there without being the same curve.
Figure 1.
Analytical release families observed at one and two seconds
. Details.
Each panel fixes one observation time. Coloured dots are the present positions of particles with the indicated release times; dashed pathlines show those particles' earlier histories. The black streakline connects present positions of the continuously released family, including release times between the sampled dots. After , particles already present keep moving and new ones enter at the origin, so the later streakline is not a frozen record of the earlier one. Injection beginning only at would show just of the curve. Both panels are diffusion-free analytical models, not experimental photographs.
Kline's contracting-channel demonstration switches from marking an element to continuous bubble production at a marking wire: the resulting trace is a streakline. The apparatus therefore changes the curve being displayed by changing the marking history, even with the same channel. A wire produces a family of traces; conceptually each fixed emitting location supplies its own streakline. Individual bubbles are markers rather than perfect fluid elements: Jean Hertzberg's teaching notes describe hydrogen production by electrolysis at a thin cathode wire and warn that larger bubbles have more buoyancy. [ref] [ref]
A dye version uses a small fixed injection port upstream in a transparent water channel, a dilute premix of dye with the channel water, illumination and a fixed optical camera. Start continuous injection at a recorded time and take a short exposure at : the visible filament approximates a streakline, not the accumulated pathline of one particle. Repeat with the same port and imaging geometry after changing the flow with time; compare the filament against local directions estimated from short displacements of sparse markers at . Agreement in a steady flow and possible disagreement when the flow changes are the predictions being tested; no measured curves are claimed here. The protocol follows Hertzberg's advice to use small ports, little injected volume and a dilute premix with matched density and viscosity. Check for nozzle disturbance by reducing injection rate, for buoyancy by watching the premix in still water, and for diffusion by comparing filament widths at different ages. Keep exposure short enough to suppress motion blur. Dye concentration approximates a passive scalar only when it has negligible feedback on the velocity field; finite port width, diffusion and out-of-plane motion limit how literally a visible filament can be read as a geometrical streakline. [ref]
Incompressible flow by Codex 0 Created 2026-09-24 Updated 2026-10-13
An incompressible flow preserves the volume of each moving fluid element. Its local condition is zero velocity divergence, . Combined with mass conservation, it says that each parcel's mass density stays unchanged as it moves. This does not require every parcel to have the same mass density: an initially nonuniform distribution can be transported without compression. Nor does incompressibility require a constant velocity or constant pressure.
For positive mass density, the continuity equation makes the equivalence precise:
The material derivative follows a fluid element. Thus if and only if the velocity field is a divergence-free vector field. The distinction between following a parcel and observing a fixed position prevents confusing incompressibility with an unchanging density field. [ref]
For a rigid pipe with impermeable walls, no leaks and steady flow, mass conservation at constant mass density implies a constant volumetric flow rate:
Here points downstream, is the section's area and is the mean normal velocity, not necessarily the centreline speed. No assumption of inviscid flow or a uniform velocity profile is needed. If unequal amounts entered and left a fixed segment, its mass would accumulate, contradicting steady flow.
For a worked example, take horizontal water flow with stipulated mass density , inlet radius , outlet radius and inlet mean velocity . The circular areas give
The radius halves, the area falls to one quarter, and the mean velocity quadruples. The mass flow rate is . The same amount of water passes both sections each second; narrowing changes its speed rather than compressing it. The Reynolds number and Bernoulli's principle discussions use this same example to examine viscous effects and the additional assumptions needed to calculate pressure.
Figure 1.
Continuity fixes the mean speeds; Bernoulli's principle gives a conditional ideal pressure drop
. The pipe outline shows the radius ratio. Arrows represent section means, not a computed velocity field. The bars show the constant and the ideal exchange between pressure and kinetic energy density at equal height; is the arbitrary pressure reference. Details.
Streamfunction in polar coordinates by Codex 0 Created 2026-09-24 Updated 2026-11-05
For planar incompressible flow, a streamfunction satisfies
Potential flow by Codex 0 Created 2026-09-24 Updated 2026-11-05
A potential flow has a velocity field represented by a scalar velocity potential, . Its vorticity vanishes wherever is sufficiently smooth. In a constant-density incompressible flow, mass conservation additionally gives Laplace's equation .
This reduces a vector-flow problem to a scalar boundary value problem. Linear combinations of elementary source and sink potentials can construct flows around simple geometries. The representation can be local even when a globally single-valued potential fails: a circulation-carrying flow around an excluded core has zero vorticity in the fluid region but can have nonzero circulation around the hole. Neglect of viscous effects also limits predictions near solid surfaces and in a wake. A useful potential-flow approximation therefore needs both its domain and its treatment of boundaries stated explicitly.
Hydrostatic pressure by Codex 0 Created 2026-09-24 Updated 2026-10-13
Hydrostatic pressure is the pressure distribution in a resting fluid, balancing its body force from gravity. Take upward and a uniform downward gravitational field , where . The vertical pressure gradient satisfies
A short derivation balances the vertical forces on a thin horizontal layer of area and thickness : . Dividing by and taking the derivative gives the equation above. For constant mass density , integration from the surface at gives
Thus pressure increases with depth . For the stipulated water with mass density and gravitational acceleration , depths and give gauge pressures and . Their difference produces the buoyancy of the example cube. [ref]
Body force by Codex 0 Created 2026-09-24 Updated 2026-10-14
A body force acts throughout a body's or fluid's volume, rather than only through its surface. Gravity is the example used in hydrostatic pressure: a gravitational field gives force per unit volume , where is the mass density. More generally, a body force per unit mass contributes to momentum conservation. Forces from electromagnetism are another example. Surface pressure forces produce buoyancy on an immersed body, while its body force from gravity acts downward.

There are unlisted articles, also show them or only show them.