HLA/RTI and Relative Key Implementation Technologies

In this article, the main research content of the system structure of the new generation distributed interactive simulation HLA is introduced, the function and system structure of the run-time infrastructure (RTI) are described, and the implementation method of the data distribution management (DDM) and the time management are researched profoundly.


Introduction
With the quick development of the computer technology and the simulation technology, the application of the simulation technology is more and more extensive, and especially, the distributed interactive simulation technology has been the mainstream of the modern simulation technology.From generating the plan of SIMNET, to the protocol of DIS2.xIEEE1278 and to the establishment of ALSP protocol, and to the current DIS++/HLA system structure, the distributed interactive simulation technology is all to enhance the interoperability among simulation applications and the reusability of simulation parts.In Aug of 1996, United States Department of Defense officially enacted the general technological frame aiming at the domain of modeling and simulation.This frame is composed by three parts including the conceptual model of mission space (CMMS), HLA and a series of data standards, and is thought as the next generation distributed interactive simulation standard.HLA is the start and base to establish the modeling and simulation general technical frame, and the necessary base to realize the interoperation and reuse among different types of simulation and between these simulations and C4I system.

Main research content of HLA
The basic thought of HLA is to use the object-oriented method to design, develop, and realize the object model of the system, and obtain the interoperation and reuse of the simulation federations on the higher layer.The standard of HLA is composed by three parts including the rule, the object model template (OMT) and the interface criterion.The simulation applications and software which centralize together to realize the special simulation object in HLA are called as the federation, and its members are called as federate.
The rule describes the responsibility and relationships between the federate and RTI, and it is the base that the simulation realizes the correct interaction.According to the application range, the rule can be divided into the federation rule and the federate rule.The federation rule includes that (1) the federation should has the federation object model (FOM) described by OMT; (2) the concrete implementation part of all objects in FOM is completed by federate, not RTI; (3) in the implementation of federation, the FOM data exchange among federates must be completed through RTI; (4) in the federation implementation, the data exchanging between federate and RTI must accord with the HLA/RTI interface criterion; (5) in the federation implementation, any one attribute of any one object example can only be possessed by one federate at any moment.The federate rule includes that (1) the federate should possess the SOM described by OMT; (2) the federate should update and reflect the object attributes in SOM, and transmit and receive the SOM object interaction; (3) the federate could actively transfer/receive the property of attributes in the federation implementation according to regulations in SOM; (4) the federate could change the condition to update the attribute of objects; (5) the federate should manage its own local clock to harmonize the data exchange with other federates.
OMT defines the general method to describe HLA object model, and offers standard format to record the information of object model, which could promote the interoperation and reuse of simulation applications.OMT includes FOM and SOM.FOM provides the sharing information and exchange conditions among various federates in one federation, and SOM is the object model of single federate, and it could offer the detailed explanation of capacity of each federate to the federation.
The interface criterion defines the mode of information interaction of federates by the mode of service, and includes the transferred services and the provided call-back services, and these services mainly include six aspects, i.e. the federation management, the announcement management, the object management, the property management, the data distribution management, and the time management.HLA is a system structure of the distributed simulation, and it doesn't mean the concrete software set, and RTI is the concrete implementation of the HLA interface criterion.RTI is the core of the whole HLA technical system.

Functional description of RTI
The typical RTI system is composed by the RtiExe, FedExe, and libRTI base.RtiExe is to manage the creation and destruction of the federation running, and each federate completes the initialization and joins into the corresponding federation implementation by the communication with RtiExe.FedExe manages enter and exit of the federate, and supports the data communication and running among federates.libRTI is a C++ base, and the federate transfers the RTI service by use the libRTI base to complete the information interaction with other federates.
As the core of the federation implementation, RTI has the function which is similar with the distributed operation system with special intention, and it could traverse the computer platform and the network system, separates the logic and communication of simulation behaviors, and provides various standard services required by the federate, and accordingly strengthen the interoperation and transplantation of simulation applications.RTI takes charge the creation/withdraw of federation, the enter/exit of federate, the enrollment/withdraw of object examples, distribution of distributed data, maintaining the uniform of distributed data, and harmonizing the time pushing among federates in the federation.Before the simulation runs, the guarding course of RtiExe runs on the RTI servicer, and this course is started by manual work and enters into the supervision state.The FedExe is created by certain federate first, and this course establishes the association with RtiExe by the appointed communication channel and registered its address to RtiExe.Then, the federate could transfer the RTI service to inquire the address of FedExe to RtiExe, and ask the manager to join the federation implementation course.When the federate produces one object in the implementation course, it registers this object to RTI, and RTI will distribute unique id to the object.When the state of object changes, the federate transmits the updated state value of each object to RTI, and RTI would decide transmitting data to the federate according to the public and ordered information and filtrate redundant information at the same time.Similar with the creation of object, when the federation implementation ends, manager sends the information of ending the simulation implementation to all federates, and when all federates end the implementation, RTI informs the manager of FedExe to end the Fedexe.In the whole process of simulation implementation, RTI has very important function.

System structure of RTI
The most significant characteristic of the HLA system structure is to realize the separation of the simulation function and the running support system, and this characteristic is applied n the design of the RTI system structure.At present, the system structure with modularization, distribution, and hierarchy is mainly adopted, and the coupling relationships among various functional models are reduced as much as possible and the relationship of hierarchy transfer is adopted to strengthen the independent development of various functional models, and reduce the influences among them.
The characteristic of the modularization system structure is to possess a central node with all functions, and this central node could implement all services, and federates interact by this node.This model has simple structure, could be implemented easily, but the burden of this central node is large, and it will easily be the bottleneck of the system, making against the expansion of the system.
The distributed system structure is similar with the system structure of the ALSP system, and there is no the central node, and federates depend on the harmonizing algorithm of LRC to implement the push and interaction of the simulation clock.The advantage of this model is that there is not the system bottleneck, and the system could be flexible, but the harmonizing algorithm is very complex, and the running efficiency is low in most situations.
The characteristic of the hierarchy system structure is to set up the RTI servicer by the hierarchy, and each sub-servicer of RTI takes charge the service requests of one or one set of federate, and the service requests which could not be completed will be put in the higher-level RTI servicer.Combining with the advantages of above two models, this model is the most extensive structured model in the application.

Key implementation technologies in RTI
The core software of the implementation of HLA is the implementation of RTI, and in six management services of RTI, the implementation of the time management and the data distribution management is most difficult.Therefore, the research emphasis of RTI is the implementation technology of the time management and the data distribution management.

Time management strategy in RTI
The key problem of RTI time management is how to harmonize the local times of various federates to realize the whole time push of the simulation, and ensure the correctness of the event logic relationship based on time, and support the interoperation among the federates which adopt different time management mechanism in the federation.
As viewed from the support of interoperation, the time management should be designed as the comprehensive integration frame which could support the different time mechanism among multiple federates in the federation.The time push mechanism of federate has four types, i.e. the logic synchronization, the logic time passiveness, and the logic time initiative.RTI time management could offer the service primitive for the push of time, and federates transmit the time push request to RTI according to their loci time push mode, and RTI adopts corresponding harmonized push strategy to push the logic times of various federates according to the type of the federate in the time push.In the practice, the conservative mechanism or the optimistic mechanism is adopted to push the logic times of various federates, and ensure the causal correctness.Corresponding algorithms includes the management method based on the minimum timestamp and the management method based on the advance quantity.Except for adopting various optimized time management algorithms to effectively ensure the ranking adjustment of the timestamp information, the time management system structure separating the computation of the timestamp sequence with the ranking transmission algorithm of the timestamp sequence, and this time management system structure could ensure the flexibility and expansion of the system, adapt the adjustment requirement of different simulation system time, and try to ensure the independence of the time management model and reduce the influence to other modules.
As the comprehensive integrated frame supporting the interoperation, when designing the implementation of time management, four following problems should be emphasized, i.e. (1) satisfying the real-time requirement of the simulation application, (2) high-precision clock synchronization adjustment in the distributed strong-real-time simulation system, (3) harmonizing the synchronized implementation among federates, (4) maintaining the time-space coherence of the whole system composed by the interoperated simulation entities.Generally speaking, the implementation of the time management function must accord with the object management and the data distribution management to ensure the logic correctness of the data transmitting to federates.

Implementation strategy of data distribution management
The main intention and function of the data distribution management is to use the data filtration mechanism to reduce the communication expense among nodes.To offer the data filtering method based on values, the data distribution management generally adopts the concept of pathway-choosing space which is the standardized multi-dimensional reference frame, and the federates use this reference frame to describe the type and condition of the data they could transmit and hope to receive.The data distribution management adopts the hierarchical structure.
(1) Interest expression: Federates explain the region where the data they want to order and publicize to RTI.
(2) Combination: It means to adopt certain combination algorithm to try to combine the ordered regions and the updating regions in the pathway-choosing space as much as possible, to reduce the communication and computation expenses in matching.
(3) Matching: It is to compare whether the ordered regions and the updating regions in the pathway-choosing space are superposed.
(4) Establishing the link: It means to establish the network link based on the ordered federate set generated in matching.
(5) Data transmission: It means to transmit the attribute and interaction to the ordered party of these data by the established network link.
The current implementation of the data distribution management has following main characteristics, i.e. (1) separating the pathway choosing with the data transmission, (2) adopting hierarchical system structure, (3) adopting hierarchical filtering mechanism.
At present, the data distribution management mainly realizes the distribution management of data in the real-time condition, and for those federates adopting the logic time, the data distribution management should also deal with the synchronization between data updating and ordering for the federates with different logic times.

Conclusions
HLA is a new generation distributed interactive simulation high level architecture, and the implementation of RTI is its core technology.Whether the RTI design is reasonable will directly influence the running and implementation of the whole simulation system.The implementation technology of the time management and the data distribution management is the emphasis in the RTI research.For the time management, the running concurrency of various federates should be further studied, and the hierarchical and classified strategy should be adopted to hierarchically manage the federates according to the different application demands of time push, and the time adjustment of the federates with close coupling should be centralized to manage by different time management algorithms to optimize the time management performance of the whole federation, and satisfy the simulation running requirements of the complex system.For the data distribution management, the key technology is to quickly and conveniently obtain the set of all ordered members in the corresponding updating region by comparing the ordered region with the updating region.