G2: Chemical Process Control - American Chemical Society


G2: Chemical Process Control - American Chemical Societypubs.acs.org/doi/pdfplus/10.1021/bk-1989-0408.ch013a unified fra...

0 downloads 92 Views 1005KB Size

Chapter 13

G2: Chemical Process

Control

Robert L . Moore

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

Gensym Corporation, 125 CambridgePark Drive, Cambridge, M A 02140

The requirements for expert systems for process control have inspired new designs based on real-time knowledge base inferencing. Object oriented representation of plant equipment, knowledge representation of the interactions of processes and models of process behavior -- heuristic as well as analytical -are incorporated into a real-time expert system for process control. The application of inference in real-time requires using metaknowledge to focus the inferencing resources of the expert system. Finally truth maintenance requires a temporal model of the time dependence of the truth of data and inferred results. A structure which includes these considerations is presented. Over 100 installations have been implemented as of this writing.

This paper describes the G2 expert system technology developed for realtime applications. Current installations are primarily in large chemical process plants, where the need for this technology is to advise operators for safety and economic reasons. Other applications include manufacturing in the aerospace and microelectronics industries, network monitoring, telemetry data monitoring, robotics and financial transaction monitoring. In this paper we discuss the basis of the technology of the G2 real-time expert system. G2 allows the representation of deep knowledge, analytic and heuristic knowledge, and other aspects required for the implementation of real-time expert systems. Graphics and structured natural language interfaces allow the user to construct knowledge bases of dynamic applications, to test expert system behavior and to validate knowledge bases under various dynamic scenarios. The interactive developer interface allows short development0097-6156/89y0408-0190$06.00/0 o 1989 American Chemical Society

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

170

EXPERT SYSTEM APPLICATIONS IN CHEMISTRY

and-test cycles. Built-in data interface facilities allow the engineer to implement an application interactive with live data sources.

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

Knowledge Representation Several considerations of dynamic domains impose requirements on the knowledge representation: 1. The concurrent use of analytic and heuristic models. Conventional simulation methods allow analytic models. Conventional expert systems allow heuristics, but leave the analytic part for the user to program. The combination of analytic and heuristic knowledge in an object oriented framework allows the applications to be addressed in a unified way. 2. Interaction between objects. The structure of an application is frequently important in predicting behavior, performing diagnosis or in scenario simulation. Structure is generally expressed as connectedness of objects, or proximity of objects. Structure may also be expressed in an object's attributes, especially where connections may vary in time. A framework which has the built-in capability to reason in terms of object connectedness or proximity, and to integrate analytic as well as heuristic knowledge in these terms, allows construction of the knowledge for the application. 3. Dynamic behavior and live data. Many problems have a real-time aspect, including dynamic knowledge in differential equation form, such as equations of motion. Live data may be needed for the eventual deployment, and data access and real-time processing may be important. A framework which includes these real-time considerations in the expert system design is required. The framework allows simulation to provide real-time values for prototyping and development, to be supplanted by sensor-based data at installation. Data servers provide interfaces to other systems with a minimum of user work, so the prototype can become the actual application. In addition to the general characteristics of the applications, which call for a unified framework, the general desirability of rapid implementation calls for the use of high level interfaces. In G2 these include graphical construction of the application domain and structured natural language for expression of knowledge, models, and other information. Modern parsing techniques allow the user to express the knowledge in reasonably natural form, and G2 checks the user input as it occurs. Look-ahead menus help the user, and errors are immediately flagged. This eliminates a whole level of debugging which conventional programming requires. Fig. 1 shows connected objects. The domain was defined on the workstation screen by connecting the separate objects. The G2 expert system then "knows about" the connection and interaction of these objects. In Fig. 1, the engineer is defining a rule. A "look ahead" menu helps the engineer to define knowledge in a form that G2 can understand, while the rule itself is in a natural form. The engineer can refer to current or past

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

value of current first of the following

any attribute-name any class-name

Fig. 1.

NKUM

PREHEAT

MMYH M M I H

wim

r

GlMSyM w a r n NMim

H i a m «fijyM

m s m HMXH NW>H

MMVH

Gensym G2

REACTOR-1

MNSTM W W I W W

MM yn MMyn MMyn MMyn MI MynMyn MMyn MMyn MMyn M» I

I

MMtyM HW Miyn H K » M MHtyn •iinyn MTH M M

(JIHjyM «INjyH

MMJTM

MmyM

MMim

Defining heuristic knowledge.

interpolated value of collection time of maximum minimum average standard deviation of rate of change per integral in expiration time of icon-color of icon-x-position of icon-y-position of icon-heading of icon-width of icon-height of name of distance between symbol sum product count of each

if the p t e of change per minute of the temperature of the temperature-sensor connected to any reactor during the last 1 minute > 20 then conclude that

MiyM

M M X H

MM:

MNS:

M Ntyn MMyM HiyM n yn MMyn MNtynMM MyM ynMMyn MMyn MMynMw yin n MMyn a MM yn MMM ynMyM nN nM M iMynMM nNNlytynn jyM tyyM H M MyM nnNM NtyM nNtyn MNtyn M etriN sytyw M yn nM MM ntyynn M N tytyn M M yn nMyM n MNtyn • MyNMW nM«fynmyM M t y n m y H t y n M n M N t y M N n M N t y MM NM tyyn iMM N t y n e i H i m MNI M H y j w M M y n M M n yM nMM NtyM nNM NtyM nNM NtyM nNM NtyM nNM NtyM nNM NtyM nNM NtyM nNM NtyM nNM NtyM n ynN«rtyn~• yn aintyn MMyn tM ynM ynN tynN tynN tynN tynN tynN tynN tynN tynN NM tynM M N t y n M t y n M t y n M t y n M t y n M t y n M t y n M t y n M t y n M t y n tyM nMM : tM ynMyM NM tynMyM NtM ynMyM NtM ynNtyM NtM ynNtyM NtM ynMyM MM ynMyM NtM ynMyM MM ynNtyM MM ynMyM MM ynN ynN » I> 1 M M y n N X n n n n n n n n n n M yM n M M M M H y t M Myn M Ntyn M Myn M M y n M N t y n M M y n M N t y n M M y n M M y n M M y n M M y n M M y n M M y n M M y n M M y n • 1 M M y n M N t y n H U H N MM tM ynNtyM Myn MNtyn MNtyn MMyn MMyn MNtyn MMtyn wmytn wxiyn MMyn MMyn MM: ytiMM nynHMm i HM •n«sM ynwyH MM MyM Ntynn MMyn MMyn MMyn MMyn MMyn MMyn MMyn MMyn MMyn MMyn MMyn « i MMyn «itfMyn n MMyn MMyn MMyn MMyn MMyn MNtyn MMyn MMyn MMyn • MMyn MNjy« MMyn Mutyn MMyn MMyn MMyn MMyn • ityn MMyn MMyn «

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

172

EXPERT SYSTEM APPLICATIONS IN CHEMISTRY

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

values, or to behavior over time. The rule can invoke conclusions or initiate actions. In many domains, there are multiple objects which have related knowledge. For example, there may be many pumps, all of which need inference analysis of a similar sort. Fig. 2 shows generic knowledge, which can be applied across a class of objects. The G2 inference engine can interpret all specific applications of generic knowledge by actively interpreting the schematic representation of domain structure. In the case of connected objects, the behavior can be defined in terms of the connection, which is understood by G2 "live" from the screen. For example: "if the rate of change per second of the temperature of the object X connected at an input of any heat-exchanger during the last 3 seconds > 5 then invoke diagnostic rules for X" This heuristic considers dynamic behavior of a connected object, and searches for causes of problems by tracing back through connections. The "X" in the above rule is a local name, within the rule. If a new object in the heat-exchanger class is created, through cloning for example, and it is connected to other objects, then the above heuristic will apply also to the new object. This allows the rapid implementation of diagnostics. Behavior of objects can be defined by classes or specific instances. An example of a class behavior might be: "state variable: d/dt( the velocity of any intercept-vehicle V) = (the thrust of V ) / (the mass of V ) etc." Here the behavior is generic, across the class, but individual instances can behave according to their own attribute values. A new object in the class can be created, by cloning for example, and it will inherit this behavior. The prototyping of hundreds of such objects becomes relatively trivial. Fig. 3 shows a robot navigation application. This was inspired by an installation of G2 at the Robotics Technology Group at the Savannah River Laboratory. The robots in the example seek the shortest path toward one of the "goals." The user can connect and disconnect the nodes of the example, and G2 will understand if the path exists between the nodes. The animation feature of G2 is used to move the robots during the scenario. The use of robots in a nuclear plant is primarily intended to avoid sending humans into hazardous environments. There are many examples in conventional chemical plants where a similar use of robots would be well justified. Fig. 4 shows critical path planning using G2. The user defines the possible paths by graphical connection of objects. Alternate structures can be considered, even by changes while running. This allows interactive design of planning strategies. In the particular example, a complex batch chemical processing plant is being scheduled by G2, with critical path activities explained by G2, to help the user with rescheduling the plant.

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

Fig. 2.

ml

"1

"

v

"" "

ffi

yn ot Ntyn otmyn otmyn otmyn otmyn otmyn otmyn | «t myn oimyn otmyn otmyn otmyn otmyn otmyn ot ml :yn « myn otmyn otmyn otmyn otmyn otmyn otmyn M.I I «f myn otmyn otmyn Of myn otmyn otmyn otnsyn et ml .yn otmyn otmyn otmyn otmyn otmyn otmyn otmyn I otmyn otmyn otmyn of myn otmyn otmyn ot ntyn et m|_ :yn otnsyn otmyn Of myn otnsyn otmyn Otnsyn otnsyn 01 of myn otmyn otmyn otnsyn otnsyn otmyn otnsyn otnsyn otmyn o .yn otmyn otmyn otnsyn otmyn otmyn otnsyn otmyn otnsyn otm: * OINS/M jyn otmyn otmyn otmyn otnsyn otmyn otmyn otm:

Generic knowledge for classes of objects.

Gensym G2

SAMPLE WITH PUMP RULES AND P R O C E S S CONTROLLERS

and the valve-position of any valve connected to the pump < .95 then conclude that the pump is working

if the inferred-recent-flow of any pump is normal

| the pv of lc-2 | 9.

| the sp of lc-2 | 3

| the p-out of tank-2 | 19.006

hide

| the outflow of tank-2 | 4JI77

enter

enter

f

n otmyn oimyn otmyn MHim otmyn N m m H M m u m m otmyn myn SfMiyn otmyn otmyn otmyn «fMyn otmyn otmyn MNtyn otmy n otnsyn otnsyn of myn otnsyn otmyn of myn otmyn of wyn otmyn 01 myn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmy n otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otm. :, myn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmy n otmyn otmyn otmyn ot myn otmyn otmyn otmyn otmyti ottityn 01 myn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmy n otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn 01 myn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmy iiyn otmyn otmyn otmyn otmyn otmyn otmyn otNiyn ottii myn otmyn ot myn otmyn otmyn otmyn otmyn otmyn otmyn otmy n otmyn otmyn otmyn otmyn ot myn otmyn otmyn otmyn otmyn 01 myn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmy n otmyn otmyn ot myn otmyn otmyn otmyn otmyn otmyn otmyn 01 myn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmyn otmy

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

BANGKOK

;TANCE-DETAILS

X

30T-2-DI S P L A Y S

)T-1-DISPLAYS

GOAL

A

N

MAP WORKSHEET

PARIS

ERMAN BERLIN

^

| the distance-to-goal of london | 461.834]

| the distance-to-goal of paris | 547.927 |

LONDON

7*

6-

BRUSSELS

| the diste ice-to-goal of brussels | 609.645~|

OSLO

69%,

BERGEN

NORj

Note: pause the system before moving goals.

Robot navigation example.

| the distance-to-goal of miami | "l72

129.495

363.266 | | the distance-to-goal of boston | 250.644 |

Fig. 3.

-IC

C A L G £ W

the distance-to-goal of Chicago

the distance-to-goal of calgary

MAP-WORKSHEET

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

Activity MIX-VAT-1 is on

E

]

)

|

y

Fig. 4.

ADD-

HE—>• TIME-1

COOL-REACTOR-1 GOOP-X-MADE

| the earliest-done-time of cool-reactor-1 |27

| the latest-start-time of cool-reactor-1 | 22~

Change colors on critical path

Print critical path events

Print critical time constraints

Print critical path activities

HOLD-REACTOR-1-AT-500





H

CONTROL-PANEL

HEAT-REACTOR-1 -TO-500

[

Critical path planning.

PUMP-G-INTO-REACTOR-2

PUMP-E-INTO-RE ACTOR-1

]

->-

|7

REACTOR-1-FULL

I

J^REAC

PUMP-D-INTO-REACTOR-1

>•

PUMP-C-INTO-RE ACTOR-1

_

| the earliest-done-time of reactor-1-full

7

CRITICAL PATH PLANNING

Iff

MENU-OF-ICONS

the latest-start-time of reactor-1-full

PUMP-F-lfMTO-REACTOR-2

REACTOR-1-CLEAN\ /

H-RE ACTOR-1

one-time of wash-reactor-1 | 3

irt-time of wash-reactor-1 | 1

PLANNING-NETWORK

i?m-?fl nm flrilulut m m - I

#12 12:03:24 p.m. Activity PUMPREACTOR-1-TO-VAT-1 is on critical path

#11 12:03:24 p.m. critical path

MESSAGE-BOARD

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

176

EXPERT SYSTEM APPLICATIONS IN CHEMISTRY

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

Knowledge Base Management Knowledge can be arranged on workspaces, on which the user can organize the knowledge for ease of management. Fig. 5 shows a variety of such workspaces, which can be stacked, expanded or contracted, and otherwise manipulated. Each workspace can be treated as a separate execution process, or they can be executed concurrently. In the case of large applications, there may be many workspaces, perhaps hundreds of them, each with hundreds of objects, rules, dynamic models, displays and other items. G2 provides a relational-knowledge-base retrieval facility to enable the user to manage such a large application. For example, the user may request: "show on a workspace every statement containing the word schedule" in which case a temporary workspace is created with copies of every model, rule or other statement with the chosen word or phrase, or "show on a workspace every rule where categories includes safety" in which case the temporary workspace contains all rules about safety This is an example of one use of metaknowledge ( knowledge about knowledge ). or "show on a workspace every object where the outlet-temperature of the object > 780" in which case the temporary workspace shows the objects which have the named attribute, and where the value of the attribute satisfies the request. In the temporary workspace, the user may interactively edit the knowledge, or may say "go to original" in which case the workspace containing the original of the item is brought up, with the cursor centered on the requested item. In this way, a user can navigate through workspaces containing thousands of items. Reasoning About Knowledge Two, apparently conflicting, requirements dominate the inference paradigm considerations in the real-time domains. One is the need for truth maintenance. With thousands of data changing rapidly, the validity of conclusions at all levels of inference are in question. The other requirement is for real-time performance, where real-time means fast enough to advise the human operator and/or control the robot or other process. First attempts at using expert systems for real-time applications involved taking a "snap-shot" of data and using a static expert system paradigm to perform inference. This process is then repeated after inferences are completed. Conventional pattern-matching paradigms which examine all possible conclusions for the current data values are too slow for most real applications. The static expert system approaches lead to slow performance on even small prototypes of a few hundred rules and a few hundred data values. This has been widely recognized. Code improvements and computer improvements can help. However, a fundamentally different inference approach is appropriate for real-time problems. The approach that a human expert uses in a real-time situation is to maintain a peripheral awareness across the domain, watching for

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

Hohne and Pierce; Expert System Applications in Chemistry ACS Symposium Series; American Chemical Society: Washington, DC, 1989.

Fig. 5.

L)V16

~7

7"

BROKE-TANK

VALVE-READOUTS

SMART-SENSORS

PULP-AND-PAPER-SCHEMATIC

hrokc-tank-Jcvcl | * whkf-watcr-tank-lcvcl

Page 1

Gensym G2

PAPER-EQUIPMENT-DEFINITIONS

PAPER-BREAK-RULES-AND-VARIABLES

LEVEL-RULES

ISA-ICONS

GRAPH

FAULT-RULES-AND-READOUTS

FAULT-CONTROL

COUCH-PIT-DIAGNOSTIC-RULES

BROKE-TANK-DIAGNOSTIC-RULES

11 Mar 89

p.m. Done loading 4PER.kb.16"

look

Managing knowledge on workspaces.

limit-consistency of broke-tank then

if the consistency of broke-tank < the low-

corrected"

room - low feed consistency must be

for the next 5 seconds that "Call mixing

consistency of feed then inform operator

if the consistency of feed < the low-limit-

to the valve

making-equipment connected at the input

consistency-check rules for the paper-

consistency of blend-chest then invoke

at an input to blend-chest < the

if the consistency of any valve connected

Performing analysis"

cause upset in paper basis weight.

blend-chest] %) - if not corrected will

consistency low ([the consistency of

next 5 seconds that "Blend chest

blend-chest and inform operator for the

invoke consistency-check rules for

limit-consistency of blend-chest then

if the consistency of blend-chest < the low-

BLEND-CHEST-DIAGNOSTIC-RULES

BLEND-CHEST-DIAGNOSTIC-RULES

Top-Level Workspaces

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

-4 ^1

Downloaded by IOWA STATE UNIV on March 1, 2017 | http://pubs.acs.org Publication Date: September 1, 1989 | doi: 10.1021/bk-1989-0408.ch013

178

EXPERT SYSTEM APPLICATIONS

IN

CHEMISTRY

performance exceptions, and then focusing on areas of interest. The G2 inference engine operates similarly. The inference engine continually scans knowledge which the expert has specified for peripheral awareness. If a safety-threatening condition occurs in a reactor, for example, the G2 inference engine uses metaknowledge to determine which knowledge to invoke, thus focusing on the area of interest. One benefit of the metaknowledge approach is that very large knowledge bases can be run in real time. Since many types of problems and behaviors are represented in the knowledge base, it can get quite large, with thousands of rules. However G2 does not consume computer time looking for patterns in all of this knowledge all the time. Rather it focuses attention on the knowledge needed. The concept is like the human thought process, in that a human does not use knowledge of swimming or driving when walking in the park. The human mind focuses, using the knowledge relevant to the task. In static expert systems, truth maintenance involves changing inferences when data changes. In real-time problems there is an additional requirement to change inferences even if no new data is available, since time is a factor in validity or certainty of inference. One way to express this temporal validity information is to attach an expiration time to each value maintained by the inference engine, and propagate this when inference is carried forward. Generally, when a conclusion is based on several time sensitive variables, the earliest of their respective expiration times will be carried forward. Expiration times can be propagated forward through multiple levels of inference, but there are also ways to limit this propagation. Application Example Plant safety is an important application area for G2. Many of the early installations are for chemical and nuclear safety purposes. Of course, plants are already provided with extensive alarming and other safety related equipment. G2 does not replace any of this - it is used to add another intelligent observer of the plant operation - an observer that watches thousands of variables with tireless attention, applies knowledge of expected behavior and interactions, and indicates to the operator an intelligent description of unexpected or unsafe behavior. It is questionable whether a plant should be run without such an observer. As an example of the methodology involved with such an application, consider the following: "if abs(the valve position of any valve V - the valve position of V 2 minutes ago) > .05 and abs(the flow of V - the flow of V 2 minutes ago)/(the flow-maximum of V)