ConceptioArchivearXiv CS
arXiv CSopen access

Flexible Distributed Particle Filtering for the Internet of Things via Aggregate Computing

Unknown · 2026 · arxiv_cs
arXiv CS · Papers · License: Open Access · 2026
Open Source ↗Direct PDF ↓
clouddistributedcomputingparallelcomputing
distributed computing, parallel computing, cloud

Flexible Distributed Particle Filtering for the Internet of Things via Aggregate Computing Angela Cortecchia

Davide Domini

Giovanni Ciatto

ORCiD: 0009-0000-3650-7450

ORCiD: 0009-0006-8337-8990

ORCiD: 0000-0002-1841-8996

Roberto Casadei

Danilo Pianini

Mirko Viroli

ORCiD: 0000-0001-9149-949X

ORCiD: 0000-0002-8392-5409

ORCiD: 0000-0003-2702-5702

arXiv:2606.18483v1 [cs.DC] 16 Jun 2026

Department of Computer Science and Engineering (DISI), Alma Mater Studiorum—Università di Bologna Cesena (FC), Italy Abstract—State estimation from uncertain, distributed observations is central in many cyber-physical applications. While Distributed Particle Filtering (DPF) algorithms address nonlinear and non-Gaussian estimations in distributed settings, most solutions remain tied to specific architectures and communication assumptions, limiting adaptability in open, heterogeneous deployments—most notably, the Internet of Things (IoT). In this paper, we propose a field-based formulation of Distributed Particle Filtering grounded in Aggregate Computing (AC). By expressing estimation and information dissemination as computational fields, our approach decouples the core filtering logic from coordination and data-flow strategies. This enables systematic customisation of key design dimensions, including fusion-center placement and resilience, aggregated measurement functions, as well as the type and scope of information propagation. Through a set of in-silico experiments, we show how diverse DPF configurations can be derived within a unified framework, highlighting trade-offs among accuracy, communication cost, and robustness. Overall, the proposed approach positions AC as an effective abstraction layer for engineering adaptable DPF solutions in open IoT environments. Index Terms—Distributed Particle Filtering, Aggregate Computing, Aggregate Programming, Computational Fields, Distributed State Estimation, Internet of Things

I. I NTRODUCTION Estimating the state of a dynamic system from uncertain and partial observations is a foundational problem in a wide range of application domains [1], including target tracking, monitoring, and cyber-physical control. In many realistic scenarios, the system of interest exhibits non-linear dynamics and non-Gaussian uncertainty, making classical linear estimation techniques inadequate. Particle Filters (PF) [2] have emerged as a principled and widely adopted approach to address such settings, providing a Monte Carlo approximation of sequential Bayesian estimation that can flexibly accommodate complex system and measurement models [1]. In Internet of Things (IoT) and large-scale distributed systems, observations are typically collected by multiple spatially distributed entities, each endowed with limited sensing, computation, and communication capabilities. This has motivated extensive research on Distributed Particle Filtering (DPF) [1], where the estimation process is decentralised across a network

of cooperating nodes. Over the years, a rich ecosystem of DPF algorithms has been developed, spanning fusion-center-based approaches, leader-agent schemes, consensus-based methods, and hybrid dissemination strategies. These approaches explore different trade-offs among estimation accuracy, communication cost, robustness, and scalability, and have been successfully applied to a variety of scenarios. Despite many solutions, state-of-the-art DPF approaches achieve flexibility through specialised designs tightly coupled to specific architectural, communication, and modelling assumptions. For instance, the role of fusion centers, the structure of information propagation, the representation of beliefs, and the nature of measurement models are often hardcoded into the algorithmic formulation. As a result, adapting a given DPF solution to changes in sensors, topology, reliability, or mobility often requires non-trivial redesign rather than simple reconfiguration. This limits the suitability of existing DPF approaches for open and heterogeneous IoT systems, where assumptions on deployment density, sensor quality, and connectivity are inherently weak and subject to change. To address these challenges, we turn to Aggregate Computing (AC) [3], a macro-programming [4] paradigm designed to express collective behaviour in distributed systems independently of low-level coordination details. AC promotes a global, aggregate view of computation, where programs describe how information should flow and be transformed across a population of devices, rather than prescribing device-level protocols. This perspective fits IoT scenarios, abstracting over failures, asynchrony, and dynamic topologies while enabling concise resilient behaviours. At the formal core of AC lies the Field Calculus (FC) [5], a functional model for programming (computational) fields [6], i.e., distributed data structures mapping devices or spatial locations to values. FC provides language constructs to evolve fields over time, to exchange information among neighbouring devices, and to restrict computations to dynamically determined regions of the network. Crucially, FC offers equivalent local and global semantics: the same program can be interpreted both as a description of individual device behaviour and as a specification of the resulting collective dynamics.

This duality enables reasoning at the aggregate level while remaining implementable on fully decentralised systems. In this paper, we propose a field-based approach to DPF that integrates AC and FC as a unifying abstraction layer for distributed state estimation. Rather than introducing a new DPF algorithm, our contribution lies in reframing DPF as a family of configurable field computations, where key design dimensions become explicit and composable. These include (i) the placement and resilience of fusion roles, (ii) the definition of measurement functions (possibly aggregated across neighbourhoods), (iii) the form of information exchanged among nodes, and (iv) the spatial and topological scope of dissemination. By expressing these aspects as computational fields, the proposed approach supports systematic adaptation to heterogeneous sensors, uneven spatial observability, node mobility, and failures, without entangling such concerns with the core estimation logic. We validate the proposed framework through a set of in-silico experiments exploring multiple DPF configurations derived from the same field-based specification. These include fusion-center-based schemes realised via leader election for fault tolerance and fully decentralised solutions relying on local particle filters with aggregated measurement functions. Overall, our results show that a field-based formulation enables a flexible and principled design space for DPF, well aligned with the requirements of open IoT environments. The paper is structured as follows. Section II recalls the literature on PF, DPF, and AC, and summarises the most relevant related works. Section III presents our modelling of the DPF problem from an AC, field-based perspective. Section IV discusses the exemplary case of target tracking. Section V describes the experimental setup and discusses the obtained results. Finally, section VI concludes the paper and outlines promising directions for future research. II. BACKGROUND A. The Filtering Problem via Particle Filtering (PF) Sequential state estimation concerns the reconstruction of the latent evolution of a dynamical system from partial and noisy observations. In the context of IoT, the system state typically represents physical, environmental, or logical quantities of interest – such as position, speed, load, occupancy, or anomaly indicators – that evolve over time and are indirectly observed by spatially distributed observer devices. a) Underlying system model: Let xt ∈ Rn denote the system state at discrete time t, and let yt ∈ Rm denote the corresponding observations. The system is commonly modelled as a state-space process xt = f (xt−1 , ut ),

(1)

yt = h(xt , vt ),

(2)

where f (·) and h(·) are the (possibly non-linear) transition and observation models, and ut , vt represent process and measurement noise, respectively. There, the transition model f (·) describes the current system state (xt ) as a function of the previous state (xt−1 ) possibly

subject to process noise (ut ). Similarly, the observation model h(·) describes current observations (yt ) as a function of the current state (xt ) possibly subject to measurement noise (vt ). For example, in a tracking scenario, the state vector may encode position and velocity, xt = [pt , vt ] and the transition model f (·) may describe motion dynamics according to the laws of physics—the simplest case being inertial motion subject to random noise, formally: pt = pt−1 +vt−1 ·∆t+ut , where ∆t is the time elapsed between t − 1 and t. In the same scenario, observations may consist of noisy distance measurements from M different sensors, yt = [d1,t , d2,t , . . . , dM,t ], where di,t is the distance measured by sensor i at time t, and the observation model h(·) may relate these measurements to the underlying state – e.g., through geometric relationships – accounting for sensor noise and biases. b) The filtering problem: Under these assumptions, the filtering problem consists of recursively estimating the posterior probability distribution: p(xt | y1:t ),

(3)

given a prior p(xt−1 | y1:t−1 ) – namely, the probability distribution of the previous system state w.r.t. all past observations – and a new observation yt . In linear-Gaussian settings, the posterior from eq. (3) admits a closed-form solution computed by the Kalman filter [7]. However, many IoT scenarios violate these assumptions due to non-linear dynamics, non-Gaussian noise, multimodal beliefs, or abrupt regime changes. In such cases, Kalmanbased approaches may (i) yield biased estimates, because the linear-Gaussian modelling would not capture the true system behaviour; (ii) diverge because the filter fails to track sudden changes in the state; or (iii) become computationally intractable. These limitations motivate the use of more general Bayesian filtering techniques, such as PF. c) Particle Filtering (PF): PF addresses the general filtering problem by approximating the posterior distribution through a finite set – of fixed cardinality N – of weighted samples called “particles”. Hence, eq. (3) is approximated as: p(xt | y1:t ) ≈

N X

wt,i · δ(xt − xt,i ),

(4)

i=1 N where {xt,i }N i=1 are particles at time t, {wt,i }i=1 are normalised weights, and δ(·) is the Dirac delta function. In practice, such modelling allows computing the Minimum Mean Square Error (MMSE) estimate of the system state as the weighted average of the particles:

x̂t =

N X

wt,i · xt,i .

(5)

i=1

In this way, the whole estimation process reduces to maintaining and updating the set of particles and weights over time, as new observations become available. Each iteration of a PF consists of three conceptual steps: prediction, weighting, and resampling. During prediction, particles are propagated according to a proposal distribution, often

derived from the state transition model. Weights are then updated based on the likelihood of the new observation. Over time, this process tends to concentrate probability mass on a small number of particles, a phenomenon known as particle degeneracy. To mitigate this effect, resampling redistributes particles by replicating those with higher weights and discarding those with negligible contribution. B. Distributed Particle Filtering (DPF) The classical formulation of PF assumes that all observations are centrally available and processed by a single estimator. This assumption is often incompatible with large-scale IoT systems, where sensing, computation, and communication resources are inherently distributed across multiple devices, and where centralized data collection may be infeasible due to bandwidth, latency, energy, or robustness constraints. In DPF, the system state xt remains conceptually global, but observations are taken from K spatially distributed devices, ranged through by k. We denote by yt,k the observation collected at time t by device k. There is no single observation model anymore, but rather a set of local observation models, yt,k = hk (xt , vt,k ), where hk (·) may vary across devices to account for heterogeneous sensing capabilities, or viewpoints. The goal of DPF is to approximate the same posterior as in the centralised case, p(xt | y1:t,1:K ), while relying only on local computations and limited inter-device communication. a) Design space of DPF: Unlike centralised PF, there is no unique way to distribute the filtering process. Existing DPF approaches explore a broad design space, characterised by different choices regarding (i) how particles are represented and maintained across devices; (ii) what information is exchanged between devices, e.g., raw measurements, particle weights, sufficient statistics, or parametric approximations; (iii) how communication is structured, e.g., via neighbourhood exchanges, consensus protocols, or hierarchical aggregation; and (iv) where and how global consistency is enforced. A first major distinction is between approaches that rely on a fusion centre and fully decentralised schemes. Fusion-centrebased solutions delegate the final combination of information to a designated node, which simplifies algorithm design but introduces a single point of failure and scalability bottlenecks. Fully decentralised DPF schemes, instead, aim to avoid any privileged node, typically relying on peer-to-peer communication patterns. Another common distinction concerns the role of particles. Some approaches maintain identical particle sets across devices, requiring synchronisation or consensus mechanisms to ensure consistency of particle weights. Others allow each device to maintain its own local particle population, exchanging information to progressively align local beliefs. These choices impact communication overhead, robustness, and sensitivity to network dynamics. b) Algorithmic challenges: Distributing PF introduces challenges that are absent in the centralized setting. First, communication constraints limit how much information can

be exchanged, forcing approximations that may degrade estimation accuracy. Second, asynchronous execution and timevarying network topologies complicate the coordination of prediction, weighting, and resampling steps. Third, heterogeneity in device capabilities and sensing models requires algorithms to gracefully handle partial, delayed, or unreliable information. As a result, state-of-the-art DPF solutions typically embody flexibility through specialised algorithmic designs, each tied to specific architectural and modelling assumptions. While effective in their target scenarios, such specialisations often limit adaptability to open and heterogeneous IoT systems, where network structure, device roles, and sensing modalities may change over time. c) Towards flexible DPF implementations: From a system-level perspective, DPF can be interpreted as a distributed coordination problem: multiple devices collaboratively maintain and evolve a shared probabilistic representation of system state. Such a perspective naturally raises questions about programming abstractions, coordination mechanisms, and adaptability, beyond the design of individual algorithms. These questions motivate the exploration of higher-level, declarative approaches to distributed estimation, able to express DPF logic independently of specific network structures or communication patterns, as discussed in the following. C. The Field Calculus and Aggregate Computing Aggregate Computing [3] is a macro-programming [4] and coordination paradigm formally grounded in the Field Calculus [8] that supports the design of the collective, selforganising behaviour of large-scale, open, and dynamic networks of devices. Specifically, this is achieved through (i) a flexible execution model supporting “continuous” decentralised coordination, (ii) a functional programming model with field-based abstractions supporting global-level reasoning and modular composition of resilient collective behaviours. These ingredients are detailed next. a) System model and execution assumptions: AC assumes a system composed of many devices, each endowed with local sensing, computation, and communication capabilities. Devices interact by exchanging information with neighbouring devices, according to an application-dependent notion of neighbourhood (e.g., spatial proximity or logical connectivity). Execution proceeds in asynchronous “perceive– compute–act” rounds: each device repeatedly (i) perceives its local context (given by sensor data and messages from neighbours), (ii) computes local outputs, and (iii) acts in its local context, e.g., by running movement actuations and disseminating locally-computed information to the neighbours. No global clock, central coordinator, or reliable synchronisation is assumed. b) Programming model: functions and computational fields: In AC there is a single macro-program run by every device in their compute step. The important aspect about the aggregate macro-programming model is its ability to use neighbourhood communication within classical functions [9]. So, calling a function means such a function is executed by all

the devices, round by round, with local outputs progressively changing also based on neighbour messages (prescribed by the function itself or its inputs). This enables to capture reusable self-organisation patterns as functions, and to use functional composition to build more complex self-organisation logic. The fundamental abstraction underlying AC is that of a computational field, i.e., a distributed data structure mapping each device (also: the spatial locations where devices are situated) to a value. Conceptually, a field is a mapping from n-dimensional space-time Rn × R≥0 to some value domain Y—be it a scalar (e.g., temperature), a vector (e.g., velocity), or a more complex object (e.g., a set of observations). This abstraction admits a dual interpretation: (i) local: each device computes a value as part of its execution; or (ii) global: the set of all values constitutes a field describing the system state as a whole. This duality allows aggregate programs to be written as if manipulating global objects, while being executed purely through local behaviours and interactions. Functions can be then thought of as accepting and returning fields. c) From primitives to building blocks: Field calculi offer a small set of constructs to build field-based computations: (i) observation of neighbouring values, (ii) stateful value transformation (round-by-round), and (iii) branching of computations over subsets of devices based on Boolean conditions. Building on these primitive mechanisms, more complex patterns of distributed coordination can be expressed; in particular, [10] identifies a core set of reusable self-organising building blocks providing: (i) information spreading and outward computation through a distributed gradient (cf [11].); (ii) information collection and inward aggregation through converge-cast; and (iii) distributed leader election [12]. Crucially, these patterns and any compositions thereof are formally proven be self-stabilising [13]. d) Aggregate Computing in practice: Practical usages of AC are supported through domain-specific languages (DSLs), implementing variants of the FC [5], [8], [9], [14] that enable building layered libraries. These DSLs can be found both stand-alone [15] and internal to mainstream embedded in mainstream languages such as Scala [9], C++ [16], and, more recently, Kotlin [17]. In this paper, we adopt such Kotlin-based DSL, called Collektive, as reference AC language, detailing in section III how it can be used to implement DPF. D. Related works Distributed filtering has a long tradition in Wireless Sensor Networks (WSNs) and multi-agent systems, with DPF methods surveyed and taxonomised in [1]. The survey categorises DPF methods into families w.r.t. how information is exchanged and where computation takes place, focusing on: consensus/gossip-based schemes, where local filters are coupled through iterative agreement on sufficient statistics or likelihood1 surrogates [18], [19]; likelihood1 fusion approaches, where the key challenge is to approximate a joint likelihood1 (or its parameters) in a decentralised manner, enabling local particle updates that reflect global information [20];

proposal adaptation and cooperative resampling mechanisms, meant to mitigate weight degeneracy and improve efficiency under communication constraints [21]. Across these families, solutions typically embody flexibility through specialised algorithmic designs, but their implementation is still tightly coupled to specific architectural assumptions (e.g., synchrony, connectivity, roles, message schedules), which limits portability across heterogeneous and open IoT deployments [1]. What is still missing is a unifying programming-model perspective that (i) treats DPF and its components as reusable, composable building blocks and (ii) cleanly separates filtering semantics from spatial coordination mechanisms, so that the same estimator can adapt to changing neighbourhoods, densities, and connectivity. Our work targets this gap by recasting DPF as a field-based computation in AC, enabling flexible orchestration of particle evolution and information fusion through aggregate operators, rather than through architecture-specific protocols. III. F IELD - BASED DPF S As discussed in Section II, existing DPF solutions can be broadly classified into three architectural families: (i) consensus-based approaches; (ii) fusion-center-based schemes; and (iii) leader-agent-based formulations [1]. While these approaches explore different trade-offs between accuracy, communication cost, and robustness, they are typically grounded in strong assumptions on network topology, communication structure, and node roles, which limits their adaptability in open and dynamic IoT deployments. In this section, we show how AC enables a unified modelling of DPF that abstracts over such architectural commitments. By expressing estimation and coordination as fieldbased computations, AC decouples the filtering logic from the underlying network structure, yielding designs that remain valid under dynamic changes in density and topology. A. Architectural Abstraction and Coordination From an architectural standpoint, AC naturally subsumes the main DPF families within a single programming model. Fusion-center-based solutions can be expressed without statically designating a central node, by realising the fusion role as a dynamically elected leader. Unlike classical leader-agent approaches, where leadership may change at every filtering step, AC supports self-stabilising leadership [12], [22], in which the leader persists and is replaced only in response to failures or significant topological changes. This results in fusion-like behaviour combined with fault tolerance, selfhealing, and the absence of single points of failure. More generally, AC enables flexible interpolation between fully decentralised and centrally coordinated DPF schemes, without requiring algorithmic redesign. Architectural choices thus become configuration aspects of the aggregate program rather than intrinsic properties of the filtering algorithm. 1 In the context of Bayesian filtering, the term “likelihood” commonly refers to the probability of the (possibly distributed) measurement vector (yt ) conditioned on the system state (xt ), i.e. p(yt | xt ).

B. Information Exchange as Field Computation AC also provides a principled abstraction for modelling what information is exchanged among nodes during DPF execution. In the literature, information sharing typically involves either (i) particle sets, (ii) parametric approximations of the posterior (e.g., Gaussian or mixture-of-Gaussians statistics), or (iii) global likelihood surrogates [1]. All these strategies can be naturally represented as computational fields, locally produced and selectively propagated or aggregated across the network. Beyond these established approaches, AC enables an additional design option based on the aggregation of raw local measurements. Let each of the K sensors acquire a local observation at time t according to yk,t = hk (xt , vk,t ),

k = 1, . . . , K.

(6)

Using aggregate operators, local measurements can be combined within neighbourhoods or dynamically defined regions N , yielding an aggregated measurement function:  (7) ŷt = HN (k) {hk (xt , vk,t )}k∈N , which can be used directly in the particle weighting step. This form is equivalent to the construction of a distributed sensor, where multiple devices jointly contribute to a single, higher-quality observation. Moving from local to distributed sensing is especially beneficial in scenarios with limited, noisy, or fragile sensors, where aggregating raw measurements can significantly improve the quality of the likelihood estimation. To the best of our knowledge, existing DPF approaches like [23]–[25] mainly focus on sharing particles, beliefs, or likelihood approximations, while the explicit construction of aggregated measurement functions by raw measurement sharing has not been systematically explored. C. Spatially Adaptive Computation & Partitioned Estimation A further advantage of integrating DPF with AC lies in the ability to dynamically adapt the spatial extent of computation based on the estimated relevance of sensing nodes with respect to the system state. In many distributed estimation scenarios, and in particular in target tracking, only a subset of sensors provides informative observations at any given time. Sensors that are far from the object of interest typically produce highly noisy, weak, or even absent measurements, contributing marginally to estimation accuracy while still incurring computational and communication costs. Within AC, this situation can be naturally addressed by embedding the restriction directly into the aggregate program, using domain separation (distributed branching) constructs that dynamically partition the network based on local observability conditions (e.g., proximity or measurement quality with respect to the target). As a result, particle filtering can be selectively activated only on nodes that are sufficiently close to the estimated object location, while the remaining nodes remain computationally inactive or execute a lightweight monitoring role.

This form of spatial gating of computation is particularly easy to express in AC through field-based conditionals, and does not require explicit role assignment or protocol changes. Importantly, as the estimated state of the object evolves over time, the region of active computation smoothly follows it, automatically activating newly relevant sensors and deactivating those that become uninformative. This mechanism may yield improved energy efficiency and scalability, while simultaneously reducing the impact of low-quality measurements on the estimation process. Beyond selective activation, AC also supports the construction of partitioned network architectures through the SelfOrganising Coordination Regions (SCR) pattern [26], whereby the sensor network is dynamically partitioned into spatial coordination regions inducing a Voronoi-like tessellation of devices based on their positions. Within each partition, a representative device (i.e., the leader) is elected to coordinate local estimation activities, aggregate information, or interface with higher-level coordination layers. Such architectures are especially beneficial in settings characterised by severely constrained communication capabilities, or when multiple objects are simultaneously present in the environment. In these scenarios, each partition can focus on estimating the state of the objects located within its spatial domain, while ignoring distant objects whose observations would be weak or irrelevant. Global consistency can then be recovered through limited coordination among partition leaders only, significantly reducing communication overhead. Crucially, these partitions and leadership roles are not statically defined: they emerge from the aggregate program and continuously adapt to changes in node density, topology, or object distribution. Moreover, while partitions may initially be constructed solely based on spatial proximity, AC enables their refinement through additional metrics, such as signal quality, uncertainty, or task-specific relevance. This can be achieved by exploiting the notion of space-fluidity [27]. As a result, partitions may expand, contract, or deform over time, better aligning the computational structure with the evolving estimation needs. All the above mechanisms are realised within AC in a selforganising and self-healing manner. Node failures, mobility, or the disappearance of elected leaders do not require changes to the aggregate specification: the system automatically reconfigures itself, re-electing leaders, reshaping partitions, and re-routing information flows as needed. This further reinforces the suitability of AC as an abstraction layer for engineering robust and adaptive DPF solutions in open IoT environments. IV. E XEMPLARY CASE : TARGET TRACKING In this section, we show a possible application of AC as a technique to implement DPFs, focusing on a common problem in the IoT domain: target tracking through a network of spatially distributed sensors. A. Problem description We consider a target-tracking problem in a bidimensional Euclidean space. We assume such space to be populated

by a set of spatially distributed sensing devices, forming a static sensor network, S = {s1 , . . . , sk } deployed in fixed positions, tracking a single moving target T whose trajectory is unknown. Each sensor si is capable of minimal computation and communication within a limited neighbourhood N (si ). Also, we assume the sensing devices can perceive the target by the radio signal emitted by the moving object. Each sensor si is located at a known position ri = (xi , yi ), while the position of the moving target T is denoted by m = (x, y). The distance between the moving target T and sensor si is defined as di = ∥m − ri ∥. The perceived signal power at sensor si is modeled using a log-distance path-loss model:   di + εi , (8) Pi = P0 − 10n log10 d0 where P0 is the received power at a reference distance d0 , n is the path-loss exponent, and εi ∼ N (0, σp2 ) models measurement noise. Finally, each sensor runs an aggregate program. Execution of devices proceeds in semi-synchronous rounds: each device executes rounds at approximately the same rate, but with bounded drift between any two subsequent rounds. This matches the standard execution model assumed by AC and FC. This is also why we index time with discrete steps t ∈ N, despite the underlying system evolves in continuous time. Also, notice that the notion of round here refers to the local computation cycle of each device, so the same round index t may correspond to slightly different real times across devices. B. Aggregate Measurement Functions As discussed in Section Section III-B, a key advantage of leveraging AC for DPF lies in the ability to construct aggregate measurement functions from local observations shared among neighbouring devices. Rather than treating each sensor as an isolated information source, AC enables the sensing infrastructure to be interpreted as a computational field of measurements, where local perceptions are continuously combined through neighbourhood interactions. In the considered target-tracking scenario, each sensor si acquires at time t a local measure yit of the position of the target T . Through neighbourhood communication, each sensor gains access to the observations collected by its neighbours, and can locally compute an aggregate measurement function that refines the estimation of the target position. Notice that as the number of neighbouring sensors increases, the aggregate estimate becomes more accurate due to the availability of a richer set of local observations. Such aggregation can take simple forms, such as weighted averages of neighbouring measurements, or more sophisticated functions that account for measurement quality, for instance by weighting observations according to the estimated distance from the target or the expected noise level. In this work, we consider an indirect form of measurement aggregation, where observations from neighbouring sensors are treated as conditionally independent and combined by multiplying their local likelihoods.

Importantly, each sensor maintains its own local particle filter and its own set of particles. Aggregation operates solely at the level of measurements, without requiring the exchange of particles among neighbours. This design choice significantly reduces communication overhead, which would otherwise be dominated by the transmission of particle sets, while still allowing each local filter to incorporate richer and more informative observations through neighbourhood-level aggregation. C. Fusion Center as an elected leader As discussed in Section III-A, a second advantage of adopting AC for DPF is the ability to realise fusion-centerbased architectures through dynamic leader election. Rather than selecting a fusion center a priori, AC allows the fusion role to be assigned at runtime based on a chosen metric, such as network centrality or other application-specific criteria. This approach provides two main benefits. First, the fusion center is not statically bound to a specific device, but can adapt to changes in network topology or deployment conditions. Second, in the presence of node failures, the system automatically elects a new leader in a self-healing and self-organising manner, without requiring external intervention, allowing the tracking process to continue over time. In this setting, the system still exposes a computational field of local measurements yit , which are progressively aggregated toward the elected leader through a converge-cast operator. The leader node thus acts as a fusion center, collecting measurements from the network and executing a particle filter based on the received information. Notice that measurements from sensors at different hop distances reach the fusion center with different delays: data from neighbours arrive immediately, while information from farther nodes experiences multi-hop propagation delays. Consequently, updates at the fusion center are temporally staggered and reflect the underlying network topology. V. E XPERIMENTAL E VALUATION A. Experimental Setup To validate the approach described in the previous sections, we conducted a simulation-based evaluation. All the experiments are publicly available on GitHub2 under a permissive license for reproducibility. Simulations were developed using the Alchemist simulator [28], which provides an environment for simulating distributed, dynamic systems and AC programs. The program logic for the sensors’ behaviour and program evaluation was implemented in Kotlin, leveraging the Collektive framework for AC constructs [17]. We designed two main experiments to validate the approaches described in Section IV: (i) an experiment focusing on evaluating an aggregated measurement function through local measurement sharing among neighbouring sensors; (ii) an experiment focusing on evaluating the leader-based fusion centre approach for reconstructing the target trajectory, even under dynamic leader changes. 2 https://github.com/domm99/experiments-ac-based-distributed-particlefiltering

Y (m)

100

Estimated

|N| = 1

100

Start

End

|N| = 4

100

80

80

80

80

60

60

60

60

40

40

40

40

20

20

20

20

0

0 0

20

40

X (m)

60

80

100

0 0

20

40

X (m)

60

80

100

3000

|N| = 7

100

Time Steps

Real Trajectory

|N| = 0

0 0

20

40

X (m)

60

80

100

0

20

40

X (m)

60

80

100

0

Fig. 1: Estimated trajectories for different numbers of sensors. With few neighbors (0-1), the filters fail to converge due to limited information; increasing the neighbors count allows exploiting aggregated measurements, improving the estimation and enabling convergence toward the real trajectory.

102

RMSE

|N|

101

0 1 4 7

100 0

500

1000

1500

2000

2500

Time Step

3000

Fig. 2: Average RMSE over 100 random seeds, with shaded areas indicating variance.

Real Trajectory FC Failure

Estimated Start

End 3000

100 80

Time Steps

Y (m)

60 40 20 0 0

20

40

X (m)

60

80

100

0

Fig. 3: Trajectories estimated via the leader-based fusion center approach. The plot shows the estimated trajectory before and after the leader failure at time step 1500. A brief transient phase is observed initially and around the disconnection event, which corresponds to the leader election process.

The experiments consist of a network of 25 sensors deployed on a two-dimensional spatial grid, with slight random perturbations of the nominal grid positions. In the environment, there is a single moving object following a predefined non-linear trajectory γ:   vt + 5 sin(0.3 vt) . (9) γ : R → R2 , γ(t) = vt, 2 where v = 0.05m/s is a constant speed. The moving object emits signals that can be perceived by the sensors: the further the object is from a sensor, the weaker the perceived signal, and the noisier the measurement becomes. The sensors and object states are defined by their planar position (x, y), and the moving object state is defined by its velocity components along the two axes. Sensors do not move, and run computations at a fixed 1Hz rate, with no syncronisation between them. The neighbourhood size |N | is a free variable of the experiment. Each configuration executes for 3000 simulated seconds. Every experiment was repeated 100 times with different random seeds to account for the stochasticity. The goal of the sensors is to cooperatively track the moving object by estimating its position over time via DPF. B. Discussion Figure 1 shows the estimated trajectories for the first experiment, in which each sensor runs its own particle filter while constructing an aggregated measurement function by sharing local measurements with its neighbours. The figure reports the performance obtained for different neighbourhood sizes (|N |). When no neighbours are available, the filters fail to converge due to the limited amount of information. As neighbouring sensors increase, aggregated measurements improve accuracy and convergence. A single neighbour is sufficient to improve the estimation significantly over time. With |N | = 4, a brief initial instability is observed, followed by rapid convergence. With |N | = 7 neighbours, the estimation is both accurate and stable over time, highlighting the benefits of aggregating information from multiple sensors. The same trend is observed

in Figure 2, which reports the average Root Mean Square Error (RMSE) over time. With few neighbours, the estimation error remains high and does not decrease, whereas exploiting information from a larger neighbourhood significantly reduces the error and improves long-term stability. Figure 3 shows the estimated trajectories for the second experiment, where a leader-based fusion center is used to reconstruct the target trajectory. The chart shows the estimated trajectory before and after the leader failure at time step 1500. We observe a brief transient phase associated with leader election at the beginning of the simulation, when tracking starts, and a second transient triggered by the failure of the current leader and the subsequent election of a new one. Once the new leader is elected, after a brief transient period, it is able to take over the fusion center role and continue tracking the moving object. This shows the resilience of the leader-based fusion center approach, as it can adapt to dynamic changes in leadership and maintain accurate tracking performance. VI. C ONCLUSION AND F UTURE W ORK In this paper, we propose a field-based formulation of DPF grounded in AC, decoupling the estimation logic from architectural and coordination concerns. By expressing sensing, data sharing, and fusion mechanisms as computational fields, our approach enables the systematic derivation of different DPF configurations within a unified programming model. The experimental evaluation on a target-tracking scenario shows that both neighbourhood-level aggregated measurement functions and leader-based fusion centres can be effectively realised in AC, yielding improved estimation accuracy and robustness while preserving decentralised coordination. Future work will focus on experimentally exploring more design dimensions discussed in Section III but not evaluated in this paper. In particular, we plan to investigate spatially adaptive computation strategies, including dynamic restriction of filtering activities to relevant regions of the network and partitioned estimation through self-organising coordination regions. Finally, extending the evaluation to multiple targets and heterogeneous sensing modalities is a natural next step to further assess the flexibility of the proposed framework. ACKNOWLEDGMENTS This work contributes to the research agenda of the Italian Science Fund (FIS3) Starting Grant project FoMaSE – Foundations for Macro-programming-based Software Engineering (Grant No. FIS-2024-00174, CUP J53C25002170001). R EFERENCES [1] O. Hlinka, F. Hlawatsch, and P. M. Djuric, “Distributed particle filtering in agent networks: A survey, classification, and comparison,” IEEE Signal Process. Mag., vol. 30, no. 1, pp. 61–81, 2013. [2] M. S. Arulampalam, S. Maskell, N. J. Gordon, and T. Clapp, “A tutorial on particle filters for online nonlinear/non-gaussian bayesian tracking,” IEEE Trans. Signal Process., vol. 50, no. 2, pp. 174–188, 2002. [3] J. Beal, D. Pianini, and M. Viroli, “Aggregate programming for the internet of things,” Computer, vol. 48, no. 9, pp. 22–30, 2015. [4] R. Casadei, “Macroprogramming: Concepts, state of the art, and opportunities of macroscopic behaviour modelling,” ACM Comput. Surv., vol. 55, no. 13s, pp. 275:1–275:37, 2023.

[5] G. Audrito, M. Viroli, F. Damiani, D. Pianini, and J. Beal, “A higherorder calculus of computational fields,” ACM Trans. Comput. Log., vol. 20, no. 1, pp. 5:1–5:55, 2019. [6] M. Mamei, F. Zambonelli, and L. Leonardi, “Co-fields: A physically inspired approach to motion coordination,” IEEE Pervasive Comput., vol. 3, no. 2, pp. 52–61, 2004. [7] R. E. Kalman, “A new approach to linear filtering and prediction problems,” J. Basic Eng., vol. 82, no. 1, p. 35–45, 1960. [8] M. Viroli, J. Beal, F. Damiani, G. Audrito, R. Casadei, and D. Pianini, “From distributed coordination to field calculus and aggregate computing,” J. Log. Algebraic Methods Program., vol. 109, 2019. [9] G. Audrito, R. Casadei, F. Damiani, and M. Viroli, “Computation against a neighbour: Addressing large-scale distribution and adaptivity with functional programming and scala,” Log. Methods Comput. Sci., vol. 19, no. 1, 2023. [10] M. Viroli, G. Audrito, J. Beal, F. Damiani, and D. Pianini, “Engineering resilient collective adaptive systems by self-stabilisation,” ACM Trans. Model. Comput. Simul., vol. 28, no. 2, pp. 16:1–16:28, 2018. [11] T. D. Wolf and T. Holvoet, “Designing self-organising emergent systems based on information flows and feedback-loops,” in 1st International Conference on Self-Adaptive and Self-Organizing Systems, SASO. IEEE Computer Society, 2007, pp. 295–298. [12] D. Pianini, R. Casadei, and M. Viroli, “Self-stabilising priority-based multi-leader election and network partitioning,” in IEEE International Conference on Autonomic Computing and Self-Organizing Systems, ACSOS’22. IEEE, 2022, pp. 81–90. [13] E. W. Dijkstra, “Self-stabilizing systems in spite of distributed control,” Commun. ACM, vol. 17, no. 11, pp. 643–644, 1974. [14] G. Audrito, R. Casadei, F. Damiani, G. Salvaneschi, and M. Viroli, “The exchange calculus (XC): A functional programming language design for distributed collective systems,” J. Syst. Softw., vol. 210, p. 111976, 2024. [15] D. Pianini, M. Viroli, and J. Beal, “Protelis: practical aggregate programming,” in Proceedings of the 30th Annual ACM Symposium on Applied Computing. ACM, 2015, pp. 1846–1853. [16] G. Audrito and G. Torta, “FCPP to aggregate them all,” Sci. Comput. Program., vol. 231, p. 103026, 2024. [17] A. Cortecchia, “Multiplatform self-organizing systems through a KotlinMP implementation of aggregate computing,” in IEEE International Conference on Autonomic Computing and Self-Organizing Systems, ACSOS’2024 - Companion. IEEE, 2024, pp. 155–157. [18] R. Olfati-Saber, “Distributed Kalman filter with embedded consensus filters,” in 44th IEEE Conference on Decision and Control & 8th European Control Conference Control. IEEE, 2005, pp. 8179–8184. [19] F. S. Cattivelli and A. H. Sayed, “Diffusion strategies for distributed kalman filtering and smoothing,” IEEE Trans. Autom. Control., vol. 55, no. 9, pp. 2069–2084, 2010. [20] O. Hlinka, O. Sluciak, F. Hlawatsch, P. M. Djuric, and M. Rupp, “Likelihood consensus and its application to distributed particle filtering,” IEEE Trans. Signal Process., vol. 60, no. 8, pp. 4334–4349, 2012. [21] O. Hlinka, F. Hlawatsch, and P. M. Djuric, “Consensus-based distributed particle filtering with distributed proposal adaptation,” IEEE Trans. Signal Process., vol. 62, no. 12, pp. 3029–3041, 2014. [22] Y. Mo, G. Audrito, S. Dasgupta, and J. Beal, “Near-optimal knowledgefree resilient leader election,” Autom., vol. 146, p. 110583, 2022. [23] M. Rosencrantz, G. J. Gordon, and S. Thrun, “Decentralized sensor fusion with distributed particle filters,” in 19th Conference in Uncertainty in Artificial Intelligence. Morgan Kaufmann, 2003, pp. 493–500. [24] M. Coates, “Distributed particle filters for sensor networks,” in 3rd International Symposium on Information Processing in Sensor Networks, IPSN’04, Proceedings. ACM, 2004, pp. 99–107. [25] C. G. de Figueredo, C. J. B. Jr., and M. G. S. Bruno, “Cooperative parameter estimation on the unit sphere using a network of diffusion particle filters,” IEEE Signal Process. Lett., vol. 27, pp. 715–719, 2020. [26] D. Pianini, R. Casadei, M. Viroli, and A. Natali, “Partitioned integration and coordination via the self-organising coordination regions pattern,” Future Gener. Comput. Syst., vol. 114, pp. 44–68, 2021. [27] R. Casadei, S. Mariani, D. Pianini, M. Viroli, and F. Zambonelli, “Spacefluid adaptive sampling by self-organisation,” Log. Methods Comput. Sci., vol. 19, no. 4, 2023. [28] D. Pianini, S. Montagna, and M. Viroli, “Chemical-oriented simulation of computational systems with alchemist,” Journal of Simulation, vol. 7, no. 3, pp. 202–215, Aug. 2013.

Record · ID 287104 · SHA-256 a8d6097d67ab778c
Retrieved via Conceptio — every document is proof-bundled with source, license, and retrieval metadata.