Fractal Recursion, Bounded Infinity, and Adapted systems
From the publisher’s feed, collected in the ZeroLabs newsroom.
What fractals, loss landscapes, and dynamical stability reveal about adaptation under constraintOptimization in the loss landscape. Gradient-based optimization traces a trajectory through parameter space toward regions of lower training loss. The geometry surrounding a solution reflects its local sensitivity to parameter perturbations, but this geometry is parameterization-dependent and does not by itself determine generalization. Image by author (Used AI)Is lower training loss always equivalent to a better model?In deep learning, optimization is often described as a search for parameter configurations that minimize an objective function. Yet the endpoint alone does not tell us how robustly a solution behaves, how sensitive it is to perturbation, or how well it will generalize beyond the conditions under which it was trained. Convergence, generalization, robustness, and adaptability are related, but they are not the same property.This matters whenever a model must operate beyond the conditions captured by its training objective. Real systems encounter distribution shifts, noisy inputs, changing contexts, and new information; a solution that performs well at the end of training may still respond poorly when those conditions change. Optimization therefore raises a practical question as well as a mathematical one: not only whether a model reaches a low-loss solution, but how that solution behaves when the conditions around it change.This distinction motivates a broader question: what does it mean for a learning system to remain stable without becoming rigid? A model may fit its observed data increasingly well without necessarily becoming better at handling unseen inputs, shifts in data distribution, or future adaptation. The relevant question is therefore not simply how completely a system can be optimized, but what kind of stability allows useful structure to persist while remaining responsive to change.This question extends beyond optimization. Imperfection is often treated as something to be corrected, reduced, or eliminated. Yet some systems persist not by removing variation altogether, but by keeping change within workable bounds. In such systems, incompleteness is not merely the absence of a finished state. It is a dynamic condition in which continuity is sustained through ongoing transformation.A geometric model makes this possibility unusually clear. The Koch snowflake is generated by repeatedly applying the same local rule. As the iterations continue, its boundary becomes increasingly elaborate and its perimeter grows without bound, while its enclosed area approaches a finite limit. The figure therefore realizes a precise structural possibility: indefinitely continuing recursive elaboration under a global constraint.In this article, I first treat this structure as a mathematical and computational object, and only then extend it as a broader conceptual analogue. Through Python-generated Koch snowflakes, visualizations of loss landscapes, and a comparison between Lyapunov and asymptotic stability, I examine a recurring question across optimization and adaptive systems: must a system converge to a fixed state in order to persist, or can useful stability coexist with continued reorganization?The aim is not to claim that neural networks, memory, and consciousness operate through the same mechanism. Rather, it is to ask what becomes visible once we distinguish boundedness from stasis, stability from convergence, and persistence from completion.Bounded Infinity: From Fractals to Adaptive SystemsA finite system need not be structurally static. The Koch snowflake provides a mathematically exact example: repeated local transformation produces indefinitely finer structure while the global object remains bounded. I use this duality — continued generativity under finite constraint — as the formal starting point for the argument that follows.1.1 Formal Duality: Infinite Perimeter, Bounded AreaThe same recursive rule produces divergence in one geometric quantity and convergence in another.Figure 1. Divergent perimeter and bounded area in the Koch snowflake. As the recursive construction proceeds, the perimeter grows by a factor of 4/3 at each iteration, while the enclosed area converges toward the finite limit A∞ =8/5 A_0. Image by author.1.2 Python ImplementationThe recursive transformation is implemented below; the complete snowflake generator, visualization routine, and plotting code are available in the accompanying GitHub Gist.Koch snowflake across successive iterations. Repeated application of the same local transformation produces increasingly fine boundary structure while the overall geometry remains bounded. Image by author.def koch_segment(p1, p2, depth): if depth == 0: return np.array([p1, p2]) one_third = p1 + (p2 - p1) / 3 two_thirds = p1 + 2 * (p2 - p1) / 3 vector = two_thirds - one_third angle = -np.pi / 3 rotation = np.array([ [np.cos(angle), -np.sin(angle)], [np.sin(angle), np.cos(angle)] ]) peak = one_third + rotation @ vector return np.vstack([ koch_segment(p1, one_third, depth - 1)[:-1], koch_segment(one_third, peak, depth - 1)[:-1], koch_segment(peak, two_thirds, depth - 1)[:-1], koch_segment(two_thirds, p2, depth - 1) ])The implementation is deliberately simple: complexity arises not from increasingly complicated instructions, but from repeated application of the same local transformation.The recursive rule can also be expressed quantitatively. At iteration n, the boundary consists ofsegments, while the length of each segment isand henceEach iteration thus increases the number of segments faster than it decreases their individual length: a fourfold proliferation competes with a threefold contraction, producing a net perimeter factor of 4/3.Its complexity grows without bound even as its global extent remains bounded. Here, indefinite elaboration does not require an escape from constraint; it emerges through repeated transformation within it.This distinction concerns the geometry of the object itself rather than merely the way in which that geometry is represented. A single Koch curve forming part of the snowflake boundary, for example, may be parameterized in different ways without changing the geometric image being traced. This distinction between representation and underlying structure will become important again in optimization.From Recursion to OptimizationThe Koch construction shows how repeated local transformations accumulate into a global geometric structure. Optimization follows a different mechanism, but a related iterative logic: repeated local updates generate a trajectory through parameter space rather than an increasingly elaborate geometry.This shift from recursive geometry to iterative optimization brings us to gradient descent, where each parameter state determines the update that follows.Gradient Descent as an Iterative Trajectoryθt : parameter state at iteration tη: learning rate∇L(θt ): loss gradient evaluated at the current state−η∇L(θt ): parameter update in the negative-gradient directionEach update changes the state from which the next gradient is evaluated. Gradient descent therefore unfolds as a sequence of state-dependent updates, tracing a trajectory through parameter space.Figure 3. Optimization trajectory and local loss geometry in a toy neural network. A. Training loss over 300 epochs. B. PCA projection of the high-dimensional parameter trajectory. C. Training loss evaluated on a two-dimensional plane around the final parameter vector using the leading PCA directions. The contours illustrate direction-dependent local sensitivity within the selected slice. Image by author.The full Python implementation used to generate this figure is available in the accompanying [Google Colab notebook].To make this geometry concrete, I trained a small multilayer perceptron on a two-dimensional synthetic classification task and recorded its parameter vector throughout optimization. The training objective decreased steadily over 300 epochs (Figure 3-A). I then projected the resulting high-dimensional parameter trajectory onto its first two principal components for visualization (Figure 3-B). Finally, I evaluated the training loss on a two-dimensional plane around the final parameter vector, using the leading PCA directions (Figure 3-C). The resulting contours reveal direction-dependent local sensitivity within this selected slice. This experiment is intended as a computational illustration of optimization geometry rather than as a benchmark of generalization.This visualization provides only a low-dimensional, parameterization-dependent view of the loss landscape; it does not represent the full geometry or provide a parameterization-invariant measure of generalization.Navigating the Loss LandscapeA low training loss describes the value attained at a particular solution, but not the geometry surrounding it. Two solutions with similarly low training loss may differ substantially in their sensitivity to parameter perturbations. S. Hochreiter and J. Schmidhuber, Flat Minima (1997), Neural Computation 9(1), 1–42. formalized this intuition through the notion of flat minima, while N. S. Keskar, D. Mudigere, J. Nocedal, M. Smelyanskiy, and P. T. P. Tang, On Large-Batch Training for Deep Learning: Generalization Gap and Sharp Minima (2017), International Conference on Learning Representations (ICLR). later reported an empirical association between sharper solutions and poorer generalization in large-batch deep-network training.Intuitively, loss remains relatively low across a broader neighborhood around a flat minimum, whereas comparatively small perturbations around a sharp minimum can produce a rapid increase in loss.A sequence of gradient-descent updates can be viewed as a trajectory through a loss landscape. In this space, each point in parameter space corresponds to a particular value of the objective function. From this perspective, optimization is not merely the act of reaching a low-loss point; it is also a path through a geometric space whose local structure can influence where training ultimately arrives.Figure 4. Schematic optimization trajectory through a loss landscape. Successive parameter updates trace a path through regions with different local geometries. Narrow and broader basins are shown as schematic features of the objective landscape; their relationship to generalization should not be interpreted as a universal one-to-one rule. Image by author.The visual width of a basin, however, is only a low-dimensional intuition for a geometry that exists in a high-dimensional parameter space. Near a local minimum θ, the loss can be approximated by a second-order Taylor expansion:where H = ∇²L(θ∗) is the Hessian evaluated at the minimum. Because the first-order term vanishes at a differentiable local minimum, the local change in loss is governed, to second order, by the curvature encoded in H.Assuming that the Hessian is positive definite, consider the set of perturbations for which the quadratic increase in loss remains below a tolerance ϵ:Writing the eigendecomposition of the Hessian asand expressing the perturbation in the corresponding eigenvector coordinates,gives,The resulting level set is an ellipsoid whose principal radii areLarge Hessian eigenvalues therefore correspond to directions of stronger curvature and shorter radii, whereas smaller eigenvalues correspond to gentler curvature and longer radii. In this local quadratic picture, a flatter region is not simply one that appears visually broad: it permits larger parameter perturbations along one or more directions before the loss exceeds the chosen tolerance.Figure 5. Flat and sharp minima through Hessian geometry. Under a local quadratic approximation with a positive-definite Hessian, smaller Hessian eigenvalues correspond to larger principal radii and a larger local low-loss volume. This geometric notion of flatness is parameterization-dependent and does not, by itself, guarantee better generalization. Image by author.The same interpretation can be expressed in terms of local volume. In d parameter dimensions,For fixed d and ϵ,The determinant therefore provides a compact volume-based intuition within this quadratic approximation: collectively smaller curvature eigenvalues correspond to a larger local low-loss ellipsoid, while larger curvature produces a smaller one.This geometric picture connects to earlier work on generalization. Hochreiter and Schmidhuber (1997) associated extended low-error regions in weight space with lower expected overfitting, while Keskar et al. (2017) later reported that large-batch training tended to converge to sharper solutions than small-batch training. They proposed that noise in small-batch gradient estimates may contribute to this difference.The useful conclusion, however, is narrower than a universal rule that “flat” is good and “sharp” is bad. Training loss alone does not determine generalization, and local curvature describes properties of a particular region of parameter space rather than a complete account of model behavior.More importantly, this geometric interpretation requires a further qualification: flatness is not generally invariant under reparameterization. This raises a more fundamental question about which properties survive a change of representation.What Survives a Change of Representation?The Hessian provides a local description of the geometry surrounding a solution in parameter space. Yet this description raises a more fundamental question: which properties belong to the learned function itself, and which depend on the coordinates through which that function is represented?This distinction matters because parameter-space geometry is not necessarily invariant under reparameterization. [3] L. Dinh, R. Pascanu, S. Bengio, and Y. Bengio, Sharp Minima Can Generalize For Deep Nets (2017), Proceedings of the 34th International Conference on Machine Learning (ICML), PMLR 70, 1019–1028. showed that functionally equivalent deep networks can exhibit substantially different measures of sharpness. In other words, two parameter vectors may represent the same input–output function,while the local geometry surrounding θ and θ̃ appears markedly different. A minimum that is sharp under one parameterization may therefore correspond to a functionally equivalent representation with very different apparent curvature. Flatness, although useful as a local geometric description, should not by itself be treated as an invariant property of the learned function.The distinction becomes clearer by returning briefly to the Koch curve. Let a Koch curve be represented by a continuous parameterizationUnder a suitable reparameterization ϕ:[0,1] → [0,1],Although the indexing or traversal of points along the curve changes, the geometric image does not:Properties belonging to that geometric image — such as its self-similar structure and Hausdorff dimension — therefore remain properties of the same object rather than artifacts of how its points are parameterized. For the Koch curve,regardless of how the same geometric image is traversed by an admissible reparameterization.The comparison with deep networks is deliberately limited.A reparameterized Koch curve and a reparameterized neural network are not mathematically equivalent constructions. Rather, their contrast exposes a common methodological problem. In the Koch curve, the representation can change while the relevant geometric object remains unchanged; in a neural network, the represented function can remain unchanged while aspects of its apparent parameter-space geometry change. The question is therefore not simply what a representation looks like, but which properties survive a change of representation, and which belong only to the coordinates used to describe the system?Stability Does Not Require ConvergenceThe geometry of an optimization trajectory raises a broader question: does stability necessarily require convergence to a single fixed point? In dynamical systems, the answer is no. Stability and convergence are related, but they are not identical properties.A system can remain bounded under perturbation without collapsing onto a single equilibrium. This distinction matters for the argument developed here because it separates persistence within a viable region from asymptotic arrival at one final state.Asymptotic Stability vs. Lyapunov StabilityIn an asymptotically stable system, trajectories that begin sufficiently close to an equilibrium remain nearby and eventually converge to it. Lyapunov stability is weaker: trajectories that start sufficiently close remain sufficiently close for all future time.Formally, an equilibrium x\* is Lyapunov stable if, for every ε>0, there exists a δ>0 such thatAsymptotic stability adds the further requirement thatThe distinction is simple but important: stability constrains motion; asymptotic stability additionally requires convergence.A Python Comparison of Two Stable SystemsTo make this distinction visible, consider two simple two-dimensional systems. The first is damped and converges toward the equilibrium at the origin. The second is an undamped harmonic oscillator whose trajectories remain bounded but continue indefinitely without converging.For the undamped system,we can defineAlong a trajectory,The value of V therefore remains constant, so trajectories stay on closed level sets rather than collapsing onto the origin.Figure 6. Asymptotic stability versus Lyapunov stability. The damped system on the left converges toward the equilibrium at the origin, whereas the undamped harmonic oscillator on the right remains bounded on a closed trajectory without converging. Image by author.The comparison illustrates a property central to the present argument: bounded persistence does not logically require asymptotic convergence. A system may continue to evolve while remaining within a stable region of state space.This does not mean that non-convergence is inherently desirable in machine learning, nor that an undamped oscillator is a model of intelligence. Rather, the example provides a formal distinction that helps sharpen the optimization question raised above: if useful behavior depends not only on reaching low loss but also on remaining robust under perturbation, then convergence to a single point is only one possible form of stable behavior.The example does not imply a formal equivalence between Lyapunov stability and robustness in optimization. Rather, it supplies a useful distinction by analogy: convergence to a single point is not the only way a system can exhibit constrained, persistent behavior.Memory as Recursive ReconstructionThe iterative structure discussed above also provides a useful language for thinking about autobiographical memory. Retrieval is not equivalent to reading an unchanged record from storage; remembering is reconstructive, shaped by the current state of the remembering system and the context in which retrieval occurs.As a conceptual schematic, this process can be written aswhere Mn represents the current memory state, Cn the retrieval context, and In new information available during reconstruction. This is not intended as an established computational model of memory, but as a compact representation of context-sensitive reconstruction.Memory therefore illustrates a broader distinction: persistence does not require exact preservation. What continues across retrievals may be an organized structure capable of reconstruction rather than an unchanged representation.Persistence Far From EquilibriumLiving systems maintain boundaries between themselves and their environments, yet persistence also requires exchange across those boundaries.Persistence in living systems poses a related problem: maintaining identity requires boundaries, but maintaining life requires exchange across them.Biological self/non-self discrimination offers one example of selective boundary maintenance. A viable boundary cannot simply eliminate interaction with the environment; living systems continuously exchange matter and energy while regulating internal variables within ranges compatible with continued function.Homeostasis should therefore not be confused with thermodynamic equilibrium. Biological organization is maintained through ongoing flux, regulation, and energy dissipation.Perturbation need not be purely destructive: within viable bounds, it may be absorbed through regulation or accompanied by reorganization. Persistence therefore depends not on instability itself, but on the capacity to regulate or reorganize before perturbation becomes destabilizing.What Consciousness AddsThe Koch snowflake offers one geometric model for thinking about this distinction. Its boundary can undergo indefinite recursive elaboration while the total region it encloses remains finite. Consciousness need not be claimed to possess a literally fractal architecture for this geometry to be conceptually useful. If conscious processing is bounded in capacity yet capable of repeatedly recombining, revising, and extending what becomes available within those bounds, then the Koch construction provides a structural analogy: finite constraint need not imply finite generativity.The resemblance lies not in mechanism but in organization. In both cases, continued transformation occurs without requiring the system to escape its bounds. What remains globally constrained may nevertheless support continued differentiation and recombination within those constraints.Much information processing occurs without conscious access. Consciousness is therefore not a prerequisite for cognition as such. What conscious access appears to add, on influential global-workspace accounts, is a form of broader and more durable availability: information can become accessible across multiple systems and support some forms of report, intentional control, novel combination, and extended processing.The relevant point here is not that consciousness creates cognition from nothing, but that conscious access may help keep information available for continued recombination and action. In the vocabulary developed throughout this article, consciousness is therefore relevant not because it abolishes constraint, but because it may expand what can be repeatedly accessed, recombined, and reorganized within constraint.Stability without the capacity for reorganization may preserve a state without preserving adaptability.The analogies above do not imply that neural networks, biological systems, and autobiographical memory share a common mechanism. They do, however, suggest a useful engineering distinction between stability and rigidity.In machine learning, a model that achieves a very low training loss is not necessarily the model best equipped to generalize beyond its training data or remain useful under perturbation. Continual learning introduces an additional requirement: new information must be incorporated without catastrophically erasing previously useful structure.From this perspective, the relevant design goal is not simply convergence toward a frozen optimum. It is the preservation of enough structure for a system to remain useful while retaining the capacity to adapt.The broader lesson is not that flatter minima, continual adaptation, or robustness are equivalent. Rather, they each expose a limitation of evaluating learning solely by the attainment of a single low-loss endpoint.What These Analogies Can — and Cannot — Tell UsThese comparisons operate at different explanatory levels. Some are mathematical results, some are computational mechanisms, some are empirical theories, and others are structural analogies. Their value lies not in collapsing these levels into a single mechanism, but in using formally clearer systems to isolate recurring questions about constraint, stability, and continued transformation.On this view, cognition is not simply the preservation of an established order, but an ongoing capacity for revision and recombination.Human–Machine Coupling Beyond AnalogyHuman cognition and machine learning need not share an underlying mechanism to exhibit comparable computational motifs. Both operate under finite constraints, transform incoming information through learned or accumulated structure, and allow prior states to shape subsequent processing.The relation becomes more interesting when comparison gives way to interaction. A human user is not merely another information-processing system placed beside the model; in interactive use, the user can become part of the model’s effective computational environment. Human cognition enters the loop by selecting goals, framing prompts, evaluating outputs, rejecting inadequate trajectories, and recursively introducing the products of earlier iterations as new inputs.Contemporary LLM systems make this distinction concrete. A model’s behavior can change substantially with context and feedback even when its parameters remain fixed during an interaction. In-context adaptation therefore differs from persistent learning through parameter updates: the former changes the computation induced by the current context, whereas the latter changes the model itself.The relation between human cognition and machine learning therefore becomes most interesting not at the level of identity, but of coupling. A bounded model can participate in a larger adaptive system whose effective trajectory is continually reshaped by context, feedback, and human selection.Infinite Persistence Within ImperfectionAcross these examples, the same distinction has appeared in different forms. The Koch snowflake seperates boundness from limited elaboration; optimization separates low training loss from generalization; Lyapunov theory separates stability from convergence; reconstructive memory separates persistence from exact preservation; and living systems separate maintenance from equilibrium.Persistence, in each case, is better understood not as the elimination of variation, but as the preservation of structure through it.The distinction between representation and structure sharpens this conclusion. What persists through transformation need not be an identical state, trajectory, or representation. The more useful question is what remains structurally meaningful as those forms change.Persistence is not necessarily the absence of transformation. Under constraint, it may be the capacity to continue through it.Fractal Recursion, Bounded Infinity, and Adapted systems was originally published in Towards AI on Medium, where people are continuing the conversation by highlighting and responding to this story.