Pseudo Flow Ref
Pseudo Flow Ref
Operation
Flowchart Symbol
Pseudocode
Start MyFunc
Process/Assignment
Input/Output
Input [stream] x, y
z = input('Enter value: '); disp(['Result = ' result]); fprintf(outfile, 'x = %5.2f', x);
F
Selection
x = y? T
if x == y else end
J=0
Counter Controlled Loop
F J <= 10
J=J +1 T
1
do/while z x/y
Structured Repetition
y>0 F T
while block if cond break block next step home(x,y) z myfunc(x) -ormyfunc(x) z
Function Call
home(x,y) or z myfunc(x)
Notes and Comments: The flowchart, pseudocode and Matlab examples do not generally correspond (i.e., they dont necessarily represent the same action). Use indentation to show structure in pseudocode and Matlab source code. cond is a logical condition (a Boolean expression). next step mans the next step in the algorithm. In Matlab, this can generally be any statement. source and dest means any open data source or destination of the appropriate type. Some coding styles prohibit General Repetition structures. If general repetition is used, there should only be one way in and one way out.