A method comprising: determining, by a base station in a wireless network, interference for a plurality of pairs of cells, wherein each pair of cells is between an individual one of one or more serving cells formed by the base station and an individual one of other cells that surround the one or more serving cells; and allocating,; by the base station, values for physical cell identifications for the one or more serving cells based on the interference for the plurality of pairs of cells, characterized by allocating values for physical cell identifications for the one or more serving cells further comprises solving the following problem: Trace G z PCI T Γ neighbourhood + Z G z PCI = 0 where Trace () is a trace operation, Γ neighbourhood is a matrix of interference consisting of Γ target ( t), which is a first matrix for only the first plurality of pairs of cells, when only the first plurality of pairs of cells is used, and comprising Γ target ( t) and a plurality of Γ partial ( t), each of which is a second matrix, when both the first matrix and the second matrices are used, Z i, j = { 1 cell i and j are neighbours or neighbour-of-neighbours 0 otherwise, G z PCI is a grouping matrix whose element at row i column j is given by G z, i, j PCI = { 1 j = p z, i + 1 0 otherwise, where p z represent a z 'th candidate solution for the physical cell identifications, and the values for the physical cell identifications for the one or more serving cells are p opt, which is determined by the G z PCI that makes the equation in the problem true, wherein the determining the interference for the plurality of pairs of cells determines a first matrix; and wherein each second pair of cells is between an individual one of the neighbour cells and an individual one of other cells that surround the individual one of the neighbour cells. determining, by a base station in a wireless network, interference for a plurality of pairs of cells, wherein each pair of cells is between an individual one of one or more serving cells formed by the base station and an individual one of other cells that surround the one or more serving cells; and allocating,; by the base station, values for physical cell identifications for the one or more serving cells based on the interference for the plurality of pairs of cells, characterized by allocating values for physical cell identifications for the one or more serving cells further comprises solving the following problem: Trace G z PCI T Γ neighbourhood + Z G z PCI = 0 where Trace () is a trace operation, Γ neighbourhood is a matrix of interference consisting of Γ target ( t), which is a first matrix for only the first plurality of pairs of cells, when only the first plurality of pairs of cells is used, and comprising Γ target ( t) and a plurality of Γ partial ( t), each of which is a second matrix, when both the first matrix and the second matrices are used, Z i, j = { 1 cell i and j are neighbours or neighbour-of-neighbours 0 otherwise, G z PCI is a grouping matrix whose element at row i column j is given by G z, i, j PCI = { 1 j = p z, i + 1 0 otherwise, where p z represent a z 'th candidate solution for the physical cell identifications, and the values for the physical cell identifications for the one or more serving cells are p opt, which is determined by the G z PCI that makes the equation in the problem true, wherein the determining the interference for the plurality of pairs of cells determines a first matrix; and wherein each second pair of cells is between an individual one of the neighbour cells and an individual one of other cells that surround the individual one of the neighbour cells.