# A Lookahead Behavior Model for Multi-Agent Hybrid Simulation
## 2 Related Works
### State Update Mechanism in Agent-Based Modeling  
The state update mechanism is the first problem to be solved before introducing DES in the agent-based model. In each of the \"sense-think-act\" cycles in the agent model, the agent needs to update its state and complete the synchronization with other agents. Minimizing the number of state updates becomes the key to the efficiency improvement of the hybrid simulation. According to the ways different simulation models change their states, simulation can be divided into synchronous simulation and asynchronous simulation. In synchronous simulation, all state variables of all entities are updated synchronously. Asynchronous simulation allows an entity to individually update its own state at one specific simulation moment regardless of other entities, while in asynchronous simulation, the asynchronous update for attributes can also be applied; that is, at the state update point, the entity only needs to update variables that have state changes, rather than update all of the state variables. With the simulation time mechanism and the state synchronization mechanism combined, the updating of the agent's attributes in the hybrid simulation can be carried out using the following methods [20; 32; 33]:  
(1) Fixed time synchronization (FS): All agents update their respective states at fixed intervals. The smaller the time step, the fewer the interactions missed by the simulation and the more accurate the simulation results. This method is easy to be realized, which is an advantage of fixed time synchronization. However, a drawback is that there may be redundant updates. The small steps used to guarantee the correctness of the simulation results often tremendously increase the number of updates of the agent's state. Even when there is no event, the agent's state change still needs to be checked. Moreover, the fixed time step requires the shortest possible interval that might occur for all interactions. As interactions occurring in the battlefield are random, and there are many entities, the computational burden increased by this fixed-step method is too much to meet the requirement of computation efficiency proposed in analytic simulations. (2) Variable time synchronization (VS): All agents update their states simultaneously, and the update requirements can be proposed by any agent in the simulation. The step size for the agent to update its state is not fixed during the simulation. This method still faces the problem of redundant updates, and has many unnecessary computation processes. (3) Optimistic synchronization (OS): Each agent updates its state separately without considering other agents, and only if it finds that there has been a causal error caused by the interaction with other agents will it use the rollback mechanism to roll the agent back to its state before the interaction occurs. This method can give full play to the agent's parallelism, but when too many causal errors occur, the frequent rollback has a great influence on the system's overall operating efficiency. (5) Complete resynchronization (CR): At each resynchronization moment, all agents update their states. (6) Partial resynchronization (PR): At each resynchronization moment, only the required agents update their states. In these state update mechanisms, FS, VS, and OS are synchronous simulation, and CR and PR belong to asynchronous simulation. All states of all agents in the synchronization simulation need to be updated synchronously. In asynchronous simulation, the agent can update the state variables according to its own state change and conservatively estimate when the interaction will occur, requesting that relevant agents update the states once the interaction occurs; that is, to carry out resynchronization.