;;; -*- Mode:Common-Lisp; Package:DME-user; Base:10; Theory:DME-KB; Implementation: #+clos-frames :Clos-And-Epikit #-clos-frames :epikit -*-

;;; WARNING.  If you change any of the names of the central classes like model-fragment
;;; then update the kb-vars file.

;; This file contains the definitions of classes of objects needed by DME.

;;; See also the function INITIALIZE-DME-KB and the file WORLDS.LISP

(in-package :dme-user)
(in-implementation #+clos-frames :Clos-And-Epikit
		   #-clos-frames dme::*dme-implementation*)
(in-theory *background-theory*)

;==============================================================================
;;; Define these early, so that we can assert things about other relations without warnings.
;==============================================================================

(define-class dme-kernel-class ($class-that-is-part-of-the-dme-kernel)
  "Instances are classes that are part of the DME kernel.")

(define-function all-superclasses ($class)
  "The cached list of superclasses of this class.")

; function needed by the explanation facility.

(define-function english ($anything)
  "DME's convention for documentation.  A function.")

(define-function dimension (?quantity)
  "What dimension are the quantities in the slot"
  :def (quantity-slot ?quantity))

(define-function unit ($dimension)
  "In what unit is this dimension is expressed (in the current scenario file)")


;==========================================================================
; Definitions for the -*- syntax


(define-function it-is-* ($entity)
  "Contains a description of the object"
  :def (or
	 (model-fragment $entity)
	 (qualitative-parameter $entity)
	 (quantity-slot $entity)
	 (other-slot $entity)
	 (behavior-constraint $entity)))


(define-function notes ($entity)
  "Contains notes about the object"
  :def (or
	 (model-fragment $entity)
	 (qualitative-parameter $entity)
	 (quantity-slot $entity)
	 (other-slot $entity)
	 (behavior-constraint $entity)))


(define-function the-*-the-object ($slot)
  "Contains a one word description of the relationship between the slot and 
    its object"
  :def (or
	 (qualitative-parameter $slot)
	 (quantity-slot $slot)
	 (other-slot $slot)))


(define-function component-is-* (?om)
  "Describes in what state the component is when the given operating
    mode is active"
  :def (operating-mode-model ?om))

;==============================================================================
;==============================================================================

(define-class boolean-value ($true-or-false)
  "The extensional set of boolean truth values."
  :Axiom-Def (dme-kernel-class boolean-value)
  :iff-def (or (= $true-or-false TRUE)
	       (= $true-or-false FALSE)))

(define-class model-fragment ($x)
  "The top level class for all models."
  :Axiom-Def (dme-kernel-class model-fragment))

(put-function-value 'Model-Fragment 'it-is-* "a model fragment"
		    *background-theory*)

;; Individual-Behavior-Model
(define-class behavior-model (?model)
  "All model fragments that contain any behavioral description."
  :Axiom-Def (dme-kernel-class behavior-model)
  :Def (model-fragment  ?model))

(put-function-value 'behavior-model 'it-is-* "a behavior model"
		    *background-theory*)

(define-class structural-element-model ($model)
  "All model fragments that contain any structural-element-model description."
  :Axiom-Def (dme-kernel-class structural-element-model)
  :def ((model-fragment $model)
	(continuous-behavior-model $model)))

(put-function-value 'structural-element-model 'it-is-* "a structural-element-model model"
		    *background-theory*)

(define-class alarm-model (?model)
  "All model fragments that represent alarms."
  :Axiom-Def (dme-kernel-class alarm-model)
  :def ((discontinuous-behavior-model ?model)))

(put-function-value 'alarm-model  'it-is-* "an alarm model"
		    *background-theory*)

(define-class flow-point (?model)
  "All model fragments that represent flow points."
  :Axiom-Def (dme-kernel-class flow-point)
  :def ((structural-element-model ?model)))

(put-function-value 'flow-point  'it-is-* "a flow point"
		    *background-theory*)

(define-class system-model (?model)
  "All model fragments that contain any system description.  A system is a type of structural-element-models that are composed of
    one or more components, other than terminals."
  :Axiom-Def (dme-kernel-class system-model)
  :def (structural-element-model ?model))

(put-function-value 'system-model 'it-is-* "a device model"
		    *background-theory*)

(define-function component-class-of-opmode (?model-class)
  "The class of components that can have a certain class of operating modes.  The value must be a subclass of
  structural-element-model  "
  :def (operating-mode-model ?model-class))

(define-class operator-action-model (?model)
  "The class of all model fragments that denote operator actions.
  By convention, devices will have a subclass of this class whose immediate subclasses are all of
  the behavior modes of a given device, i.e. Battery-Operating-modes is a superclass of
  the overcharged, undercharged etc. modes."
  :Axiom-Def (dme-kernel-class operator-action-model)
  :Def (behavior-model ?model))


(define-class Continuous-behavior-model (?model)
  "The class of model fragments representing continuous phenomena."
  :Axiom-Def (dme-kernel-class continuous-behavior-model)
  :def (model-fragment ?model))

(put-function-value 'Continuous-behavior-model 'it-is-* "a continuous model fragment"
		    *background-theory*)

(define-class Discontinuous-behavior-model ($model)
  "The class of model fragments representing discontinuous phenomena."
  :Axiom-Def (dme-kernel-class discontinuous-behavior-model)
  :def ((model-fragment $model)
	(behavior-model $model)))

(put-function-value 'Discontinuous-behavior-model 'it-is-* "a discontinuous model fragment"
		    *background-theory*)


(define-class discontinuous-quantitative-behavior-model (?model)
  "The class of behavior-models representing phenomena causing discontinuous changes to quantity values."
  :Axiom-Def (dme-kernel-class discontinuous-quantitative-behavior-model)
  :def (Discontinuous-behavior-model ?model))

(put-function-value 'discontinuous-quantitative-behavior-model 'it-is-* "a quantitative action"
		    *background-theory*)

(define-class discontinuous-non-quantitative-behavior-model (?model)
  "The class of behavior-models representing phenomena causing discontinuous and non-quantitative changes."
  :Axiom-Def (dme-kernel-class discontinuous-non-quantitative-behavior-model)
  :def (Discontinuous-behavior-model ?model))

(put-function-value 'discontinuous-non-quantitative-behavior-model 'it-is-*
		    "a non-quantitative action"
		    *background-theory*)

(define-function instantiation-condition (?model-class)
  "The data structure encapsulating the condition for creating an instance of a model class."
  :def (behavior-model ?model-class))

(define-relation continuous-at-model-change-p (?MF-inst ?qty-slot)
 "Specifies that the value of qty-slot of mf-inst is continuous at the boundary of operating regions. 
MF-inst: Model instance.
qty-slot: A quantity slot."
  :def ((model-fragment ?MF-inst) 
	(quantity-slot ?qty-slot)))

;;; Note this probably shouldn't be defined here.  We never seem to use it
;;; as a relation.
(define-relation Action-rule (?MF-inst ?condition ?vars ?model-var ?assertion)
 "Specifies the changes caused by discontinuous changes.  Takes five arguments, MF-inst, condition, vars, model-var, assertion.
MF-inst: Model instance.
Condition: A quoted expression.  The condition to be evaluated before the changes are executed.  Mainly for the purpose of binding
           variables to be used in assertion.
vars: The list of free variables appearing in Condition.
model-var: The free variable to be used in assertion to designate the created instance.
Assertion: A quoted expression.  The assertions to be made in the new state after the change."
  :def (discontinuous-behavior-model ?MF-inst))

(define-relation Active (?MF-inst ?time-spec)
  "Maps the model instance to the time at which it became active.
  The value is known iff the behavior-model instance is active
  during at the time."
  :def (and (behavior-model ?MF-inst)
            (time-spec ?time-spec)))

(make-time-dependent 'active 2)

(define-relation Instantiated (?MF-inst ?time-spec)
 "Takes two arguments, MF-inst and time-spec.  The value is t iff the
MF-inst is instantiated at the time.  Being instantiated 
means that the instantiation condition of the model class evaluates
to true at the time."
  :def (and (model-fragment ?MF-inst)
            (time-spec ?time-spec)))

(make-time-dependent 'instantiated 2)


(define-function derivative-of (?derivative-function)
  "(= (derivative-of F1) F2) means F1(x) = dx/dt F2(x)."
  :def (and (quantity-slot ?derivative-function)))

(define-function integral-of (?integral-function)
  "(= (integral-of F1) F2) means (= (derivative-of F2) F1)"
  :def (and (quantity-slot ?integral-function)))

(define-function at (?time ?slot)
  "returns the value of the slot at the given time"
  :def (and (quantity-slot ?slot)))

(define-function user-accessible ($slot)
  "If true, means that the user can tweak the value of this slot"
  :def (or (qualitative-parameter $slot)
	   (quantity-slot $slot)))

(define-function possible-values (?slot)
  "List of the legal values that can be taken by this qualitative parameter"
  :def (qualitative-parameter ?slot))

(define-function quantity-slots (?model)
  "mapping from a model-class to list of slots that denote quantity variables.
Intended to be inherited down through subclasses (submodels)."
  :def (behavior-model ?model))

(define-function qualitative-parameters (?model)
  "mapping from a model-class to list of slots that denote non-quantitative model parameters.
Intended to be inherited down through subclasses (submodels)."
  :def (behavior-model ?model))

(define-function component-slots (?model)
  "Definitions of slots whose values are components of a model.
This slot currently only makes sense for models, not model instances.
Since its values are arbitrary lisp lists, they are quoted."
  :def (model-fragment ?model))

(define-function participant-slots (?model)
  "Definitions of slots whose values are participants in a model.
This slot currently only makes sense for models, not model instances.
Since its values are arbitrary lisp lists, they are quoted."
  :def (behavior-model ?model))

(define-function other-slots (?model)
  "Definitions of model slots for which we have no category at present.
This slot currently only makes sense for models, not model instances.
Since its values are arbitrary lisp lists, they are quoted."
  :def (model-fragment ?model))

;; Operating modes and actions

(define-function operating-modes (?model)
  "The set of operating modes relevant to instances of this class."
  :def (model-fragment ?model))

(define-function actions (?model)
  "The set of actions performed by instances of this class."
  :def (model-fragment ?model))

;; Behavior-Constraint.

(define-class Behavior-constraint ($const)
  "The class of behavior constraint structural-element-models."
  :Axiom-Def (dme-kernel-class behavior-constraint))

(define-function Constraint-expression (?const)
  "Takes one argument, Behavior-constraint.  Returns the constraint expression, which is a quoted structural-element-model."
  :def (behavior-constraint ?const))

;; Equation

(define-class Equation ($eqn)
  "The class of equation structural-element-models."
  :Axiom-Def (dme-kernel-class equation))
						       
(define-function Equation-expression (?eqn)
  "Takes one argument, Equation.  Returns the equation expression, which is a quoted structural-element-model."
  :def (equation ?eqn))

;; Quantity

(define-class Quantity ($quantity)
  "The class of quantity structural-element-models."
  :Axiom-Def (dme-kernel-class quantity))

(define-function Value (?quantity ?time-spec)
  "Takes two arguments, Quantity and Time-spec.  Returns the value of the quantity at the time."
  :def (and (quantity ?quantity) (time-spec ?time-spec)))

;; Time-spec

;; fixed an inconsitency in the KB caused by the variable being named the same as the relation.
(define-class Time-spec ($time-spec)
  "The class of time point or interval structural-element-models."
  :Axiom-Def (dme-kernel-class time-spec))

(define-class Time-point (?time-point)
  "The class of time point structural-element-models."
  :Axiom-Def (dme-kernel-class time-point)
  :Def (time-spec ?time-point))

(define-class Time-interval (?time-interval)
  "The class of time interval structural-element-models."
  :Axiom-Def (dme-kernel-class time-interval)
  :Def (time-spec ?time-interval))

(define-function previous-interval (?new-interval ?previous-interval)
  "Connects two time intervals into a temporal sequence."
  :Def (and (Time-Interval ?new-interval) (Time-Interval ?previous-interval)))

(define-function instantiation-justification (?new-instance ?sentence)
  "Records a justification for a new instance.  
  The sentence is the bound instantiation condition with a free time variable."
  :Def (Model-Fragment ?new-instance))

(define-class q-operator ($op)
  "Mathematical operators used in behavior constraints."
  :Axiom-Def (dme-kernel-class q-operator))

(define-class q-expression-operator (?op)
  "expression operator"
  :Axiom-Def (dme-kernel-class q-expression-operator)
  :def (q-operator ?op))

(define-class q-constraint-operator (?op)
  "constraint operator"
  :Axiom-Def (dme-kernel-class q-constraint-operator)
  :def (q-operator ?op))

(define-class q-mapping-operator (?op)
  "expression operator"
  :Axiom-Def (dme-kernel-class q-mapping-operator)
  :def (q-operator ?op))


(define-function partial-eval-function (?operator ?lisp-function)
  "associates with an operator a lisp function for partial evaluation of terms beginning with that operator."
  :def (q-operator ?operator))

(define-function translate-to-qsim-function (?operator ?lisp-function)
  "associates with an operator a lisp function for translating 
mathematical expressions  beginning with that operator into QSIM constraints."
  :def (q-operator ?operator))

;===============================================================================

;;; Added by JPR for graphics stuff.

 
(define-function abbreviation ($slot)
  "Abbreviation for the slot. Used when building compact variable names"
  :def (or
	 (qualitative-parameter $slot)
	 (quantity-slot $slot)
	 (other-slot $slot)))


(define-function connection-topology ($model)
  "(connection-topology 'eps)
   -> a list of connection descriptors specs denoting,
 `((connected-terminals ,from-junction-name ,to-object-terminal ,to-object-name
		             ,@edge-specs)))
  means that connections between the specified terminals and junctions in the model named EPS.
  If edge-specs are provided then they tell the window system how to draw the connection.
  If they are specified they should be of the form (<<n>> ((x1 y1) ...(xn yn))),
  where n is the number of intermediate vertices in the connection and the respective (xi yi)
  pairs are used to position the points at which the connection articulates."
)



(define-function graphical-representation ($model)
  "(graphical-representation 'eps) a plist of stuff used in graphics.")

(define-function terminal-descriptors ($model)
  "(terminal-descriptors 'ccc-component) a list of terminal descriptors for
   the model class.")

(define-function owning-model-spec ($model $spec)
  "(owning-model-spec 'solar-array-3 $spec)
   ->`(solar-array-component-three eps-4)"
)

(define-function quantity-range (?quantity-slot ?range)
  "The range of values a quantity-slot can take.  Takes two arguments,
quantity-slot and range.
quantity-slot: A quantity slot.
range: A list of two real numbers."
  :def (quantity-slot ?quantity-slot))


; function needed by the explanation facility.


(define-function activation-condition ($model-class) 
  "Takes one argument, model-class.
    The value is the activation condition for that model class if any.")

(define-function activation-condition-descriptor ($model-class) 
  "Takes one argument, model-class.
    The value is the activation condition defstruct for that model class if any
    as specified by the user.")

(define-function behavior-rules ($model-class) 
  "Takes one argument, model-class.
    The value is the quoted set of behavior-rules for the model class")

(define-function other-axioms ($model-class) 
  "Takes one argument, model-class.
    The value is the quoted set of other-axioms for the model class")

(define-function create-class-arguments ($model-class) 
  "Takes one argument, model-class.
    The value is the quoted set of create-class-arguments for the model class")

(define-function behavior-constraint-descriptors (?model-class)
  "Asserts that instances of a particular model class have a set of constraints described by the value.
  e.g. `(behavior-constraint-description rechargeable-battery
                ,(list (dme::make-behavior-constraint-descriptor
                         :Name constraint-name
                         :Constraint-Expression constraint
		         :Description behavior-constraint-description)))"
  :Axiom-Def (Behavior-model ?model-class))

(define-function articulation-axiom-descriptors (?model-class)
  "Asserts that instances of a particular model class have a set of constraints described by the value.
  e.g. `(articulation-axiom-description rechargeable-battery
                ,(list (dme::make-articulation-axiom-descriptor
                         :Name constraint-name
                         :Constraint-Expression constraint
		         :Description articulation-axiom-description)))"
  :Axiom-Def (Behavior-model ?model-class))



(define-function Action-Rule-descriptor ($model-class)
  "Contains the action rule descriptor associated with this model class if
   any as a quoted defstruct instance of the type action-descriptor.")


;; quantity slots

(define-class quantity-slot (?function)
  "The class whose instances are unary functions from BEHAVIOR-MODELs
   to quantities."
  :Axiom-Def (dme-kernel-class quantity-slot)
  :def (kif:unary-function ?function))

(define-class component-slot (?slot)
  "The class whose instances are unary functions from BEHAVIOR-MODELs
   to other models."
  :Axiom-Def (dme-kernel-class component-slot)
  :def (kif:unary-function ?slot))

(define-class participant-slot (?slot)
  "The class whose instances are unary functions from BEHAVIOR-MODELs
   to other models."
  :Axiom-Def (dme-kernel-class participant-slot)
  :def (kif:unary-function ?slot))

(define-class qualitative-parameter (?slot)
  "The class whose instances are unary functions from BEHAVIOR-MODELs
   to qualitative parameters of the model."
  :Axiom-Def (dme-kernel-class qualitative-parameter)
  :def (kif:unary-function ?slot))


(define-class time-dependent-slot (?slot)
  "The class whose instances are unary functions from BEHAVIOR-MODELs
   to qualitative parameters of the model."
  :Axiom-Def (dme-kernel-class time-dependent-slot)
  :def (kif:unary-function ?slot))

(define-class action-rule-instance (?slot)
  "The class whose instances are action rules."
  :Axiom-Def (dme-kernel-class action-rule-instance)
  :def (kif:unary-function ?slot))


(define-class other-slot (?slot)
  "The class whose instances are binary relations from BEHAVIOR-MODELs
   to other slots of the model."
  :Axiom-Def (dme-kernel-class other-slot)
  :def (kif:binary-relation ?slot))


(define-function points-of-discontinuity (?qty-slot ?point-list)
 "Specifies the possible points of discontinuity for qty-slot.   
qty-slot: A quantity slot.
point-list: A list of numbers."
  :def (quantity-slot ?qty-slot))

(define-function symbol-name-of-landmark-value-mapping ($x $y)
 "Specifies the symbolic name of a landmark value.  
  The precise definition should be supplied.  
x:
y: ")

(define-function caching-rules (?MF-class) 
  "Takes one argument, behavior-model-class.
   returns the list of caching rules associated with this class."
  :def (model-fragment ?MF-class))

; Functions that have to do with operating modes and operator actions.

(define-function Operating-Mode-class (?MF-class) 
  :def (model-fragment ?MF-class))

(define-function Operating-Mode-class-of  (?MF-class) 
  "Takes one argument, behavior-model-class.  The value is another model fragment class which is the superclass of all the 
operating mode models of mf-class."
  :def (model-fragment ?MF-class))

(define-function User-specified-new-value  (?MF-instance)
  "mf-instance is an instance of an operating action mode.
    The value is the new value specified by the user.
   We save the value as an alist of (interval value) pairs."
  :def ((ol:instance-of ?MF-instance operating-mode-model)))

(define-function model-class-to-operate-on   (?op-action)
  "Takes one argument, operator-action-model class.  The value is a structural-element-model class that the op-action 
    acts upon.  For example, (model-class-to-operate-on turn-valve) = valve."
  :def (operator-action-model ?op-action))

(define-function slot-to-operate-on (?op-action)
  "Takes one argument, operator-action-model class.  The value is a slot that the op-action acts     For example, (model-class-to-operate-on turn-valve) = valve-open-p."
  :def (operator-action-model ?op-action))



;;;; Procedures

(define-class procedure ($procedure)
  "Operator procedures represented as a graph."
  :Axiom-Def (dme-kernel-class procedure))

(put-function-value 'procedure 'it-is-* "an operator procedure"
		    *background-theory*)

(define-function root-node (?procedure)
  "Takes one argument, procedure instance.  The value is an instance of procedure-step.
    For example, (root-node loss-of-verniers) = lov-n1"
  :def (ol:instance-of ?procedure procedure))

(define-class procedure-step ($step)
  "One step in an operator procedure.  It is a node in a ooperator procedure graph."
  :Axiom-Def (dme-kernel-class procedure-step))

(put-function-value 'procedure-step  'it-is-* "an operator procedure step"
		    *background-theory*)

(define-class action-step (?step)
  "Operator procedure steps involving one or more operator actions."
  :Axiom-Def (dme-kernel-class action-step)
  :Def (procedure-step ?step))

(put-function-value 'action-step  'it-is-* "an action step"
		    *background-theory*)

(define-class wait-step (?step)
  "Operator procedure steps involving a finite time period of no-op (waiting period)"
  :Axiom-Def (dme-kernel-class wait-step)
  :Def (procedure-step ?step))

(put-function-value 'wait-step  'it-is-* "a waiting step"
		    *background-theory*)

(define-class test-step (?step)
  "Operator procedure steps for testing some condition and branching."
  :Axiom-Def (dme-kernel-class test-step)
  :Def (procedure-step ?step))

(put-function-value 'test-step  'it-is-* "a test step"
		    *background-theory*)

(dme::let ((*model-fragment-theory* *background-theory*))
  ;;; Something strange going on here.
;	     (lisp::if (lisp::typep ol:*current-theory* 'oli::epikit-theory)
;		       (oli::epikit-theory ol:*current-theory*)
;		       *background-theory*)))
  (define-model operating-mode-model 
    :it-is-*
    "The class of all model fragments that denote behavior of a component.
By convention, devices will have a subclass of this class whose immediate
subclasses are all of the behavior modes of a given device,
i.e. Battery-Operating-modes is a superclass of
the overcharged, undercharged etc. modes."
    :type (behavior-model)
    :it-is-* "an operating mode"
    :Create-Class-Arguments
      (:Axiom-Def (dme-kernel-class operating-mode-model))))


(define-function unit-of-measure ($quantity)
  "The unit in which we measure the quantity.")

(define-quantity temperature
  :It-Is-* "The quantity denoting temperature"
  :Unit-Of-Measure kelvin
  :Create-Class-Arguments (:Axiom-Def (dme-kernel-class temperature)))

(define-quantity charge
  :It-Is-* "The quantity denoting charge"
  :Unit-Of-Measure Coulomb
  :Create-Class-Arguments (:Axiom-Def (dme-kernel-class charge)))

(define-quantity voltage
  :It-Is-* "The quantity denoting voltage"
  :Unit-Of-Measure Volt
  :Create-Class-Arguments (:Axiom-Def (dme-kernel-class voltage)))

(define-quantity time
  :It-Is-* "The quantity denoting time"
  :Unit-Of-Measure Second
  :Create-Class-Arguments (:Axiom-Def (dme-kernel-class time)))

(define-quantity resistance
  :It-Is-* "The quantity denoting resistance"
  :Unit-Of-Measure Ohm
  :Create-Class-Arguments (:Axiom-Def (dme-kernel-class resistance)))

(define-quantity intensity
  :It-Is-* "The quantity denoting intensity"
  :Unit-Of-Measure ampere ;;; Is this right?
  :Create-Class-Arguments (:Axiom-Def (dme-kernel-class intensity)))

;;; !!!!!! Obsolete
(define-function meter-specs ($spec)
  "(meter-specs 'eps)
   ->`((battery-component stored-charge 10 20 t) ...)
  Values are of the form:
  (metered-component metered-quantity delta-x delta-y large-p)
  Metered-component could be a (terminal component) pair.
  Metered-Quantity is the name of the quantity.
  
  Delta-X and Delta-Y are the offsets from the bottom right
  corner of the metered component.
  Large-p is true if this specification is for the
  large display.
  "
)

;;; !!!!!! Obsolete
(define-function display-position-data ($display-data)
  "(display-position-data '(junction-k2-w2 electrical-junction)) with a value of '((42 100)) means put an icon
   for k2-w2, which is an electrical junction at position (42, 100) on the screen.  Any extra data
   in the position spec, e.g. (250 203 :T-1-Position :Top ...) is passed through to the item
   when it is created as its init-plist.  In this case it means attach the terminal t-1-position
  to the top of the icon."
)

;;; !!!!!! Obsolete
(define-function large-display-position-data ($display-data)
  "This relation is used when a window is said to be large.
  (display-position-data '(junction-k2-w2 electrical-junction)) with a value = '((42 100)) means put the icon
   for k2-w2, which is an electrical junction at position (42, 100) on the screen.  Any extra data
   in the position spec, e.g. (250 203 :T-1-Position :Top ...) is passed through to the item
   when it is created as its init-plist.  In this case it means attach the terminal t-1-position
  to the top of the icon."
)

;==============================================================================

#+CML
(define-class cml-user::thing (?x)
  "The top level class for all cml models."
  :Axiom-Def (dme-kernel-class cml-user::thing)
  :Def (model-fragment ?x))

#+CML
(put-function-value 'cml-user::thing 'it-is-* "a modeled thing"
		    *background-theory*)


;;; Don't delete this form-feed char.

;;; 
;;; Enable GNU Emacs version numbers.  Don't mess with these
;;; lines, or we'll find you and we'll kill you...
;;; 
;;; Local Variables:
;;; mode: lisp
;;; version-control: t  
;;; End:

This Lisp-to-HTML translation was brought to you by
François Gerbaux and Tom Gruber