Reputation: 1479
Suppose I have math algorithm e.g.
A = B + C
C = D + E
F = B + D
I would like to draw a diagram to represent it and the flow of the algorithm i.e. people know how the value of A calculate. Is there tool or the name of UML diagram that I can take a look?
Upvotes: 3
Views: 2882
Reputation: 897
There is an proposal to supplement UML diagrams by the diagrams called KOPENOGRAM. Which rather on data flow focus on algorithmical structure, conditions, loops, etc. As this is an proposal, limited specific tools exist to generate or draw kopenograms from source code (AFAIK there are Java plugins for BlueJ or NetBeans). However, Excel or any spreadsheet app might be used to make table and borders.
Your example will look like:
No dependency is shown on operations as in previous example, as this is task rather for compiler.
Upvotes: 2
Reputation: 9952
Maybe a Dataflow Diagram?
Something like this:
It's not part of UML, but can be a very useful way to show computation.
hth.
Upvotes: 2
Reputation: 7402
UML diagrams are either about static structure (classes/components/packages) or interaction between entities (activity/sequence diagrams/state machines).
Algorithms or algorithm design are not covered by UML (very much like any other type of concrete method specification).
Upvotes: 1