Jump to content

Recommended Posts

  • Seeq Team

Background

In this Use Case, a user created a condition to identify when the compressor is running.  During each Compressor Running capsule, the compressor operates in a variety of modes.  The user would like a summary of the modes of operation for each capsule in the form of a new signal that reports all modes for each capsule (i.e. Transition;Stage 1;Transition;Stage 2;Transition, Stage 1;Transition).

image.png

Method

1. The first step is to resample the string value to only have data points at the value changes.  It's possible the signal is already sampled this way, but if it is not, use the following Formula syntax to create a "compressed" signal:

$stringSignal.tocondition().setMaximumDuration(3d).transformToSamples($capsule -> 
    sample($capsule.getStart(), 
        $capsule.getProperty('Value')), 4d)
image.png

2.  Now, you can create a signal that concatenates the string values during each capsule.  This is achieved using the following Formula syntax:
$compressorRunning.setmaximumduration(10d).transformToSamples($cap->
   sample(
       $cap.getStart(),
       $compressedStringSignal.toGroup($cap).reduce("", ($s, $capsule) -> 
                        $s + $capsule.getvalue())), 7d).toStep()

image.png

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...