We study continuum limits of discrete models for (possibly heterogeneous) nanowires. The lattice energy includes at least nearest and next-tonearest neighbour interactions: the latter have the role of penalising changes of orientation. In the heterogeneous case, we obtain an estimate on the minimal energy spent to match different equilibria. This gives insight into the nucleation of dislocations in epitaxially grown heterostructured nanowires.Introduction. In this paper we study an atomistic model for (possibly heterogeneous) nanowires. We consider a scaling of the energy that corresponds to a reduction of the system from N dimensions to one dimension and, in addition, accounts for transitions between different equilibria.Specifically, in the homogeneous case, we study the asymptotic behaviour of the energy defined bywhere p > 1 and u is a deformation of the portion of the lattice εZ N modelling the nanowire; the small parameter ε > 0 represents the atomic distance and R > 0 is sufficiently large to include a certain number of interactions beyond nearest neighbours. The above sum is taken over a "thin" domain, i.e., a domain consisting of a few lines of atoms (for the precise formula see (1.4)); as the lattice distance converges to zero, we perform a discrete to continuum limit and a dimension reduction simultaneously. This model was first studied in [14,15] under the assumption that the admissible deformations satisfy the non-interpenetration condition, namely, that the Jacobian determinant of a suitably defined piecewise affine interpolation of u is positive. Here we remove such assumption and we show that, by incorporating into the energy the effect of interactions in a certain finite range, one can recover the results of [14,15] and get even further insight into the problem. More precisely, we obtain an effective energy that accounts for the effects of changes of orientation in the lattice. The latter are thus allowed, but energetically penalised. We remark that, in dimension two, our analysis corresponds to the first-order Γ-limit of a functional of the kind studied in [1,18] without non-interpenetration assumptions. We also point out that the effects of long range interactions in non-convex lattice systems have already been analysed in [7,5,6] in the one-dimensional case.For the scaling of (0.1), we obtain a complete description of the Γ-limit with respect to two different topologies (Theorems 5.1 and 5.4). It turns out that the Γ-limit with respect to the topology used in [14,15] is trivial (see Remark 4), that is, one can exhibit recovery sequences for which the gradient always lies in the same energy well up to an asymptotically vanishing correction. In order to see the effects of changes of orientation in the nanowire, we introduce a stronger topology which is sensitive to them. In this case, for each change of orientation, the Γ-limit gives a finite positive contribution which is characterised by a discrete optimal transition problem. Moreover, one can prove that if we prescribe affine boundary conditi...