Reference · Flowchart symbols
Flowchart predefined process symbol: the rectangle with double sides
In short
The predefined process symbol is a rectangle with a second vertical line inside each side. It stands for a named step whose details are defined somewhere else, such as a subroutine, a function, a module or another flowchart. In the chart it counts as one step, with one line in and one line out. It is also called the subroutine symbol or the subprocess symbol.
Updated · by the ChartCraft team · part of the flowchart symbols reference
What is the predefined process symbol in a flowchart?
It is the process rectangle with double vertical sides. ISO 5807 defines it as "a named process consisting of one or more operations or program steps that are specified elsewhere, for example, a subroutine, a module". The label is the name of that process, and the reader finds the detail under the same name.
| Symbol | Name | Meaning | Example label |
|---|---|---|---|
| Predefined process | A named routine whose steps are defined elsewhere | Calculate tax | |
| Process | A step fully described by its own label | Add tax to total | |
| Terminator of the sub-flow | Start and end of the chart that defines the routine | Calculate tax, Return | |
| Decision (not a process) | A question that branches the flow | Tax exempt? |
Mermaid writes it with double square brackets: A[[Calculate tax]].
What is the difference between a process and a predefined process?
A process is complete as written: its label says everything the step does. A predefined process is a reference: its label names a routine, and the steps of that routine are drawn or written somewhere else.
| Process | Predefined process | |
|---|---|---|
| Shape | Plain rectangle | Rectangle with double vertical sides |
| What the label is | The action itself | The name of a routine |
| Where the detail is | Nowhere else: the label is the detail | In another flowchart, a function or a written procedure |
| Example | Add tax to total | Calculate tax |
| Mermaid | A[Check stock] | A[[Calculate tax]] |
When should you use a predefined process symbol?
Use it when a step is really a routine with steps of its own, and those steps are documented somewhere the reader can find them.
- The same steps appear in several charts. Draw them once and refer to them by name.
- A step is too detailed for this level. The main chart stays short and the detail moves to its own chart.
- The step already exists. A library function, an API call or a written procedure does not need to be redrawn.
- Not for a single action. If the label says all there is to say, use a plain process rectangle.
Where is a predefined process defined?
Somewhere other than the chart it appears on, under the same name. ISO 5807 says "specified elsewhere" without saying where. ANSI X3.5 is stricter: "Elsewhere means not this set of flowcharts". For a step whose detail is drawn in the same set of charts, ANSI describes a different marking, a stripe across the top of the symbol with a reference to the detailed chart. IBM's flowcharting guide makes the same split and gives a library subroutine as its example of a predefined process. If your team follows ANSI, keep the double-sided rectangle for routines documented outside the chart set.
How do you draw the flowchart of a predefined process?
Draw it as a chart of its own. Start it with a terminator that carries the same name as the predefined process box, so the reader can match the two, and end it with a terminator labelled Return or End. The terminator guide shows how start and end symbols are labelled.
What does a flowchart with predefined process symbols look like?
In this checkout flow, "Calculate tax" and "Calculate shipping" are predefined processes: each is a routine with its own rules, drawn in its own chart. The other steps are plain processes because their labels say all they do.
flowchart TD
S([Order placed]) --> A[Add up item prices]
A --> T[[Calculate tax]]
T --> SH[[Calculate shipping]]
SH --> P[Charge card]
P --> X([Order confirmed])
How do you write a predefined process in Mermaid?
Use double square brackets: A[[Calculate tax]]. Mermaid's documentation calls this the subroutine shape. From Mermaid 11.3.0 the same shape can also be written by name: A@{ shape: subproc, label: "Calculate tax" }.
What do real flowcharts with these symbols look like?
Live diagrams from the public ChartCraft gallery, each generated from a plain-English description. Open one to see the prompt that produced it.
Questions
What is a predefined process in a flowchart?
A named step whose details are defined somewhere else, such as a subroutine, a function or another flowchart. It is drawn as a rectangle with double vertical sides.
What does the predefined process symbol look like?
A rectangle with a second vertical line just inside its left and right sides.
What is the difference between a process and a predefined process?
A process is fully described by its label. A predefined process names a routine whose steps are drawn or written elsewhere.
Is a predefined process the same as a subroutine?
A subroutine is the most common example. ISO 5807 lists a subroutine and a module as examples of a predefined process, and Mermaid calls the same shape a subroutine.
When should you use a predefined process symbol?
When a step is a routine with steps of its own that are documented elsewhere: steps shared by several charts, detail that belongs at a lower level, or an existing function or procedure.
Where is a predefined process defined?
In another flowchart or document, under the same name as the box. ANSI X3.5 says elsewhere means outside the current set of flowcharts.
How do you write a predefined process in Mermaid?
With double square brackets, for example A[[Calculate tax]].