Tip:
Highlight text to annotate it
X
Section 10.0, PI
Performance Equations. PI
Performance Equations is a, well, it's a, it's a
system, subsystem -- and it kind of looks like an interface --
that is designed to execute real-time calculations
and these calculations can either be triggered by a calendar
or event triggering, meaning when a new
Snapshot comes in, we can trigger a calculation.
It can use any number of tags in the, in the
equation, including other Performance Equation tags.
So, there's no limitation on, you know, using
other PI -- types of PI tags. It does use
a PI tag to store the results. And, this is a great
benefit because, now, it means that everybody in the organization
can access the same calculation. In fact,
that's probably one of the best criteria
to use to decide whether to do a Performance
Equation Calculation vs a
calculation that's simply done by retrieving data
from PI into Excel, and then doing this in Excel.
So, it, it, the, the great
advantage of doing this centrally, of course, you know,
everybody can look at the same data.
Typically, what we see is, you know, if, if four people
show up at a meeting with some averages they've done using raw
data, well, you know, the four of them have different
approaches for how to handle missing data. So, the first
half an hour is spent arguing over whose averages or
totalizations are correct. So, it's much, much better if,
again, you, everybody can access the very same
calculations. And, of course, it does contain a
rich library of functions. These are functions we've developed over
the years. Now, you never hear,
you know, library functions, and syntax, and all that.
You know, obviously, this, this is some kind of a,
an Expression Syntax. And I know, when I'm in
a class like this, I like to know immediately, okay, where
is the definition of this Expression Syntax?
Well, you can find that if you go into the "PI Server
Applications User Guide." Again, you can find that for
download from our website. If you go there --
and let me jump to Page 45 -- you can
see, this is a whole chapter on Performance Equation Syntax
and the Function Reference. So, we describe
the syntax used by Performance Equation. You know, what,
what do we do to express strings,
and Digitals. What Operands do we support?
And what functions
do we use? So, you'll see a whole list
of the functions available if you go down
through this book. And, we'll discuss some of those functions later on.
Now, as I mentioned,
this is a, this is a Subsystem in PI, but
you may notice that this looks and acts an awful
lot like an interface. I mean, for example, take a look
at the file called pipeschd.bat.
Let's actually take a look at it. It's in the PI\\bin
directory, and you'll notice it is
amazingly similar to the
traditional PI Interface batch files. So, if we go
into PI\\bin -- and, by the way, this is
about the only thing in PI\\bin
that you will ever edit, 'cause normally you'd find binaries
there -- but if we look at this, see,
pipeschd.bat, it is where we specify
the Point Source for Performance Equations.
We specify the host where we're sending data, and
then we specify the Scan Classes. Let me to go to --
get rid of word wrap. There we go. This is a one-minute
Scan Class, a two-minute Scan Class,
and a -- this is a case, that last one was
a 30-second Scan Class.
So, as you can see, it's, it looks a lot like a
regular interface.
In fact, you know, the Scan Classes are exactly the same. For example,
this would do an 8-hour period with a 7-hour
offset. You'll
also find that Performance Equations -- it even writes
messages to the same Message Log. So, if you go into the
pipc\\dat directory, and look for
pipc.log, you'll actually find messages
written by the Performance Equation Generator.
So, it's not, it's got not the most
full-featured equation, you know, engine that we have.
We do have something called ACE, the Advanced Computing
Engine. But, the benefit of Performance Equations is,
well, it's free. It comes with the PI Server. And it
is very robust. We've seen people do ten --
up to ten thousand calculations a second using
this, although it is not very
full-featured with regard to syntax. I mean, for example, you can't even
add comments to your equations. So,
that's, in a nutshell, how Performance Equations works.