IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Tableaux - Graphiques - Images - Flottants Discussion :

Organigramme de programmation


Sujet :

Tableaux - Graphiques - Images - Flottants

  1. #1
    Futur Membre du Club
    Femme Profil pro
    Étudiant
    Inscrit en
    Juin 2021
    Messages
    7
    Détails du profil
    Informations personnelles :
    Sexe : Femme
    Localisation : France, Hauts de Seine (Île de France)

    Informations professionnelles :
    Activité : Étudiant

    Informations forums :
    Inscription : Juin 2021
    Messages : 7
    Points : 9
    Points
    9
    Par défaut Organigramme de programmation
    Bonjour,

    Je souhaite représenté un algorithme sous forme d'organigramme de programmation (flowchart) mais je n'arrive pas à corriger un petit problème visuel avec une flêche.
    La flêche sortante droite du dernier losange de décision coupe mon organigramme. Or, ce que je souhaite c'est que la flêche ait une allure comme ce que j'ai dessiné en rouge.
    Nom : flowchart.png
Affichages : 1145
Taille : 78,1 Ko

    Voici le code

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    \documentclass[a4paper, 11pt, twoside,openright]{report}
    \usepackage[latin1]{inputenc}
    \usepackage{tikz}
    \usetikzlibrary{shapes,arrows}
     
     
     
    \begin{document}
    \tikzstyle{decision} = [diamond, draw, fill=blue!20, 
        text width=4.5em, text badly centered, node distance=4cm, inner sep=0pt]
    \tikzstyle{block} = [rectangle, draw, fill=blue!20, 
        text width=6em, text centered, rounded corners, minimum height=4em]
    \tikzstyle{line} = [draw, -latex']
    \tikzstyle{cloud} = [draw, ellipse,fill=red!20, node distance=3cm,
        minimum height=2em]
     
    \begin{figure}
    \begin{tikzpicture}[node distance = 3cm, auto]
        \node [cloud] (input) {Sell and buy order input};
        \node[decision, below of=input] (while) {Reach end of any array?};
        \node [block, right of=while, node distance=4cm] (result) {Output the order list};
        \node[decision, below of =while] (price) {buyer price $\geq$ seller price?};
        \node [decision, below of=price] (token) {buyer token $\leq$ seller token?};
        \node [block, below of=token, node distance=4cm] (update1) {update token balance};
        \node [block, below of = update1] (createAdd1) {create and add the record to order list};
        \node[block, right of = token, node distance = 4cm] (update2) {update token balance};
        \node[block, below of=update2] (createAdd2) {create and add the record to order list};
        \node[block, below of=createAdd2] (nextb) {next buyer};
        \node[decision, below of=nextb] (notoken) {token=0?};
        \node[block, left of=price, node distance=4cm] (nexts2) {next seller};
     
        \draw [line] (input) -- coordinate[midway](m1)(while);
        \path [line] (input) -- (while);
        \path [line] (while) -- node {yes}(result);
        \path [line] (while) -- node {no} (price);
        \path [line] (price) -- node {yes} (token);
        \path [line] (token) -- node{no} (update1);
        \path [line] (token) -- node {yes} (update2);
        \path [line] (update1) -- (createAdd1);
        \path [line] (createAdd1) -| (nexts2);
        \path [line] (update2) -- (createAdd2);
        \path [line] (createAdd2) -- (nextb);
        \path [line] (nextb) -- (notoken);
        \path [line] (notoken) -| node {yes} (nexts2);
        \path [line] (price) -- node {no} (nexts2);
        \path [line] (nexts2) |- (while);
        \draw[line] (notoken.0) |- node {no}(m1);
     
    \end{tikzpicture}
    \caption{flowchart}
    \label{fig:flowchart}
    \end{figure}
     
    \end{document}
    Merci pour votre aide ^^.
    Bonne journée.

  2. #2
    Invité
    Invité(e)
    Par défaut
    Bonsoir,

    Comme ceci en ajoutant un point de contrôle :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    \draw[line] (notoken.0) -- ++(1cm, 0) |- node[right] {no}(m1);
    J'ai aussi ajouté [right] au passage pour avoir le « no » de côté et non sur le trait.

  3. #3
    Futur Membre du Club
    Femme Profil pro
    Étudiant
    Inscrit en
    Juin 2021
    Messages
    7
    Détails du profil
    Informations personnelles :
    Sexe : Femme
    Localisation : France, Hauts de Seine (Île de France)

    Informations professionnelles :
    Activité : Étudiant

    Informations forums :
    Inscription : Juin 2021
    Messages : 7
    Points : 9
    Points
    9
    Par défaut
    Merci beaucoup
    C'est parfait!

    Bonne journée!

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. [Débutant] Organigramme , programme matlab
    Par electrique_90 dans le forum MATLAB
    Réponses: 3
    Dernier message: 13/01/2010, 11h45
  2. Programme de boot qui passe la main à Windows
    Par Bob dans le forum Assembleur
    Réponses: 7
    Dernier message: 25/11/2002, 03h08
  3. [Kylix] Probleme d'execution de programmes...
    Par yopziggy dans le forum EDI
    Réponses: 19
    Dernier message: 03/05/2002, 14h50
  4. communication entre programmes
    Par jérôme dans le forum C
    Réponses: 12
    Dernier message: 16/04/2002, 08h05
  5. [Kylix] icone associée à un programme
    Par Anonymous dans le forum EDI
    Réponses: 1
    Dernier message: 22/03/2002, 09h43

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo