Using the Tool Complex G2 for Controlof Electrophysical Complex
V. Rybin G.Rybina
Moscow State Engineering Physics Institute (Technical University)
31, Kashirskoe shosse , Moscow, 115409, Russia
Abstract
We present here a research project connected with using
integrated expert system for control of electrophysicalcomplex. This paper deals with the prototype of real-time
expert system (RTES) developed by Gensym′s G2 tools.
The electrophysical complexes are complex engineeringtechnical objects, which have many input and output
parameters and often these parameters can be dependent oneach other. Than electrophysical complexes have more one
level allocate structure of control system and common
number of parameters and values which control needed canbe a couple thousand. It must be point that thedemonstration prototype of RTES for control ofelectrophysical complex, which is working up in Moscow
State Engineering Physics Institute (Technical University)
will use to work different projects of creating elements andsubsystems of RTES and also for teach a final-year
students of Automation and Cybernetic departments to use
modern software like as G2. Function of this prototype are
realizing on DEC′s ALPHA/AXP platforms.
1 Introduction
The modern electrophysical complexes (EC) arecomplex engineering-technical objects. The distinctive
peculiarity of it are the interaction of charge particles withelectromagnetic fields. EC are multiparameter, unlinear
and unstable objects of control with many input andoutput parameters and often these values can bedependent on each other. Than EC have more one level
allocate structure of control system and common number ofparameters and values which must be controlled can bea couple thousand.
The difficulty and time of design hardware andsoftware providing of control system for same objects
can be particularly shorten if use new technology likeas system G2 Gensym Corp. [1]. G2 is the core of
Gensym’s family of artificial intelligence (AI) products.
G2 is a development environment for creating anddeploying intelligent real-time applications. G2 can be used
to develop applications that solve many problems
commonly encountered in business, scientific, andindustrial markets. While G2 is flexible enough to use foralmost any intelligent application, G2 users typically apply
G2’s capabilities to complex situations that require:•••••

Monitoring, diagnosis, and alarm handling
Scheduling and logistics
Supervisory and advanced control
Process design, simulations and re-engineeringIntelligent network management•Decision support for enterprise-wide operations
G2 provides a complete, graphical development
environment for modeling, designing, building, anddeploying intelligent applications.
An application in G2 is called a knowledge base (KB).
All components of a KB exist as items. The knowledge anddata in a KB are represented by special items calledobjects. Items and objects can appear graphically as icons.
G2 calls the “blank pages” upon which you create andmaintain objects workspaces. A logical hierarchy of objects
and workspaces can be created to group and organize KB
data. A large KB can be developed from smaller, moremanageable pieces called modules.G2 development isbased on object-oriented design. Knowledge representation
maintained and extended through classes in the G2 classhierarchy.
G2 support either Motif or MS-Windows system styles,
and tools for conversion between both styles.
At the core of the developer′s environment lies G2′sstructured natural language for creating rules, models, andprocedures. G2 includes concurrent execution of rules andprocedures and the ability to reason about behaviour overtime. G2′s natural language facilities allow to create users
menu translations for none-European languages.
G2 includes network and interfacing capabilities throughseveral mechanisms :• Telewindows• G2 to G2 interface• G2 Standard Interface (GSI)• G2 File Interface (GFI)
Telewindows allows more than one user to access thesame G2 independently. The G2 to G2 interface lets two ormore G2 processes to connect for the purpose ofexchanging data. G2 supports either a DECnet or TCP/IP
protocol. The GSI product is a network-oriented tookit
used for developing software interfaces, or bridges,
between G2 and other, external systems. The GFI interface
allows G2 to read and write external data files.
G2 supports the use of foreign functions, which arefunctions written in C or C++. The foreign function
interface is platform-undependent.
The specialists in specific knowledge can create fastand effective prototypes for future systems, test and take its
to finish stage. Target of this paper is research ofpossibility of system G2 used to make the prototype ofreal-time expert system (RTES) for control of EC. The next
section describes the prototype structure of RTES forcontrol of EC. The section 3 gives an examples of G2based KB of vacuum subsystem and G2-based KB coolingsubsystem of superconductor magnets. Finally we conclude
and open some perspective in this report.

2 Prototype structure of RTES for control of EC
Developing prototype of RTES [2,3,4,5,6] for controlof modern EC is oriented towards solving next problem:• schematic introduction of main processes happen incomplex and in other subsystems and in different levelprocesses;• graphical interface with user to observe changes ofmain parameters, which describe work of complex
system;• automatic control work of complex and control system,
registration of different deflection from standard or
setting mode and inform operator about it,
prealarm, alarm shut down, regulate mode, come backto work mode after consultation with user;• study of users actions and teach user in training
apparatus mode;• make archives of all users actions and values ofcomplex, working all information up, issuing allnecessary information.
The modern EC include some difference subsystems,
which provide receiving of charge particles, acceleration
them, focus and transport them with definite requirements
showing energy, energy spread, angle divergence and time
characteristic of accelerated particles. The developing
system was very difficult and multifunctional therefore
was using unit principle of building the prototype of RTES
for control of EC. In accordance of structure of EC wasassigning separate units. Than we can union all units andreceive the prototype of RTES with single KB. At
present stage of work it was using three subsystems:
vacuum, magnet and highfrequency power .
Let′s examine architecture, composition and structure
main components of work-version prototype of RTES. It
consist of as traditional components of expert system (KB,reasoning, work memory, explanation and acquisition )as and special components, allow interaction withequipment EC in real time (modeling subsystem,subsystem connected with equipment EC). KB of the
prototype maintain description of equipment, belong toaboveforegoing life-support subsystems, in hierarchy of G2
objects descriptors and description of emergency situations
identifying by means of rules and procedures of G2.
Therefore KB of this version system maintain:• objects that reflecting different kinds of equipment
subsystems for support of vacuum, superconductor
magnets and highfrecuency power;• connections that reflecting joining of equipment;• variables, which must receive values from different
sensors ( in RTES its come in from subsystemmodeling outside world);• lists that using for storage messages operator;• workspaces to represent of EC structure charts ;• rules for determination of concrete situations neededprocess;• procedures for successive making of concrete actions(start, stop, shut down, tune subsystem of EC );• formulas for work up of parameters which arereceiving from sensors;• functions for estimate of complex calculated

values of concrete parameters.
Based on reasoning RTES realize deduction of
conclusions or recommendations next types: notification ofoperator about deflection of control values (received orcalculated),sending of control command to concrete
equipment, start of complex control process etc.
In this version RTES by help of reasoning keep up only
forward inference strategy. It must point that from nine
types of rules G2 are using common rules next types: areexciting with changes of conditions(if ...then),are exciting
with restart of system(initially) and rules-demon (scan).
Possibilities to use common rules G2 allow to abstractfrom concrete equipment and describe only common
properties and lows, inherent sum total type of equipmentthat particularly to short of difficulty of forming KB.
Interaction subsystem secure of realize for twofunctions:• constant delivery of messages about changes of main
parameters, characterizing work of EC, on screen, andwarning about emergency situations;• possibility of operator′s influence to change function ofEC equipment.
Modeling subsystem, which used instead of subsystemof real EC for imitation data of sensors include acomponent, joined with modeling of outside negativeinteraction (for example: leak in vacuum camera or
heating of superconductor magnet) and component
modeling of change of control parameters during the workof EC.
3 Some examples of KB fragments
In this section we describe some examples of G2-based
KB of vacuum subsystem and G2-based KB coolingsubsystem of superconductor magnets.
3.1 Example of realization vacuum subsystem of EC
Let′s examine few questions of KB realization ofvacuum subsystem by G2. The main object is vacuum
camera, in which must be high vacuum.
For example, vacuum camera can have three states:
atmosphere pressure ( P > 0,05 Pa), low vacuum (0,0007
Pa< P<=0,005 Pa), high vacuum ( P< =0,0007 Pa).
Combine with it in KB is including three rules:
for any preobr-pmm-46 M
for any vacuum camera V connected to M
if the pressure of M>0,005 then conclude that thestate of V is atm_pr
for any preobr-pmm-46 M
for any vacuum camera V connected to M
if the pressure of M <=0,05 and the pressure of M
>0,0007 then conclude that the state of V is low_vac.
for any preobr-pmm-46 M
for any vacuum camera V connected to M
if the pressure of M <=0,0007 then conclude thatthe state of V is high_vac.
The other group of rules in KB are watching behindstate of vacuum camera and pump out process, depend

from are starting procedures, which control rising vacuum
to necessary point, moreover, procedures starts thenecessary equipment.
In case of happened unpressurized of vacuum camera
it′s isolated. All attributes present on scheme and thenit′s can analyzing work of system. The attribute“pressure of vacuum camera” save self history on 100values. It′s permit to make a grath measurement ofpressure.
3.2 Example of realization cooling subsystem ofsuperconductor magnets
It is staying at questions of KB realization of coolingsubsystem of superconductor magnets. This subsystem areinclude the different types of magnets with cooling
substances: helium with temperature 5K and helium
with temperature 2K.
When temperature of magnet equal temperature ofoutside the for any magnet open tap, which give thepossibility of helium 5K come to magnet tank andtemperature will staying 5K. After it the same operationis happening with helium 2K.
When temperature of magnets are 2K its will
became superconductor. Now magnets are ready toaccelerate beam . Follow are presenting samples of rules,
which are controlling these processes (initially conclude
that the temperature of every magnet = 2 and conclude
that the state of every tap is closed and start relate for anymagnet M):
for any srv S connected to M
if the temperature of M > 5 and the state of S isclosed then start freeze 5 (M)for any sfv S for any magnet M that is connect to S
if the temperature of M > 2 and the temperature of
M <=5 and the state of S is closed
then start freeze 2 (S).
4 Conclusions
It must be point, that is working up in Moscow StateEngineering Physics Institute ( Technical University )demonstration prototype RTES for EC will using to work
different projects of creating elements and subsystems

RTES and for teach students to use modern software like asG2.
Functions of prototype are realizing on DEC’s ALPHA/AXP platforms ( with Open VMS 6.1 operative system).
Acknowledgments
This work is supported by RFFI grant number 96-0101078. Authors are thanking Gensym Corporation, which
given for MEPhI free license G2 system and a group ofRRDIICAT (Russian Research and Development Instituteon Information and Computer Aided Technologies) for
help and consultations.
References[1] D. Siegel, D. Riddell, “introducing G2 4.0”, Marketing
Bulletin.-Gensym Corporation,1994, November.
[2] V. Rybin, G. Rybina, V. Chuchkin, “Application G2
Software for Development of Demonstration Prototypeof the Modern Electrophysical Complex Control
System”, Proceedings of Real-Time Expert Systems
Conference. Moscow, CRDZ, 1995, p. 93 -99.
[3] V. Rybin, G. Rybina, A. Haritonov, “The Real-TimeExpert System Prototype for Control of theElectrophysical Complex”, Proceedings of Dynamic
System in Modelling and Control Conference.
Moscow, CRDZ, 1996, p.53-55.
[4] V. Rybin, G. Rybina, A. Haritonov, “The Questionsof Using System G2 for Design of the Prototype ofRealTime
ExpertSystem for ControlofElectrophysical Complex”, Proceedings of KAI-96,Russia, Kazan, October 5-12, 1996, v.2, pp.225-230.
[5] G. Rybina, “The Questions of Design of Integrated
Expert Systems for Diagnostics of Complex TechicalSystems”, Proceedings of 6-th International Conference
KDS-97. Ukraine, Yalta, Sept. 1997. Intelegence
System Developers and Users Association, 1997, Vol.
2. p. 421-428.
[6] V. Rybin, G. Rybina, “The Prototype of a Real Time
Expert System for Control of ElectrophysicalComplex”, Proceedings of 15th IMACS World
Congress on Scientific Computation, Modelling andApplied Mathematics: Berlin, August 1997, Vol.4,
Artificial Intelligence and Computer Science, pp.97100.