Suppose we want to position some points in space, given that we know at least some of the distances between them. How can we determine if this is possible? And if it is possible, can we determine the least dimension in which it is possible and algorithmically find a possible (clearly not unique) solution? This is basically the problem of physically constructing a weighted graph, where the edges represent distances between two vertices, and we don't care how far apart are any pairs of vertices not joined by an edge.
Clearly we should check that the given distances satisfy the triangle equality, but for a fixed dimension this itself is not enough. Suppose we know that a subset of three points A, B and C each lie a (Euclidean) distance of one from each other. Then there is no way to position them in one dimension. However, in two-dimensional space they can be physically constructed, as the vertices of an equilateral triangle. So there was no violation of the triangle inequality, which means the one-dimensional issue we hit was some other problem. Similarly if point D must be at unit distance from A, B and C then two dimensions are not enough, but a three-dimensional tetrahedron would resolve the problem. If A, B, C, D, E must all be at unit distance from each other, then even three dimensions are not enough...
An algebraic way to look at the three-point case is that equations $(x_A - x_B)^2 = 1^2$, $(x_B - x_C)^2 = 1^2$, $(x_C - x_A)^2 = 1^2$ are inconsistent. But we can extend to another dimension, $(x_A - x_B)^2 + (y_A - y_B)^2 = 1^2$ etc, to make them consistent (albeit under-determined). So long as there is no violation of the triangle inequality, can we always keep adding extra dimensions until the system of simultaneous quadratic equations becomes consistent? Is there an algorithm to determine whether the equations are consistent? (Bear in mind we will not necessarily know the distance between each pair of points.) Is there instead a more geometric approach we can use?
Related questions: Define positions of a set of points given (only) the distances between them (but unlike my question, all distances are given rather than only only a subset of them), When can we achieve given distances between four points? and When can a weighted graph be embedded in a metric space? (not necessarily Euclidean, and which has nice albeit trivial answer). This interesting question didn't receive an answer, but looks at sets of distances rather than assigning the distances to have to lie between particular vertices: Sets of distances between points that do not form distinct shapes. Closely related question on CS Theory SE: Best way to determine the minimum dimension of a structure given only distances between points (partially answers my question in terms of finding the minimum dimension, but not determining whether it's possible in some dimension- thanks @D.W. for finding this one).