How this calculation works
Recover every real vector consistent with magnitude-only linear measurements, identifying solutions that differ only by global sign.
For each sign vector s, solve A x = s elementwise-multiplied by b, then verify |A x|=b.A worked example
Rows (1,0), (0,1), (1,1) with magnitudes 1,2,3 recover one global-sign class, represented by (1,2). The vector (-1,-2) gives the same measurements.
Good to know
Full-column-rank real measurement matrix with dimension2–4 and at most12 rows, nonnegative exact magnitudes and bounded condition number. Enumerate sign patterns, solve/recheck every branch and deduplicate global-sign equivalents. No complex Fourier phase retrieval, noisy least-squares fallback or universal uniqueness claim.
Reference: Balan, Casazza and Edidin: On signal reconstruction without phase (opens in a new tab) ↗
Recovering a real vector without measurement signs
Ordinary linear measurements record the signed entries of A times x. Magnitude-only measurements retain their absolute values and lose those signs. The unknown vector must therefore satisfy several possible signed systems rather than one predetermined system. This page enumerates the supported sign possibilities, verifies every recovered vector and reports the distinct solutions under a stated global-sign convention.
The ambiguity x versus minus x can never be removed from real magnitude-only data because both vectors have the same absolute measurements. The result counts those two vectors as one class. Additional ambiguities can remain even after removing global sign, so a single returned representative is a uniqueness statement only for the entered matrix and magnitudes within the completed bounded search.
Compare this with the Linear system solver. Recover all real vectors consistent with |Ax|=b up to global sign, rather than solve a signed linear equation Ax=b.
Entering exact measurements and a full-rank matrix
Provide a real measurement matrix with between two and four columns and at most twelve rows. Supply one nonnegative magnitude for each row. The matrix must have full column rank; otherwise even fully signed measurements can leave a continuous family of unknown vectors. A numerical rank or condition check prevents a nearly singular solve from being mistaken for a reliable finite reconstruction.
The supported task assumes exact noiseless magnitudes, interpreted with the displayed numerical residual tolerance. Negative magnitudes are invalid rather than signs waiting to be recovered. A zero magnitude imposes a linear equality with zero right-hand side and does not need two separate sign branches. Repeated or redundant rows are allowed only if the full system remains numerically well resolved.
Turning magnitudes into signed systems
For each possible assignment of signs to nonzero measurements, multiply those signs by the magnitude vector and solve A x equal to that signed vector. One measurement sign can be fixed when removing the unavoidable global-sign duplication. This cuts the enumeration without losing any equivalence class, provided the fixed measurement is genuinely nonzero.
An overdetermined signed system may be inconsistent, so a least-squares candidate is only a candidate. It is retained only if the complete original magnitude equations are satisfied within the declared tolerance. Calling every least-squares answer a recovery would replace the requested exact problem with a noisy approximation and could produce an apparently unique vector when no exact vector actually exists.
Deduplicating solution classes
Different sign patterns can lead to the same vector when some measurements vanish or rows are redundant. The search fixes the first nonzero measurement sign to positive, selecting one representative from each global-sign pair. That convention need not make the vector's first coordinate positive. Candidate vectors are compared using a scale-aware tolerance, and the zero vector is handled as its own class.
The output should retain residuals and the actual recovered vectors, not only a count. That lets a user see whether multiple classes differ in meaningful coordinates. A resource cap or an unresolved linear solve invalidates an exhaustive uniqueness claim. In that case, the status must distinguish found candidates from a complete list established by all supported branches.
The three-measurement worked example
The default matrix rows are (1,0), (0,1) and (1,1), with magnitudes one, two and three. The first two measurements restrict the coordinate magnitudes to one and two. The third requires their signed sum to have magnitude three, so the two coordinates must have the same sign. Opposite signs would give magnitude one instead.
There is consequently one global-sign class, represented by (1,2); its negative gives the same measurements. Checking A times that vector yields (1,2,3), whose absolute values reproduce the input. If the third magnitude were one instead, the representative would have opposite coordinate signs. Removing the third row would leave two classes after global-sign equivalence, illustrating the role of an additional measurement.
Residuals and structural tests
For each accepted vector, compute the maximum difference between the predicted absolute measurements and the supplied magnitudes. Also inspect the signed linear residual before deduplication. A tiny residual is necessary for acceptance but does not independently prove exhaustive enumeration; the completed branch count supplies that separate assurance. Numerical tolerance should be stated relative to the measurement scale.
Multiplying every magnitude by a positive scalar should scale every solution by that scalar. Reordering matrix rows together with their magnitudes should leave the solution classes unchanged. Multiplying an individual matrix row by minus one also leaves magnitude data unchanged. These tests can expose accidental dependence on a particular sign pattern order or an incorrect canonicalization convention.
Limits of the recovery statement
The page handles real finite-dimensional data. It does not recover complex phases, solve an arbitrary Fourier imaging problem or apply a sparsity prior. Those extensions change both the ambiguity structure and the algorithms. The word phase in the title refers here to missing real signs, which is a restricted but mathematically meaningful form of phase retrieval.
A unique answer for one supplied vector's data does not mean that the measurement matrix recovers every possible vector uniquely. Nor does it guarantee stability under noise. If measurements are rounded or noisy, exact consistency can fail even near a plausible physical vector. A noise-aware reconstruction needs an explicit loss model and uncertainty analysis rather than an undocumented relaxation of these exact equations.
A few questions, answered
Why are x and minus x counted together?
They always produce identical absolute linear measurements, so global sign is inherently unobservable.
Does full column rank guarantee unique magnitude recovery?
No. It guarantees uniqueness only after signs are known; magnitude data may retain additional ambiguities.
Is a least-squares fit accepted automatically?
No. The original magnitude equations must pass the stated residual check.
Does one unique example prove the matrix works for every vector?
No. Instance uniqueness is different from universal phase-retrieval capability.