A terminal flowchart element is represented by an oval or a rectangle with rounded corners. It indicates either the beginning or the end of an algorithm. They usually contain the work start , stop , or end . Terminal flowchart elements may contain more descriptive phrases
A
process
flowchart element is represented by a rectangle. It indicates an operation that changes the
state
of algorithm. It may change to value, definition, form or location of data associated with the algorithm.
This flowchart indicates a simple algorithm that
assigns
the value of 5 to a variable in the workspace of the algorithm labeled
x
. In the MATLAB programming language we use the assignment operator
=
to implement the algorithm such as
> x = 5
On a piece of paper create your own flowchart that assigns the value of 3.1415926 to the variable
PI
In most programs the value of $\pi$ never changes. We call such a variable a
literal
. We created a flowchart for assigning the value of $\pi$ rounded to eight digits to the literal
PI
.
The condition flowchart element determines which of two paths the algorithm may take. The operation of a condition answers a yes/no or true/false question. A decision flowchart element is usually depicted with a rhombus. The path of the algorithm is determined by the value of result.
A simple decision statement in the MATLAB language is an
if
statement. The
keyword
is followed by an expression that results in the value
false
(0) or
true
(1). The path taken by the algorithm in the flowchart depends on this value. For example, to make sure that the value assigned to variable
x
is greater than or equal to zero one might implement the algorithm
Consider the decision flowchart above. The decision results in two separate
flows of execution
; one assigns the value of
x
to
-x
, and the other does nothing. Both flows of execution join together after each
subflow
or
subprocess
ends.
The separate flows of execution do not always join!
When they do one uses a flowchart element to indicate this joining of one
or more
flows of execution.
The one page connector flowchart element joins several paths of execution . It is represented graphically by a small circle. The size of the circle depends on the choice of the author.
Create a flowchart that uses the decision
x > MAXIMUM_VALUE
and assigns variable
x
to the value
MAXIMUM_VALUE
if it has a larger value.
When one or paths of execution reside on different pages of your document us an off-page connector flowchart element to join them. For example, a long execution path may not fit on a single page of your document. You must join the single execution path from one page to the next with an off-page connector element. Graphically, the off-page connector looks like a home plate -shaped pentagon.
A comment or annotation flowchart element does not label an action or path of execution. Instead it allows the author to include addition information about another flowchart element or execution path.
The predefined process flowchart element indicates the name of an algorithm implemented in another flowchart. One uses this flowchart element to indicate that the algorithm uses another algorithm to accomplish a complex task. This simplifies algorithms and reuses existing algorithms to create more complex tasks.
For example we may call builtin MATLAB function
sqrt
to compute the square root of the descriminant of a quadratic polynomial.
Create the flowchart for a subprocess that uses the builtin MATLAB function reshape to create a $4\times 4$ matrix of random integers between one and forty two.
randi
to create your matrix
A
An Input or Output flowchart element indicates that information is retrieved or emitted to a temporary or permanent medium. Input and output processes are genericall referred to as I/O processes. An I/O process may read or write to a file, write to the screen, read text from the keyboard, or emit strings over an internet connection. I/O flowchart elements are depicted using a parallelogram.
Creative Commons Attribution-NonCommercial-ShareAlike 4.0
Attribution
You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
Noncommercial
You may not use the material for commercial purposes.
Share Alike
You are free to share, copy and redistribute the material in any medium or format. If you adapt, remix, transform, or build upon the material, you must distribute your contributions under the
same license
as the original.