I have a DAG which loosely represents a reticulated genealogy (family "tree") of potentially millions of nodes, with fixed 2D spatial positions of some of the nodes (mostly leaf or "sink" nodes, as it happens). I want to find possible spatial positions for all the other nodes, such that the edge lengths are minimised according to some function (I could use least squares, but ideally I would be able to define my own likelihood function for edge lengths, especially one which allows each edge to have a different "weight"). I don't care about vertices crossing each other.
Is this a graph theory/layout problem, or something more like an energy minimization problem in computational chemistry? What existing algorithms and implementations exist to solve these sort of layout problems?