Best way to model Installation logic/flow - installation

We are currently working on designing the installer for our product. We are currently on the design phase and I'm wondering what is the best diagram (UML or not) to use when modeling installation logic or flow?
Currently, we are using the good'ol flowchart.
Thanks!

What problems are you having with the flowchart? Are you trying to model the functional flow of the application or the logic flow through the components of the system?
If you're just trying to show how the installer works from a functional perspective, then a flowchart is fine and has the advantage of being understandable by non-technical people.
But if you're doing a technical design, then probably you should use UML class and sequence diagrams. The class diagram shows the static relationships between classes, while sequence diagrams show how the classes interact to implement the functions of the application. You'll generally only need one class diagram but a whole bunch of sequence diagrams, because you need to work out the logic flow for each of the use cases that you've identified.
UML defines other diagram types that are all useful under limited circumstances, but class diagrams and sequence diagrams will get you 90% of the way home at least.
There's a diagram called a collaboration diagram that's related to a sequence diagram in that both show interactions between components. A collaboration diagram is what you create when you draw a bunch of boxes on a napkin and with arrows between them to show how components talk to each other. You may find that starting out with collaboration diagrams is easier.
This is a useful tool for making sequence diagrams:
http://www.websequencediagrams.com/

Related

How to use an activity diagram to detail classes & methods?

I wish to document code for a fairly complex algorithm whose implementation is intertwined across several methods and classes. A sequence diagram cannot really describe the detail of each method well so I am looking at an activity diagram; however this doesn't typically seem to represent classes and methods, only the logic.
Is there a common or even proper way to show which methods the logic belongs to? I do not need to follow strict UML, the purpose is simply to make it clear what's happening visually.
Activity diagrams and partitions
The activity diagram are supposed to models activities without necessarily relating them to classes/objects. They are however very suitable for modeling complex algorithms, as they allows to show :
the control flow -- flowchart diagrams have proven effective for modeling alorthims; activity diagrams are much more precise in their semantic and can do this as well.
object flows that show what objects are passed through
there are object actions that are specifically meant for dealing with objects
Activity diagrams support partitions, i.e. visual grouping of activities according to a criteria. A popular use is to split actions by using subsystems as grouping criteria. Breaking down by classes seems overkill, but nothing forbids such groupings if it helps, and if you're able to use it consistently.
Interaction overview diagrams
Interaction Overview Diagrams are specialization of Activity Diagrams that represent Interactions.
Interaction overview diagrams are a kind of combination of activity and sequence diagrams. The general idea is to use some activity modeling features for showing the big picture of the flows, between interaction nodes, i.e. mini sequence diagrams embedded in the larger diagram, to show which objects are involved and what messages they exchange.
There is an inspiring example here. But be careful: the linked website is based on a former version of UML and the text is not fully up-to-date. The most accurate source on these diagrams is section 17.10 of the UML 2.5.1 specs.
Additional thoughts
Instead of trying to show everything in one diagram, you may prefer the beauty of simplicity: use an easy to understand, simpler overview diagram, and uncover the complexity in additional diagrams that focus on details. This works with activity diagram complements with more detailed activities or sequence diagrams. But it also works the other way round, showing exchanges between key objects in a sequence diagram, and provide more detailed activity diagrams to describe what happens inside of one of the invoked operation.
Disclaimer: While I provide some hints that you can use to model algorithms in relation with their classes, I have at the same time to warn you that visual programming, i.e. a very very very detailed modeling, may lead to very complex diagrams that are difficult to read, and even more difficult to maintain. They loose the benefit of communicating the big picture. I'm not alone in this criticism, see Grady Booch who knows what he is talking about, since he is one of the co-inventor of UML, Martin Fowler, and many others

Modelling logic

I have an interface (android activity, but that should not matter) with text input, spinners and a toggle button (all on one page). Depending on the state of all these elements I produce text output (on the same page).
Since the relationship is not trivial, I would like to somehow visualize the logic relationship between these elements. I am reading about UML, activity diagrams, etc but got a bit lost there.
What term should I look for? What program do you recommend to use for drawing such diagrams on computer (linux)?
UML Activity Diagrams might not be what you are looking for. They are usually used to model activities in a process. They tend to be more high-level and conceptual and less about the implementation.
From your question it reads as if you are working on the implementation itself. In that case I would urge you to look at UML State Diagrams. They are really neat when you want to think about different states your application (or components of your application) can be in. It also lets you logically decompose behaviour into states.
Furthermore, it is also a straight-forward way to model your application in a way that you can apply a Design Pattern, notably the State Pattern, to implement your model.

How to use UML for describing distributed tasks

I am preparing a presentation and want to show some UML diagrams which will tell about how my distributed program runs. Since UML is a common language in the software world, I thought that it is one of the best ways to tell about the things in my mind to the listeners.
The problem is that I don't know how I can use UML diagrams for some distributed tasks. Firstly, I want to use Sequence diagrams and show the distributed components as actors. It looks possible. But, how can I demonstrate mpi_reduce_all function in this diagram? And, how can I demonstrate asynchronous communication and then synchronization (i.e. after a while I run isend/irecv commands, I synchronize the processes using wait_all function)?
Is there any idea for this? Or alternative diagrams to demonstrate what I want?
Check uml-diagrams.org: UML Activity Diagram Examples. The Fork/Join node in UML Activity Diagram is explicitly designed to show parallel tasks and synchronization points.
For the purposes of a presentation consider BPMN. The Business Process Model and
Notation (BPMN) language is also common in the software world and is also backed by the Object Management Group (OMG).
Description of parallel tasks and data exchange and synchronization points is among it's strong features.
See also:
Bonitasoft: The Ultimate Guide to BPMN2

Which type of UML diagram is best suited to modelling form validation rules?

Would an activity diagram be the best way to express validation rules for an HTML form, using a whole bunch of decision nodes? I am not convinced that it is, but I can't find a more appropriate one, nor can I find any examples of validation rules models online.
None - no one in their right mind would create a graphical representation of form validation rules. UML is not the same thing as engineering drawings, in spite of the best efforts of its proponents.
You're doing it wrong if the effort required to create the UML diagrams for a system approaches that of actually developing the code. Better to have running code that you can actually unit test. The unit tests are better documentation than UML will ever be.
Don't try to represent everything in UML.
An UML diagram is good idea. Activity diagram can be created with graphical rules (e.g. pink annotation).
It is a good start even before codding.
For any non-trivial rule you´ll need to use a language like OCL to be able to express the rule.
Validation is fired in case of a misuse case so it Can be represented using activity diagrams. Sequence and activity diagrams also help you debug production issues and nail them quickly

UML modeling tool which can convert a collaboration diagram into a sequence diagram (and back)

I was reading about UML Collaboration diagrams and what all of the tutorials mention is that a sophisticated UML modeling tool can easily convert a Collaboration diagram into a sequence diagram. I have looked around at a few and haven't found one that can do this which also runs on a Mac.
If you are aware of such a piece of software, which is still being actively developed, I would be interested.
You can convert a sequence diagram to a collaboration diagram but not a collaboration diagram to a sequence diagram.
It is also possible to display a method either in a sequence or a collaboration diagram. It seems to me that the collaboration diagram has been replaced in UML 2 by the communication diagram.
I have EclipseUML Omondo as my company modeling tool.
Have you looked at MagicDraw? I don't know if it covers your request, but it's one of the more full-featured ones out there.

Resources