Smart input func; integrators; PArkinson's

[From Bill Powers (950701.0815 MDT)]

Avery Andrews (950701.1130) --

RE: smart input functions

     Whether it's doable or not would depend a lot on the specific
     nature of what's being done. We might for example have a
     perception of `velocity' that was normally determined by visual
     flow of the ground, but if this info is unavailable, computed from
     the RPMs of the propeller: the RPM -> velocity function would be
     calibrated whenever the ground was visible, but used when it

The problem is still how to detect when the visual flow information is
available (so you don't use the less accurate perception). The more
intelligence you try to put into a single perceptual function, the more
complex the model gets, and the more special-purpose.

As you say, what needs to be done depends a lot on the specific nature
of what's being done. If we tried to devise an input function with the
required intelligence for each variable that may be controlled, under
each circumstance that may come up, we would end up with tremendous
duplication of functions, and no recognizeable overall organization.

The point of the hierarchical model is to pick out of the vast variety
of controllable variables features that are common to all circumstances,
and use highly specialized perceptual functions of simple nature
(relatively simple). In this way we can imagine higher systems that are
_never_ concerned with lower-level details, and are _always_ concerned
with controlling a single kind of aspect of the perceptual world. A
system that perceives _only_ a single logical function of its input
signals and outputs _only_ another signal representing the value of the
function does not have to be concerned with "circumstances." What we
call circumstances breaks down into a collection of variables, each
representing one dimension of the world at one level of abstraction. And
for each variable there would be a simple perceptual function that
reports the state of that variable in its one possible dimension of

The intelligence that you are trying to pack into a single perceptual
function would therefore be distributed among many perceptual functions
at many levels, and each of these would be associated with a control
system that controls the world in a single dimension. Moreover, each of
these control systems might be used (by systems of higher level) in many
different contexts, so it is "reusable" without physical duplication of

In your example, you describe two different control processes:
controlling visual flow and controlling propeller speed. The two control
systems involved would have to have different characteristics, because
the dynamical relationships between throttle setting and the controlled
variable would be entirely different. But you also imply that these two
control systems are used for controlling the same variable, velocity.
Velocity is neither visual flow nor propeller speed; it is something
that is related to these variables but not identical to them. In order
to control velocity, some system must perceive visual flow and propeller
speed as the state of another variable, velocity through space. So there
must be another perceptual function that takes as input either visual
flow or propeller speed and outputs a signal that is identified as a
velocity signal. There must also be still another system that detects
the flow signal and the propeller speed signal, looks for a logical
relationship between them, and selects which one is to be used (with
appropriate weighting) as the input to the velocity control system,
gating out the other one. The criteria for the selection depend on still
other perceptual variables and goals.

The main problem in modeling is to get the model to do what you want it
to do without injecting your own knowledge into it. Whatever the model
needs to know must be built into the model -- for example, the fact that
controlling visual flow and propeller speed affect another variable,
velocity in space. The relationship may be self-evident to you, but you
are not the one who matters. THE MODEL must somehow be equipped to
recognize this relationship, so it can know that controlling some
variable that has nothing to do with velocity will end up as a means of
controlling velocity.

In the hierarchical model, each level consists of a set of highly-
specialized single-purpose control systems. Together, however, all the
systems at a given level comprise a general-purpose kit of control
systems that can control the world, at one level of representation, in
any of the dimensions it is perceived to have at that level. Higher
systems can then use this kit of lower-level systems in all different
circumstances as a means of controlling more abstract aspects of the
perceptual world, without having to modify any of the lower-level
systems. Once there are control systems available for varying the
configuration of an arm and hand in all the potential degrees of
freedom, the higher systems do not have to be concerned with how this is
accomplished; they simply manipulate the reference signals and the arm
and hand behave, magically, as required. Once there is a control system
that can use the throttle setting to control visual flow, and another
one that can use throttle setting to control propeller speed, those
specific control processes are no longer the concern of higher systems.
All the higher systems have to do is decide which lower control system
to use -- which reference signal to vary. And the higher systems don't
have to be concerned about the origin of the velocity signal. They
simply vary whichever lower-level reference signal will have the
required effect on the velocity signal.

When you unpack the intelligence needed to carry out any control
process, you end up with a lot of different detailed control systems at
different levels. But the great advantage of doing this is that a few
relatively simple control systems can accomplish, without change of
organization, what would otherwise require a whole new collection of
complex functions for each different task done in each different


     On another topic, what's the relation between putting an integral
     component into a controller and using slowing? Intuitively, it
     seems to me like you might get similar improvements in stability
     without loss of precision of control by:
       a) adding a slower
       b) reducing the proportional component, and adding an integral

A slowing function is an integrator with a leak. It is equivalent to

y = y + a*x*dt - b*y*dt

If you collect the terms in our standard representation of a slowing
function, you will find exactly the form above.

The "y + a*x*dt" part is a pure integrator, and the " - b*y*dt" is the
leak that continually reduces y by an amount proportional to y.

Without the leak, y will simply continue to change as long as x is
nonzero. For a constant positive x, y will cease to increase when

  a*x = b*y, or

y = (a/b)*x.

So the above program step is equivalent to a proportional amplifier with
a gain of a/b and a time constant of 1/b.

There's no reason why we couldn't have a pure integrator operating in
addition to a leaky integrator and a proportional component. The exact
type of output function we use depends a great deal on the nature of the
external part of the loop, the feedback function. What you have to worry
about is keeping the feedback negative at all frequencies where the loop
gain is still greater than 1. If there is an integrator in the feedback
function, you can't have another integrator in the output function,
because that would turn the whole system into an oscillator (a pure
integrator causes a phase shift of exactly 90 degrees at all
frequencies, so two integrators in a row produce a phase shift of 180
degrees, reversing the sign of feedback).

We have generally assumed that the feedback function is a simple
proportionality, which is how we get away with using an integrating
output function. In effect, we're assuming that lower-level control
systems make the feedback function look like a proportional
relationship, or near enough to it over the bandwidth of control.
However, a real engineering approach to building a model would require
looking in detail at the dynamics of the transfer functions, as I did in
Little Man v. 2, where the environmental feedback function is anything
but a pure constant of proportionality -- it actually involves two time-
integrations as well as nonlinear dynamical interactions among the
degrees of freedom.

In that model, the hierarchical approach was all that made a simple
model possible. By starting with control of acceleration, then adding
control of velocity and then position, the model manages to keep the
feedback function for each system looking nearly like a constant of
proportionality, so a leaky integrator works just fine as an output
function at each level.
As to the robot cars, it sounds like fun but also like a tremendous
time-consumer. Don't know if I want to get embroiled in that, what with
other projects going on.
John Anderson --

Sorry to have put off replying to your post about Parkinson's Disease. I
think your strategy of working from the periphery inward is just right.
I can supply a plausible and apparently anatomically correct model for
the proprioceptive control systems of an arm operating with three
degrees of freedom; if you want to expand it beyond what I have done,
please feel free. In this model all the parameters are user-adjustable
while it's running, so you can try to reproduce various kinds of
instabilities. I suspect you would want to model some higher-level
control systems to get to the kinds of low-frequency oscillations seen
in Parkinson's. I'll be glad to help out as far as I can, but eventually
you'll want the services of a real control-system engineer.
Best to all,

Bill P.

[Avery Andrews 950705.1019 Eastern Oz Time]
(Bill Powers (950701.0815 MDT))

>The problem is still how to detect when the visual flow information is
>available (so you don't use the less accurate perception).

My guess about this is that visual flow info is present when and only
when there is info about edges available, and you can also tell wether
this info is complete on the basis of wether the edges are mapped onto
themselves by the appropriate transformations (the ones induced in
the visual field by movements). Eg. if your only edges form two strips
on either side of you, converging on some point in the distance, this
edge-display tells you nothing about whether you're going forward or
backward, but it does tell you that youre not going up or down, or to
the right or the left.

The rest of the stuff will require some thought (and time, sigh)