arXiv:2610.19942cs.LGOct 2026

Manuscript Offprint

arXiv:2610.19942

MorphingNet: Symbolic Regression Where the Network Is the Formula

Jincheng Gao, Jiahe Yi, Shuo Sun

Abstract

We introduce MorphingNet, a network for symbolic regression (SR) whose units change their function continuously. Instead of searching over expressions built from a fixed operator library, MorphingNet trains the form of each function as a parameter, so SR becomes one continuous optimization problem. Its units are either pole-free rational functions or complex exponential-logarithm functions, which move between exponentials, sinusoids, damped oscillations, power laws and logarithms as their parameters change. The network is a readable formula at every step of training, and no operator library is needed to train it; a structure-recovery step afterwards rewrites the trained formula into short elementary expressions. Training is dense linear algebra, so it is GPU-friendly and scales to large data. MorphingNet achieves state-of-the-art accuracy on SRBench, recovers most generating formulas on synthetic benchmarks, and on large data is up to two orders of magnitude faster than the strongest search method. By turning the search for a formula into the training of a network, MorphingNet offers a new paradigm for SR and for scientific discovery from data.

1. Introduction

Symbolic regression (SR) looks for a closed-form expression y=f(x)y = f(\mathbf{x}) that fits data. It chooses both the structure of the expression and its constants. Because the answer is a formula, people can read it, check it against theory and reuse it. SR has recovered physical laws from measurements (Schmidt & Lipson, 2009; Udrescu & Tegmark, 2020) and extracted equations from trained networks in astrophysics (Cranmer et al., 2020). In materials science it has rediscovered the Johnson–Mehl–Avrami–Kolmogorov transformation law and a Landau free energy (Wang et al., 2019). Most SR methods are genetic programming (GP) (Koza, 1992). GP evolves a population of expression trees built from an operator library, such as {+,×,sin⁡,exp⁡}\{+, \times, \sin, \exp\}. Each generation mutates and recombines the trees and scores every one on the data. This search is slow. Its cost grows with the number of samples, and data sets of 10510^5 to 10610^6 samples are now common. On a million samples, Operon (Burlacu et al., 2020), one of the fastest GP systems, takes a median of 11.8 hours per problem in our experiments.

A natural idea is to run SR on a GPU, as deep learning does. This is harder than it sounds. A GPU is fast when it repeats one operation on large, uniformly shaped arrays. A GP population holds many trees of different shapes, and each tree is a different program. Recent systems still move evaluation, constant fitting and even variation onto the GPU (Zhang et al., 2022; de Vries et al., 2025; Wu et al., 2025; Mao et al., 2026). These systems make each evaluation faster, but the search itself stays discrete. Every step proposes new trees, and each must be evaluated on all the data. A GPU speeds up the arithmetic, not the number of trees the search must try. What a GPU does best is continuous optimization: one model, updated by one dense step on all the data, repeated until convergence. Deep learning scales because its training has this form, and GP does not.

So the search should become training. A line of work does exactly this by making the network itself the formula. EQL (Martius & Lampert, 2016; Sahoo et al., 2018) and its successors (Li et al., 2024; Wu et al., 2024) build networks whose units are elementary operators and train them by gradient descent. ParFam (Scholl et al., 2025) fits rational functions composed with preselected elementary functions. These are elegant steps toward SR as continuous optimization. They optimize continuously, but the functions available to their units are chosen in advance. In scientific discovery, we may not know which functions to choose. An unfamiliar relationship may have no simple expression in the chosen library, even when its shape is simple. This motivates a different approach: learn the shape of each function first, then seek a familiar symbolic description. The learned shape remains available for inspection even when no such description is found.

The Kolmogorov–Arnold Network (KAN) (Liu et al., 2025; 2024) takes this route. It places a learnable spline on every

1^{1}Thrust of Financial Technology, The Hong Kong University of Science and Technology (Guangzhou), Guangzhou, China. Correspondence to: Shuo Sun shuosun@hkust-gz.edu.cn.

Preprint. October 15, 2026.

edge. Splines are flexible, and their shape is optimized continuously, like any network weight. The library is used only at the end, to replace each spline by a matching symbolic function. But a spline gains flexibility only by adding knots, and every knot is a constant. So accuracy and length grow together. Written out, a KAN is a spline soup: hundreds of piecewise constants, nested layer by layer. The symbolic matching that shortens it is approximate, so the exported formula loses accuracy.

This raises a question. Can SR be a continuous optimization problem that runs at scale, and still return a formula that people can read: a short expression, or one whose structure, such as an inner product, is visible?

Our answer is a network whose units change their function continuously. We call it MorphingNet. A unit's function is not picked from a list. It morphs from one form into another, for example from an exponential into a damped sinusoid, as training moves its parameters. So the form of the function is learned like any weight, and the network stays a closed-form expression throughout. Like KAN, MorphingNet learns function shapes from data, but each learned unit is itself a closed-form expression that can be plotted, inspected and then simplified. Such units need a basis as flexible as the B-spline, but one whose elements are closed-form functions. We use two families. The first is the rational function. Rationals approximate far better than polynomials of the same size: they reach ∣x∣|x| at the root-exponential rate e−cne^{-c\sqrt{n}} where polynomials reach it at an algebraic one (Newman, 1964), and Padé approximants represent analytic functions with few constants (Baker & Graves-Morris, 1996). Rational activations have already been used inside neural networks (Molina et al., 2020; Aghaei, 2024). The second family is the exponential of a complex logarithm. One formula with a few continuous parameters covers exponentials, sinusoids, damped oscillations and power laws. Its closest relative is the soft exponential activation (Godfrey & Gashler, 2016), which interpolates between logarithm, identity and exponential and becomes sinusoidal when its parameter is complex. Our unit composes its logarithmic and exponential branches, so that power laws and damped oscillations appear in the same unit. Unlike a spline, each of these functions is global: a few parameters describe it on the whole domain. Each unit first projects its inputs onto a learned direction, as in projection pursuit (Friedman & Stuetzle, 1981), and then applies a rational or complex exponential–logarithm function. Product ports let units multiply as well as add. The whole network is a smooth least-squares problem, so we train it with a second-order method and prune it with a sparse group penalty. Every training step is a dense matrix operation, so it runs on CPU and GPU alike. The trained network is already a real-valued formula and exports without approximation.

As trained, these formulas are accurate but long. No library is used during training, so a rational unit cannot write sin directly. To our surprise, the units learn approximation schemes of their own. A rational unit represents a sinusoid or an exponential by a Padé-type rational function, and redundant branches cancel each other. These long formulas hide short ones. This motivates a structure-recovery step that rewrites the trained formula under a fixed error bound. It replaces approximations by elementary functions and recovers inner products. A library enters only here, and its role differs from its role in GP. It does not search for the formula; the formula already exists and is accurate. The library only rewrites it in a shorter vocabulary, and users can extend it for their domain. In one case, a trained formula with 48 operations and 519 constants, fitted to a million samples in 50 dimensions, became 0.796ez2sin⁡z10.796 e^{z_2} \sin z_1. Here z1z_1 and z2z_2 are learned linear combinations of the inputs, and the 45 irrelevant inputs dropped out of them.

The results bear out all three requirements. On the 130 ground-truth problems of SRBench (La Cava et al., 2021), over ten seeds, MorphingNet reaches R2>0.999R^2 > 0.999 on 96 to 97% of problems at the three lower noise levels, against at most 88% for the published methods, and on 70% at the highest level, against at most 68%. On 104 targets whose functions lie in the library, structure recovery returns the generating formula in 96 cases, with median 7 operations and 10 constants against 16 and 16 for Operon. On a million samples, MorphingNet runs in about five minutes on a GPU, 123 times faster than Operon.

Our contributions are:

  1. Morphing units. A network of projections followed by rational and complex exponential–logarithm units, joined by product ports. The form of each function is optimized continuously, and the trained network is a formula without loss (Section 3.1).

  2. Accuracy. The highest accuracy among the SRBench methods on its ground-truth problems, at every noise level, with ablations that trace the gain to projection, and product ports to multiplicative targets (Sections 4.1 and 4.2).

  3. Structure recovery. A post-training rewrite that shortens formulas under a fixed error bound and recovers the generating formula in most cases. A library is used only here, and can be extended by the user (Sections 3.4 and 4.3).

  4. Scale. Second-order training on CPU and GPU that matches GP at small scale and is one to two orders of magnitude faster on large data (Sections 3.5 and 4.4).

References (41)