How to create an algorithm: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 329: | Line 329: | ||
'''<nowiki>{{familytree/start |summary=Sample 7}} | '''<nowiki>{{familytree/start |summary=Sample 7}} | ||
{{Family tree/start}} | {{Family tree/start}} | ||
{{Family tree | | | | | | | | | | | | | A01 | | | | |A01= }} | {{Family tree | | | | | | | | | | | | | A01 | | | | |A01=A01}} | ||
{{Family tree | | | | | | | | | | | | | |!| | | | | }} | {{Family tree | | | | | | | | | | | | | |!| | | | | }} | ||
{{Family tree | | | | | | | | | | | | | B01 | | | |B01=}} | {{Family tree | | | | | | | | | | | | | B01 | | | |B01=B01}} | ||
{{Family tree | | | | | | | | | | |,|-|-|^|-|-|.| | }} | {{Family tree | | | | | | | | | | |,|-|-|^|-|-|.| | }} | ||
{{Family tree | | | | | | | | | | C01 | | | | C02 |C01= | C02= }} | {{Family tree | | | | | | | | | | C01 | | | | C02 |C01=C01|C02=C02}} | ||
{{Family tree | | | | | | | | | | |!| | | | | |!| | }} | {{Family tree | | | | | | | | | | |!| | | | | |!| | }} | ||
{{Family tree | | | | | | | | | | D01 | | | | |!| |D01= }} | {{Family tree | | | | | | | | | | D01 | | | | |!| |D01=D01}} | ||
{{Family tree | | | | | | | | | | |!| | | | | |!| | }} | {{Family tree | | | | | | | | | | |!| | | | | |!| | }} | ||
{{Family tree | | | | | | | |,|-|-|^|-|-|.| | |!| | }} | {{Family tree | | | | | | | |,|-|-|^|-|-|.| | |!| | }} | ||
{{Family tree | | | | | | | E01 | | | | E02 | |!| |E01= | E02= }} | {{Family tree | | | | | | | E01 | | | | E02 | |!| |E01=E01| E02=E02}} | ||
{{Family tree | | | | | | | |!| | | | | |!| | |!| | }} | {{Family tree | | | | | | | |!| | | | | |!| | |!| | }} | ||
{{Family tree | | | | | | | F01 | | | | |!| | |!| |F01= }} | {{Family tree | | | | | | | F01 | | | | |!| | |!| |F01=F01}} | ||
{{Family tree | | | | | |,|-|^|-|.| | | |!| | |!| | }} | {{Family tree | | | | | |,|-|^|-|.| | | |!| | |!| | }} | ||
{{Family tree | | | | | G01 | | G02 | | |!| | |!| |G01= | G02= }} | {{Family tree | | | | | G01 | | G02 | | |!| | |!| |G01=G01| G02=G02}} | ||
{{Family tree | | | | | |!| | | |!| | | |!| | |!| | }} | {{Family tree | | | | | |!| | | |!| | | |!| | |!| | }} | ||
{{Family tree | | | | | H01 | | |!| | | |!| | |!| |H01= }} | {{Family tree | | | | | H01 | | |!| | | |!| | |!| |H01=H01}} | ||
{{Family tree | | | |,|-|^|-|.| |!| | | |!| | |!| | }} | {{Family tree | | | |,|-|^|-|.| |!| | | |!| | |!| | }} | ||
{{Family tree | | | I01 | | I02 |!| | | |!| | |!| |I01= | I02= }} | {{Family tree | | | I01 | | I02 |!| | | |!| | |!| |I01=I01| I02=I02}} | ||
{{Family tree | | | |!| | | |!| |!| | | |!| | |!| | }} | {{Family tree | | | |!| | | |!| |!| | | |!| | |!| | }} | ||
{{Family tree | | | J01 | | |!| |!| | | |!| | |!| |J01= }} | {{Family tree | | | J01 | | |!| |!| | | |!| | |!| |J01=J01}} | ||
{{Family tree | |,|-|^|-|.| |!| |!| | | |!| | |!| | }} | {{Family tree | |,|-|^|-|.| |!| |!| | | |!| | |!| | }} | ||
{{Family tree | K01 | | K02 |!| |!| | | |!| | |!| |K01=| K02= }} | {{Family tree | K01 | | K02 |!| |!| | | |!| | |!| |K01=K01| K02=K02}} | ||
{{Family tree | |!| | | |!| |!| |!| | | |!| | |!| | }} | {{Family tree | |!| | | |!| |!| |!| | | |!| | |!| | }} | ||
{{Family tree | L01 | | L02 |`| L03 |-|-|^|-|-|'| |L01=| L02= | L03= }} | {{Family tree | L01 | | L02 |`| L03 |-|-|^|-|-|'| |L01=L01| L02=L02| L03=L03}} | ||
{{Family tree/end}} | {{Family tree/end}} | ||
</nowiki>''' | </nowiki>''' | ||
Line 359: | Line 359: | ||
{{familytree/start |summary=Sample 7}} | {{familytree/start |summary=Sample 7}} | ||
{{Family tree/start}} | {{Family tree/start}} | ||
{{Family tree | | | | | | | | | | | | | A01 | | | | |A01= }} | {{Family tree | | | | | | | | | | | | | A01 | | | | |A01=A01}} | ||
{{Family tree | | | | | | | | | | | | | |!| | | | | }} | {{Family tree | | | | | | | | | | | | | |!| | | | | }} | ||
{{Family tree | | | | | | | | | | | | | B01 | | | |B01=}} | {{Family tree | | | | | | | | | | | | | B01 | | | |B01=B01}} | ||
{{Family tree | | | | | | | | | | |,|-|-|^|-|-|.| | }} | {{Family tree | | | | | | | | | | |,|-|-|^|-|-|.| | }} | ||
{{Family tree | | | | | | | | | | C01 | | | | C02 |C01= | C02= }} | {{Family tree | | | | | | | | | | C01 | | | | C02 |C01=C01|C02=C02}} | ||
{{Family tree | | | | | | | | | | |!| | | | | |!| | }} | {{Family tree | | | | | | | | | | |!| | | | | |!| | }} | ||
{{Family tree | | | | | | | | | | D01 | | | | |!| |D01= }} | {{Family tree | | | | | | | | | | D01 | | | | |!| |D01=D01}} | ||
{{Family tree | | | | | | | | | | |!| | | | | |!| | }} | {{Family tree | | | | | | | | | | |!| | | | | |!| | }} | ||
{{Family tree | | | | | | | |,|-|-|^|-|-|.| | |!| | }} | {{Family tree | | | | | | | |,|-|-|^|-|-|.| | |!| | }} | ||
{{Family tree | | | | | | | E01 | | | | E02 | |!| |E01= | E02= }} | {{Family tree | | | | | | | E01 | | | | E02 | |!| |E01=E01| E02=E02}} | ||
{{Family tree | | | | | | | |!| | | | | |!| | |!| | }} | {{Family tree | | | | | | | |!| | | | | |!| | |!| | }} | ||
{{Family tree | | | | | | | F01 | | | | |!| | |!| |F01= }} | {{Family tree | | | | | | | F01 | | | | |!| | |!| |F01=F01}} | ||
{{Family tree | | | | | |,|-|^|-|.| | | |!| | |!| | }} | {{Family tree | | | | | |,|-|^|-|.| | | |!| | |!| | }} | ||
{{Family tree | | | | | G01 | | G02 | | |!| | |!| |G01= | G02= }} | {{Family tree | | | | | G01 | | G02 | | |!| | |!| |G01=G01| G02=G02}} | ||
{{Family tree | | | | | |!| | | |!| | | |!| | |!| | }} | {{Family tree | | | | | |!| | | |!| | | |!| | |!| | }} | ||
{{Family tree | | | | | H01 | | |!| | | |!| | |!| |H01= }} | {{Family tree | | | | | H01 | | |!| | | |!| | |!| |H01=H01}} | ||
{{Family tree | | | |,|-|^|-|.| |!| | | |!| | |!| | }} | {{Family tree | | | |,|-|^|-|.| |!| | | |!| | |!| | }} | ||
{{Family tree | | | I01 | | I02 |!| | | |!| | |!| |I01= | I02= }} | {{Family tree | | | I01 | | I02 |!| | | |!| | |!| |I01=I01| I02=I02}} | ||
{{Family tree | | | |!| | | |!| |!| | | |!| | |!| | }} | {{Family tree | | | |!| | | |!| |!| | | |!| | |!| | }} | ||
{{Family tree | | | J01 | | |!| |!| | | |!| | |!| |J01= }} | {{Family tree | | | J01 | | |!| |!| | | |!| | |!| |J01=J01}} | ||
{{Family tree | |,|-|^|-|.| |!| |!| | | |!| | |!| | }} | {{Family tree | |,|-|^|-|.| |!| |!| | | |!| | |!| | }} | ||
{{Family tree | K01 | | K02 |!| |!| | | |!| | |!| |K01=| K02= }} | {{Family tree | K01 | | K02 |!| |!| | | |!| | |!| |K01=K01| K02=K02}} | ||
{{Family tree | |!| | | |!| |!| |!| | | |!| | |!| | }} | {{Family tree | |!| | | |!| |!| |!| | | |!| | |!| | }} | ||
{{Family tree | L01 | | L02 |`| L03 |-|-|^|-|-|'| |L01=| L02= | L03= }} | {{Family tree | L01 | | L02 |`| L03 |-|-|^|-|-|'| |L01=L01| L02=L02| L03=L03}} | ||
{{Family tree/end}} | {{Family tree/end}} | ||
|- | |- |
Revision as of 02:33, 6 August 2020
Editor-In-Chief: C. Michael Gibson, M.S., M.D. [1]
Overview
An algorithm is a schematic drawing that helps organizing step by step approaches in a visually simplified way. An algorithm is formed by a set of boxes and lines that join them.
Create an Algorithm
Introduction
- To begin an algorithm, you should start with the following code {{family tree/start}} and end it with {{family tree/end}}.
- You can name an algorithm by starting with following: {{family tree/summary= Name of the algorithm}}
- The algorithm consists of boxes that occupy virtual rows:
Box 1 in Row 1 | |||||||||||||||||||||||
Box 2 in Row 2 | |||||||||||||||||||||||
Box 3 in Row 3 | Box 4 in Row 3 | ||||||||||||||||||||||
- Each row is represented by the following where each | | represents a space.:
{{Family tree | | | | | | | | | }}
- Each box is represented by the content that fills the space in | |, for example | A01 | will give:
A01 | |||||||
- In order to link the boxes you need to use symbols. The basic symbols that you will most commonly use are the following:
- ! will link two boxes placed vertically on top of each other
- - will link two boxes placed horizontally next to each other
- ^ will link bifurcate a line arising from a box into two branches.
Algorithm Basics
Linking cells horizontally: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Linking cells vertically: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
More | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type: | You get: | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type: | You get: | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type: | You get: | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Putting it together: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
You type:
{{Family tree/start}} |
You get:
|
Advanced Algorithms
Please find below an image that summarizes the symbols used in creating algorithms.