# Calculating Cycle Run Length and Comparing Equipment Cycles

## Recommended Posts

• Seeq Team

I have a piece of equipment that regularly goes through cycles and I want to compare the cycles.  In this case I know the exact date and time of the equipment runs so I have used the Custom Condition tool to specify my Previous Run and Current Run.  Custom Condition allows you to enter dates for the condition you are interested in.  This can also be done in formula.

To create the condition for my Next Run I used Seeq's formula because this run is currently on going and I do not know the end date. This approach allows me to specify that this condition end at now.

```condition(2d,
capsule('2020-06-01T17:48Z', now()))```

Now that I have defined my Previous, Current and Next runs I want to calculate the run time of each of those periods. I can do this in Seeq's formula tool using the time since function.  This will allow me to create a signal whose value is the time since the start time of a condition.  This signal will end at the end of the condition.  In this case my time counter will be in hours, if you wanted it in days instead you would change the 1h to 1d.

`timeSince(\$condition, 1h)`

I duplicated this formula three times for my previous, current and next runs.  Remember, you can always duplicate a formula by clicking the "i" by item properties.   You can compare the run lengths of the 3 runs by putting them on the same lane and same axis. You'll noticed my Next Run has just started so the time since for it is much smaller.

Lastly, you can switch to capsule time view to compare the run length as well as different signals over the run.  In this case we are looking at the temperature of each run as well as the run length. You could imagine using this approach to monitor heat transfer coefficients, reactor temperature, reactor conversion, or % sulfur removed.

• 1