# \(k\)-Circle Formation and \(k\)-epf by Asynchronous Robots
## 4 Algorithm
### Agreement One Axis  
Since the robots have an agreement on the direction and orientation of the \(y\)-axis, they also have an agreement on the orientation of the \(x\)-axis without direction. This is the algorithm by which the robots identify the configurations in which they could have an agreement on the direction of the \(x\)-axis. The robots make an agreement on the direction of the \(x\)-axis in such configurations. Each robot in its look phase identifies the class in which \(C(t)\) belongs to and considers the following cases:  
1. \(C(t)\in\mathcal{I}_{1}\), i.e., \(F\) is asymmetric about the \(y\)-axis. Let \(hline_{1},\ldots,hline_{s}\) denote all the horizontal lines, each one of which passes through at least one fixed point, listed according to their increasing \(y\)-coordinates. Since the fixed points are asymmetric about the \(y\)-axis, at least one of these lines must contain asymmetric fixed points. Let \(hline_{y}\) be the topmost among such horizontal lines which contains an asymmetric fixed point. Consider the fixed point closest to the \(y\)-axis and not having a symmetric image on \(hline_{y}\). The direction from the \(y\)-axis towards the half-plane containing this fixed point is considered as the positive \(x\)-direction. All the robots agree upon this agreement. 2. \(C(t)\in\mathcal{I}_{2}\), i.e., \(F\) is symmetric about the \(y\)-axis, but \(R(t)\) is asymmetric about the \(y\)-axis. The robots consider the following cases: 1. The configuration is unbalanced. The direction from the \(y\)-axis, towards the half-plane containing the maximum number of robots, is considered as the positive \(x\)-direction. All the robots agree upon this agreement. The configuration is balanced and all the fixed points in one of the half-planes are either saturated or oversaturated. In this case the robots consider the positive \(x\)-direction towards the half-plane in which all the fixed points are either saturated or oversaturated. 3. The configuration is balanced with at least one unsaturated fixed point in both the half-planes and \(R_{y}(t)\
eq\emptyset\). The robots do not make an agreement on the direction of positive \(x\)-axis. The robots decide to transform the configuration into an unbalanced configuration. Let \(r\) be the topmost robot on the \(y\)-axis. Define \(\lambda=\max\limits_{f\in F,\ r_{i}\in R(t)\setminus\{r\}}d(r_{i}(t),f)\). Suppose \(p\) denotes the point on the \(y\)-axis, which is at \(2\lambda\) distance above from topmost horizontal line \(hline_{s}\). If the position of \(r\) is below \(p\), then it moves towards \(p\) along the \(y\)-axis. Otherwise, \(r\) is moved to one of the half-planes to a point at \(\dfrac{1}{3}\rho\) from the \(y\)-axis. This upward movement is required to avoid any collision, which might arise due to the inherent motion of \(r\) in a half-plane for some \(t^{\prime}\geq t\). 4. The configuration is balanced with at least one unsaturated fixed point in both the half-planes and \(R_{y}(t)=\emptyset\). The robots consider the following cases: 1. \(k\) is odd and \(F_{y}\
eq\emptyset\). Note that in this case, the configuration has an even number of fixed points. The direction from the \(y\)-axis towards the half-plane in which there has been more progress is considered as the positive \(x\)-axis direction. It is possible that initially there has been the same progress in both the half-planes. Since \(C(0)\) is asymmetric, there must be one asymmetric robot position about the \(y\)-axis. The positive \(x\)-direction is considered towards the half-plane that contains the asymmetric robot position, which has the highest configuration rank. All the robots agree upon this agreement. 2. Otherwise, the robots do not agree upon the direction of positive \(x\)-axis direction. This case includes the configurations in which (i) \(k\) is even and \(F_{y}\
eq\emptyset\), (ii) \(k\) is even and \(F_{y}=\emptyset\), and (iii) \(k\) is odd and \(F_{y}=\emptyset\). Notice that a configuration in this case might become symmetric with \(R_{y}(t)=\emptyset\).