Algorithm Design defines when and how the execution transitions from one Step to the next. Each Step contains an Algorithm — a sequence of Conditions that must be fulfilled before the process can move on.
💡 Think of it this way: Process Design defines what the valve positions are. Algorithm Design defines when to move from one set of positions to the next — based on sensor readings, timer expirations, operator confirmations, or any combination of these.
📋 Overview
|
Concept |
Description |
|---|---|
|
Algorithm |
A sequence of conditions attached to a Step, defining the transition logic |
|
Condition |
An atomic decision point in the algorithm (e.g., wait for a sensor reading, timer, or operator input) |
|
SFC Editor |
The visual Sequential Function Chart editor for managing conditions — see SFC Editor (GRAFCET) |
✅ Key relationship: Each Step has exactly one Algorithm, and each Algorithm belongs to exactly one Step.
🎛️ Accessing the Condition Editor
To open the Condition Editor, go to the Condition panel in the Module Ribbon and click the Edit button. A window opens where you can create, view, and modify conditions for the current step.
At the top left corner of the editor you will see:
|
Indicator |
Color |
Meaning |
|---|---|---|
|
Process name |
🟡 Yellow |
The process you are currently working in |
|
Step number/name |
🔵 Blue |
The step this condition belongs to |
|
Condition number/name |
🟢 Green |
The currently selected condition within the step |
💡 Tip: Click on the process, step, or condition indicator to open a dropdown and quickly switch to a different process, step, or condition.
🔧 Condition Types
Each condition has a Type that determines its behavior and which fields are available. You select the type from the icons at the top of the Condition Editor window.
|
Type |
Symbol |
Description |
Key Fields |
|---|---|---|---|
|
Transition |
⬡ |
Transitions to another step when the condition is fulfilled. This is the most common type. |
Description, Prompt, Condition, Success Transition |
|
Continuous Action |
A |
Executes an action continuously while the step is active. |
Description, Prompt, Success Action |
|
Cont. Action + Condition |
ᴶᶜ A |
Executes the action only while the condition is true. |
Description, Prompt, Condition, Success Action |
|
Stored on Activation |
↑ A |
Executes the action once when the step first becomes active (rising edge). |
Description, Prompt, Success Action |
|
Stored on Deactivation |
↓ A |
Executes the action once right before the step becomes inactive (falling edge). |
Description, Prompt, Success Action |
|
Stored on Event |
ᵐᴱ A |
Executes the action once when a specific event occurs during the step. |
Description, Prompt, Condition, Success Action |
|
Custom |
⭐ |
A fully customizable condition layout. All fields are available. |
Description, Prompt, Condition, Success Action, Fail Action, Success Transition, Fail Transition |
📝 Condition Fields
Depending on the selected condition type, different fields are available in the editor:
|
Field |
Icon |
Description |
Available For |
|---|---|---|---|
|
Description |
📖 |
A human-readable explanation of the condition. This text also becomes the name of the condition. |
All types |
|
Prompt |
🖥️ |
Text or Dialog shown to the operator during production. |
All types |
|
Condition |
🧮 |
The formal expression that defines what must be true. Use the Condition Builder for guided construction. |
Transition, Cont. Action + Condition, Stored on Event, Custom |
|
Success Action |
⚡ |
The action performed when the condition succeeds. Use the Action Builder for guided construction. |
Continuous Action, Cont. Action + Condition, Stored on Activation, Stored on Deactivation, Stored on Event, Custom |
|
Fail Action |
⚡ |
The action performed when the condition fails. |
Custom |
|
Success Transition |
➡️ |
The step to transition to when the condition is met. Uses a visual Transition Phase Picker. |
Transition, Custom |
|
Fail Transition |
➡️ |
The step to transition to when the condition fails. Only available for Custom type. |
Custom |
💡 Tip: The Condition and Action fields support formal expressions. Click the builder icon to the right of each field to open the Condition Builder or Action Builder for guided expression construction.
🎯 Transition Phase Picker
When editing Transition or Custom condition types, the Success Transition and Fail Transition fields use a visual phase picker instead of freeform text entry.
The picker displays a scrollable list of checkboxes — one for each step in the current process. Check one or more steps to set the transition targets. Multiple selections enable fork transitions.
|
Feature |
Details |
|---|---|
|
Success Picker |
Green accent color — used for the Success Transition field |
|
Fail Picker |
Rose/pink accent color — used for the Fail Transition field |
|
Summary bar |
Displays the count of selected steps and the serialized transition text |
|
Excluded step |
The step currently being edited is automatically excluded from the list |
🖥️ Using the Prompt Field with Dialogs
The Prompt field is used to show information or collect input from the operator during production. You can write plain text or reference a Dialog for structured operator interaction.
Inserting a Dialog into the Prompt
-
In the Prompt field, click the arrows icon on the right side
-
A window opens showing all available Dialogs
-
Click the + button to create a new dialog
-
In the Dialog Editor, you see a live preview on the right. On the left side, you can drag and drop control types: Button, CheckBox, RadioButton, TextInput, NumericInput, FloatInput
-
You can also use the built-in AI feature to generate a dialog layout automatically
-
Drag and drop controls to reorder them, or drag to the trash to remove. Click directly on text labels to edit them
-
Close the Dialog Editor when finished
Managing Dialogs
-
Right-click on a dialog to access options: Edit, Duplicate, or Remove
-
When you click a dialog to select it, the dialog name is inserted into the Prompt field
-
The selected dialog appears as a preview on the right side of the Prompt field
-
Click the dialog preview to reopen the Dialog Editor and make changes
📖 For more details on creating and managing dialogs, see the Dialog page.
🔨 Condition Editor Toolbar
At the top of the Condition Editor window, you have buttons to organize your conditions:
|
Button |
Description |
|---|---|
|
➕ Add |
Creates a new condition in the current step |
|
📋 Duplicate |
Duplicates the currently selected condition. Expand for options: Duplicate in current Step, or Select Steps to Duplicate to |
|
🗑️ Delete |
Removes the currently selected condition |
|
🖐️⬆ Move Up |
Moves the selected condition up in the condition order |
|
🖐️⬇ Move Down |
Moves the selected condition down in the condition order |
💡 Tip: The order of conditions matters — they define the sequence in which conditions are evaluated within a step.
Custom Fields
You can add custom fields to conditions for each project. This allows you to tailor the condition form to your specific documentation needs.
🧭 Navigating Conditions from the Ribbon
The Module Ribbon Condition panel provides quick access to conditions without opening the editor.
Step Navigation
In the Steps area of the ribbon, the Previous and Next buttons let you navigate through steps. Expand the arrows to navigate through the chain of conditions — following transitions forward and backward.
📐 Algorithm Frame on the P&ID
If you want to see condition details directly on the P&ID drawing, you can insert an Algorithm Frame:
-
In the Module Ribbon, click Data to expand the dropdown
-
Click Headers and Notes
-
Click Algorithm Frame
-
Click on a location on your P&ID to place the frame
-
Choose a base point to scale the size, then click again to confirm
The Algorithm Frame displays condition details including: Condition number, Type, Description, Condition expression, Prompt, Success/Fail Action, and Success/Fail Transition.
💡 Tip: When you click on different conditions in the ribbon, the Algorithm Frame automatically updates to show the selected condition's details.
📊 SFC Editor (Sequential Function Chart)
The SFC Editor (GRAFCET) provides a visual flowchart view of the algorithm. Everything you do in the SFC Editor automatically updates the steps and conditions, and vice versa.
📖 Workflows
How to Create a Transition Condition
-
Open the Condition Editor from the Module Ribbon → Condition panel → Edit
-
Use the top-left indicators to select the correct Process and Step
-
Click the ➕ Add button to create a new condition
-
Select the Transition type
-
Enter a Description — this becomes the condition's name
-
In the Condition field, enter the expression. Use the Condition Builder for guided construction
-
In the Success Transition field, specify which step to go to
-
The condition is automatically saved
How to Create a Continuous Monitoring Condition
-
Open the Condition Editor and navigate to the desired step
-
Add a new condition and select Continuous Action type
-
In the Success Action field, enter the assignment
-
This will continuously execute the action for the duration of the step
🏭 Example: CIP Caustic Wash Algorithm
Here is a typical algorithm for the Caustic Wash step in a CIP process:
|
# |
Type |
Description |
Condition |
Success Action / Transition |
|---|---|---|---|---|
|
1 |
Stored on Activation |
Record batch start |
— |
Store batch ID and timestamp |
|
2 |
Continuous Action |
Monitor temperature |
— |
|
|
3 |
Transition |
Wait for target temperature |
|
→ Circulation step |
|
4 |
Cont. Action + Condition |
Boost heater if temp drops |
|
Increase heater power |
|
5 |
Stored on Deactivation |
Record final temperature |
— |
|
This example demonstrates multiple condition types working together within a single step, which is common in pharmaceutical process design.
🔗 Related Pages
-
📐 Process Design — Creating processes and steps
-
SFC Editor (GRAFCET) — Visual Sequential Function Chart editor
-
Build Condition Field — Condition Builder guide
-
Build Action Field — Action Builder guide
-
💬 Dialog — Reusable operator interaction templates
-
Algorithm Tracker — Track individual condition field values on the P&ID
-
Intelligent Suggestions — Auto-complete in condition fields
-
Module Ribbon — Conditions panel details
-
📋 Module Data — All module-level data definitions