---
title: SCAPSO Algorithm for WSN Localization
url: https://www.emergentmind.com/topics/scapso-algorithm
type: topic
---

# SCAPSO Algorithm for WSN Localization

Searching arXiv for the specified paper to ground the article in the source.
SCAPSO, as defined in "AdapSCA-PSO: An Adaptive Localization Algorithm with AI-Based Hybrid SCA-PSO for IoT WSNs" [2507.22317], is a hybrid wireless sensor network localization algorithm that combines the Sine Cosine Algorithm (SCA) with Particle Swarm Optimization (PSO). In that formulation, SCA is used for global exploration and PSO for local exploitation, with the hybrid intended to broaden early search while refining promising regions later. The same paper uses an "unoptimized SCAPSO algorithm" as a baseline and proposes an adaptive variant, AdapSCA-PSO, that redesigns initialization, fitness evaluation, parameter settings, and the switching logic between SCA and PSO.

## 1. Definition and algorithmic role

In the paper, SCAPSO is not presented as a weighted fusion of SCA and PSO, nor as a simultaneous mixed update in which both operators are applied in one step. It is instead framed as a switching hybrid in which a selector chooses either an SCA update or a PSO update during optimization [2507.22317]. The intended division of labor is explicit: SCA is “effective in global search,” whereas PSO “excels at local search.”

This positioning matters because the paper’s SCAPSO is not merely a generic label for any SCA-PSO combination. The hybrid is motivated by the standard exploration–exploitation decomposition of meta-heuristics. SCA is used early to explore the search space broadly and to avoid poor local minima; PSO is used later to exploit candidate regions and improve final localization accuracy. In this sense, SCAPSO is a two-operator localization optimizer whose conceptual structure depends on temporal differentiation between broad search and local refinement.

A central interpretive issue is that the paper repeatedly compares against an “unoptimized SCAPSO algorithm” but does not fully specify that baseline in formal algorithmic detail. The most reasonable reading is that the baseline is a non-adaptive SCA-PSO hybrid lacking the paper’s redesigned initialization, direct ranging-based fitness, and adaptive switching schedule. The paper does not provide exact pseudocode or equations for the baseline SCAPSO, so any stronger characterization is inferential rather than directly stated.

## 2. Localization problem setting

The algorithm is developed for localization in wireless sensor networks for Internet of Things applications, especially industrial IoT, in a two-dimensional deployment space [2507.22317]. The node set is partitioned into anchor nodes, whose coordinates are known, and unknown nodes, whose coordinates must be estimated.

The paper assumes a localization model with the following inputs: anchor coordinates, hop counts from unknown nodes to anchors, one-hop neighborhood information, measured distances \(d_{jk}\) between neighboring nodes, and communication range \(L\). The output is the estimated 2D coordinates of all unknown nodes. The search space is explicitly two-dimensional, \(x \in \mathbb{R}^2\).

Each particle encodes a candidate coordinate for an unknown node in 2D, written as \(X_j = (x_j, y_j)\). The discussion of “the unknown node’s particle” suggests per-node localization optimization rather than a jointly encoded high-dimensional representation for all unknown nodes. The paper assumes one-hop communication neighborhoods, nearest-anchor information via hop count, and the availability of inter-node distance measurements for neighbors, but it does not state a detailed RSSI or ToA noise model or an explicit ranging error distribution.

These modeling choices locate SCAPSO within a class of geometry- and topology-aware WSN localization methods. A plausible implication is that the algorithm’s behavior is shaped as much by neighborhood structure and anchor placement as by the intrinsic dynamics of the hybrid meta-heuristic.

## 3. Hybrid dynamics: SCA, PSO, and adaptive switching

The PSO component is given by the standard velocity and position updates [2507.22317]:
\[
v_i(t+1)=w\,v_i(t)+c_1\,\mathrm{rand}\,\bigl(p_i-x_i(t)\bigr)+c_2\,\mathrm{rand}\,\bigl(g-x_i(t)\bigr)
\]
\[
x_i(t+1)=x_i(t)+v_i(t+1)
\]
where \(x_i(t)\) is the particle position, \(v_i(t)\) its velocity, \(p_i\) its personal best, \(g\) the global best, and \(c_1,c_2,w\) are the usual PSO parameters. The inertia weight is updated linearly from \(w_{\max}\) to \(w_{\min}\).

The SCA component updates position according to
\[
x_i(t+1)=
\begin{cases}
x_i(t) + r_1 \sin(r_2)\, \lvert r_3 g - x_i(t)\rvert, & r_4 < 0.5 \\
x_i(t) + r_1 \cos(r_2)\, \lvert r_3 g - x_i(t)\rvert, & r_4 \ge 0.5
\end{cases}
\]
with amplitude decay
\[
r_1(t)=a\left(1-\frac{t}{T}\right).
\]
The paper explains that \(r_1\) decreases over time to encourage convergence, \(r_2\) controls oscillation, \(r_3\) modifies directional pull, and \(r_4\) switches between sine and cosine.

The adaptive variant replaces a non-adaptive or less specialized hybrid schedule with an explicit switching rule:
\[
x_i(t+1)=
\begin{cases}
\mathrm{SCA}(x_i(t)), & \text{if } s < e^{-\beta t/T} \\
\mathrm{PSO}(x_i(t)), & \text{otherwise}
\end{cases}
\]
where \(s \sim U(0,1)\), \(\beta\) controls the transition rate, \(t\) is the current iteration, and \(T\) is the maximum number of iterations. The implied switching probability for SCA is approximately
\[
P(\text{choose SCA at iteration } t)=e^{-\beta t/T}.
\]

This means that SCA is selected almost always at the beginning of optimization and then decays exponentially in favor of PSO. The criterion is iteration-progress based rather than fitness-improvement based. The paper explicitly notes that there is no reinforcement learning, classifier, or neural policy; the “AI-based” terminology refers to adaptive meta-heuristic control rather than a learned model.

## 4. Initialization, fitness design, and workflow

The paper attributes much of the performance difference between the baseline SCAPSO and AdapSCA-PSO to WSN-specific redesigns in initialization and fitness evaluation [2507.22317]. Instead of standard random initialization, the method exploits network topology. For each unknown node, it finds the anchor node with the fewest hops, constrains the initial particle position to lie within one-hop radius of that nearest anchor, and scales the initial velocity according to hop count.

The corresponding formulas are
\[
v_i(0) = \delta \cdot h_i(2r-1), \qquad r \sim U(0,1)
\]
and
\[
x_i(0) \in \{x \in \mathbb{R}^2 \mid \|x-a_z\|\le L\},
\]
where \(h_i\) is the hop count from unknown node \(i\) to its nearest anchor, \(a_z\) is the coordinate of that anchor, \(L\) is the one-hop communication range, and \(\delta\) is an adjustable base velocity coefficient. The paper interprets this as sampling initial positions within a disk of radius \(L\) around the nearest anchor, while allowing initial velocity magnitude to grow with hop count.

Fitness evaluation is defined by a localization-specific cost:
\[
f(X_j)=\sum_{k \in N_j} W_k \left(d_{jk} - \|X_j - X_k\|\right)^2,
\]
where \(N_j\) is the set of one-hop neighbors of node \(j\), \(d_{jk}\) is the measured distance between nodes \(j\) and \(k\), and \(W_k\) depends on node type: \(W_k=0.8\) if node \(k\) is an anchor and \(W_k=0.2\) if node \(k\) is an unknown node. The optimizer thus minimizes the squared mismatch between measured inter-node distances and distances induced by candidate coordinates.

The workflow described in the paper is: initialize candidate coordinates, velocity, and fitness; choose SCA or PSO adaptively at each iteration; update the particle accordingly; evaluate fitness; update personal best and global best; stop at the maximum number of iterations; and return the estimated coordinates. This structure makes clear that the proposed method is not simply a hybrid update rule, but a localization pipeline specialized to WSN topology and ranging information.

## 5. Experimental evaluation and reported performance

The simulation study uses a \(100 \times 100\ \text{m}^2\) deployment area with two node counts, 100 and 200; communication distance \(L=30\) m for 100 nodes and \(L=15\) m for 200 nodes; anchor ratios of 10% and 20%; four scenarios in total; and 50 simulations per scenario [2507.22317]. The baselines are DV-Hop, standard PSO, unoptimized SCAPSO, and the proposed AdapSCA-PSO.

| Scenario | SCAPSO | AdapSCA-PSO |
|---|---:|---:|
| 100 nodes, 30 m, 10% anchors | 8.6088 m | 0.6722 m |
| 100 nodes, 30 m, 20% anchors | 6.4436 m | 0.4778 m |
| 200 nodes, 15 m, 10% anchors | 5.7791 m | 1.4689 m |
| 200 nodes, 15 m, 20% anchors | 4.5987 m | 0.9194 m |

Across the four scenarios, the paper reports that AdapSCA-PSO reduces average localization error by 89.77% relative to DV-Hop, 84.97% relative to PSO, and 84.84% relative to SCAPSO. The paper also states that the proposed method significantly reduces the number of required iterations and that Figure 4 shows faster convergence, but no exact iteration counts or percentage reduction values are numerically reported in the provided text.

The interpretation offered in the paper is that AdapSCA-PSO begins with lower initial fitness because of informed initialization; that SCA reduces fitness faster in the early stage; and that adaptive switching plus optimized parameters yields faster convergence and the lowest final fitness. Within the reported experiments, this places the adaptive variant as the strongest of the compared methods in both convergence profile and final localization error.

## 6. Parameterization, limitations, and reproducibility

The paper provides the following parameter values for the proposed method: \(w_{\max}=0.9\), \(w_{\min}=0.4\), \(c_1=2.2\), \(c_2=1.8\), \(a=2.5\), and \(\delta=0.5\), with \(L=15\) or \(30\) depending on scenario [2507.22317]. At the same time, several values are not recoverable from the reproduced text: the numerical value of \(\beta\), the exact maximum number of iterations \(T\), and the particle count \(i_{\max}\). The stopping criterion stated in the paper is the maximum number of iterations \(T\), and no additional stopping condition is mentioned.

The paper does not provide formal computational complexity. It also does not provide a complete formal definition of the baseline SCAPSO, including whether that baseline uses fixed-stage SCA then PSO, fixed-probability switching, or another hybridization scheme. This is the principal reproducibility issue surrounding SCAPSO as presented in the paper. Any implementation of the baseline from this source alone requires assumptions.

Several additional limitations are explicitly visible from the text. The evaluation appears to be simulation-only rather than based on physical deployment. The paper does not provide a detailed ranging noise or error model. It also notes that for dense networks with shorter communication range, AdapSCA-PSO may suffer a slight rise in error due to fewer effective one-hop neighbors. These points do not invalidate the reported results, but they delimit the extent to which the method can be reconstructed or generalized from the paper alone.

A common misconception would be to interpret the method’s “AI-based” characterization as implying a learned policy or neural decision module. The paper does not support that reading. Another possible misconception would be to treat SCAPSO in this source as a fully specified canonical algorithm. The text supports a narrower conclusion: SCAPSO is a hybrid SCA-PSO baseline whose motivating principle is clear, but whose exact baseline instantiation is only partially documented, whereas AdapSCA-PSO is specified in substantially greater detail.

Source: https://www.emergentmind.com/topics/scapso-algorithm