From: efulsang@ADS.COM (Ejner Fulsang)
Newsgroups: comp.ai.shells
Subject: CLIPS as a realtime process control shell
Date: 7 Apr 92 21:39:19 GMT
Article-I.D.: ads.1992Apr7.213919.22700
Organization: Advanced Decision Systems, Mtn. View, CA (415) 960-7300

My original statement:
> Why not use CLIPS? It was developed by NASA expressly for realtime process 
> control: 

Brian Donnell's response:
>> CLIPS was not developed for realtime process control; it has no 
>> direct support for temporal reasoning (although the next major 
>> release may have some).  


Brian,
	I'll take a hit on being a little presumptuous about what your
original design intentions for CLIPS were.  The demo.exe provided with
PC versions of CLIPS implies that the design team did in fact desire
to provide the capability to do realtime process control.  But, I
still dispute the part about no direct support for temporal reasoning.

	Imagine an air-conditioned room with three sensors: sensor-1
returns the temperature of the room, sensor-2 returns the desired
temperature of the room set by the occupant and sensor-3 returns the
state of the air conditioner (ON/OFF).  Using CLIPS' deftemplate
function we can keep track of the process state of the room.  Three
fields would be used for each sensor: sensor-name <STRING>;
sensor-value <INTEGER or BOOLEAN>; sensor-time <FLOAT>.  Rules can be
written to poll the sensors every 10 seconds or so using the CLIPS'
time function and some RS-232 interface code.  The deftemplate modify
function can be used to update the process state so that the fact list
doesn't get all cluttered up with process history.  Other rules can do
the necessary process state analysis and turn the air conditioner ON
or OFF as needed.  

	What I have just described here is a simple system for
realtime process control based on polled sensors.  A more elaborate
system could store multiple process states say 1 minute apart so that
the system could reason not just about the current process state but
also about the previous state and the one before that and so on.  The
idea is that the system would now have the necessary data to rate the
progress of the air conditioner at bringing the room to the desired
state.  Then the air conditioner could be turned to OFF, SLOW, MEDIUM,
or FAST as appropriate.

	The only support not directly provided by CLIPS right now is
the interface code, but I don't know of any other systems that provide
that kind of code built in anyway.  And that brings me to CLIPS'
second best feature -- the source code that comes with it!  Nobody
else that I'm aware of provides that.  Some commercial shells have
API's and some of those API's are pretty good.  But, the best API
still doesn't compare to having _all_ the source code right there in
front of you for you to have your way with.  BTW -- CLIPS first best
feature is its price.  Even when you have to pay for it, its still a 
very sophisticated package and well worth the few hundred you have to
cough up for it.

	So, while CLIPS may not have been designed expressly for
process control, I still contend that it can do the job.  Maybe CLIPS
is not fast enough for some applications such as beam forming phased
array radars.  But, there are many other practical applications where
I believe CLIPS will do just fine.  `Sorry, Brian.  Nothing you can 
say will shake my appreciation of the efforts of you and the rest of
the CLIPS Design Team.  

- Ejner 

/***********************************************************************
 Ejner Fulsang, Sr. Systems Engineer        Internet:  efulsang@ads.com
 Advanced Decision Systems                  Phone:        (415)960-7394
 Mountain View, CA 94043                    FAX:          (415)960-7500
************************************************************************/
Newsgroups: comp.ai.shells