Tikz - Overlapping arrows make them too big












2















I'm pretty new to Tikz and I'm facing a little issue.



I'd like to draw arrows that are overlapping, all going in same directions, but it's getting wider and wider and is pretty horrible. How could I face it ? Here is the code :



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{tikz}
usetikzlibrary{shapes.geometric, arrows, calc}

begin{document}
begin{tikzpicture}[node distance=2.3cm]
% Style
tikzstyle{cell} = [rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20]
tikzstyle{tensor} = [circle, minimum width=1cm, text centered, draw=black, fill=green!10]

tikzstyle{arrow} = [thick,->,>=stealth]

% Nodes

node (he) [tensor] {$h^e$};

node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
node (dn) [cell, right of=d2, xshift=2cm] {$d$};

node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


% Arrows
draw[arrow] (w1) -| (d1);
draw[arrow] (w2) -| (d2);
draw[arrow] (wn) -| (dn);

draw[arrow] (d1) -- (d2);
draw[arrow] (he) |- (d1);

draw[arrow] (he) -| (d1);
draw[arrow] (he) -| (d2);
draw[arrow] (he) -| (dn);

end{tikzpicture}
end{document}


If you render the figure, you'll see arrows getting darker, how can I fix it ?



Thanks,
Cheers










share|improve this question









New contributor




Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





















  • Welcome to TeX.Stackexchange! Can you make your example compilable? When I try to run your code I get errors. I can debug them, but how would I know if this still reproduces the problem you are asking about?

    – samcarter
    4 hours ago













  • Actually, as I know, if two lines overlapping each other in TikZ, they are darkened.

    – JouleV
    4 hours ago











  • @samcarter I fixed it, bad copy/paster my bad

    – Ricocotam
    4 hours ago











  • @joulev That's exactly my problem, I don't want arrows being darkened

    – Ricocotam
    4 hours ago






  • 1





    Have you tried to print it? There are often aliasing problems with PDF viewers, and the line can seems darker or not depending on the zoom level.

    – Rmano
    4 hours ago
















2















I'm pretty new to Tikz and I'm facing a little issue.



I'd like to draw arrows that are overlapping, all going in same directions, but it's getting wider and wider and is pretty horrible. How could I face it ? Here is the code :



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{tikz}
usetikzlibrary{shapes.geometric, arrows, calc}

begin{document}
begin{tikzpicture}[node distance=2.3cm]
% Style
tikzstyle{cell} = [rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20]
tikzstyle{tensor} = [circle, minimum width=1cm, text centered, draw=black, fill=green!10]

tikzstyle{arrow} = [thick,->,>=stealth]

% Nodes

node (he) [tensor] {$h^e$};

node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
node (dn) [cell, right of=d2, xshift=2cm] {$d$};

node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


% Arrows
draw[arrow] (w1) -| (d1);
draw[arrow] (w2) -| (d2);
draw[arrow] (wn) -| (dn);

draw[arrow] (d1) -- (d2);
draw[arrow] (he) |- (d1);

draw[arrow] (he) -| (d1);
draw[arrow] (he) -| (d2);
draw[arrow] (he) -| (dn);

end{tikzpicture}
end{document}


If you render the figure, you'll see arrows getting darker, how can I fix it ?



Thanks,
Cheers










share|improve this question









New contributor




Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





















  • Welcome to TeX.Stackexchange! Can you make your example compilable? When I try to run your code I get errors. I can debug them, but how would I know if this still reproduces the problem you are asking about?

    – samcarter
    4 hours ago













  • Actually, as I know, if two lines overlapping each other in TikZ, they are darkened.

    – JouleV
    4 hours ago











  • @samcarter I fixed it, bad copy/paster my bad

    – Ricocotam
    4 hours ago











  • @joulev That's exactly my problem, I don't want arrows being darkened

    – Ricocotam
    4 hours ago






  • 1





    Have you tried to print it? There are often aliasing problems with PDF viewers, and the line can seems darker or not depending on the zoom level.

    – Rmano
    4 hours ago














2












2








2


1






I'm pretty new to Tikz and I'm facing a little issue.



I'd like to draw arrows that are overlapping, all going in same directions, but it's getting wider and wider and is pretty horrible. How could I face it ? Here is the code :



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{tikz}
usetikzlibrary{shapes.geometric, arrows, calc}

begin{document}
begin{tikzpicture}[node distance=2.3cm]
% Style
tikzstyle{cell} = [rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20]
tikzstyle{tensor} = [circle, minimum width=1cm, text centered, draw=black, fill=green!10]

tikzstyle{arrow} = [thick,->,>=stealth]

% Nodes

node (he) [tensor] {$h^e$};

node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
node (dn) [cell, right of=d2, xshift=2cm] {$d$};

node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


% Arrows
draw[arrow] (w1) -| (d1);
draw[arrow] (w2) -| (d2);
draw[arrow] (wn) -| (dn);

draw[arrow] (d1) -- (d2);
draw[arrow] (he) |- (d1);

draw[arrow] (he) -| (d1);
draw[arrow] (he) -| (d2);
draw[arrow] (he) -| (dn);

end{tikzpicture}
end{document}


If you render the figure, you'll see arrows getting darker, how can I fix it ?



Thanks,
Cheers










share|improve this question









New contributor




Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












I'm pretty new to Tikz and I'm facing a little issue.



I'd like to draw arrows that are overlapping, all going in same directions, but it's getting wider and wider and is pretty horrible. How could I face it ? Here is the code :



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{tikz}
usetikzlibrary{shapes.geometric, arrows, calc}

begin{document}
begin{tikzpicture}[node distance=2.3cm]
% Style
tikzstyle{cell} = [rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20]
tikzstyle{tensor} = [circle, minimum width=1cm, text centered, draw=black, fill=green!10]

tikzstyle{arrow} = [thick,->,>=stealth]

% Nodes

node (he) [tensor] {$h^e$};

node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
node (dn) [cell, right of=d2, xshift=2cm] {$d$};

node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


% Arrows
draw[arrow] (w1) -| (d1);
draw[arrow] (w2) -| (d2);
draw[arrow] (wn) -| (dn);

draw[arrow] (d1) -- (d2);
draw[arrow] (he) |- (d1);

draw[arrow] (he) -| (d1);
draw[arrow] (he) -| (d2);
draw[arrow] (he) -| (dn);

end{tikzpicture}
end{document}


If you render the figure, you'll see arrows getting darker, how can I fix it ?



Thanks,
Cheers







tikz-arrows






share|improve this question









New contributor




Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited 4 hours ago









samcarter

87.8k796280




87.8k796280






New contributor




Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked 4 hours ago









RicocotamRicocotam

133




133




New contributor




Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Ricocotam is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.













  • Welcome to TeX.Stackexchange! Can you make your example compilable? When I try to run your code I get errors. I can debug them, but how would I know if this still reproduces the problem you are asking about?

    – samcarter
    4 hours ago













  • Actually, as I know, if two lines overlapping each other in TikZ, they are darkened.

    – JouleV
    4 hours ago











  • @samcarter I fixed it, bad copy/paster my bad

    – Ricocotam
    4 hours ago











  • @joulev That's exactly my problem, I don't want arrows being darkened

    – Ricocotam
    4 hours ago






  • 1





    Have you tried to print it? There are often aliasing problems with PDF viewers, and the line can seems darker or not depending on the zoom level.

    – Rmano
    4 hours ago



















  • Welcome to TeX.Stackexchange! Can you make your example compilable? When I try to run your code I get errors. I can debug them, but how would I know if this still reproduces the problem you are asking about?

    – samcarter
    4 hours ago













  • Actually, as I know, if two lines overlapping each other in TikZ, they are darkened.

    – JouleV
    4 hours ago











  • @samcarter I fixed it, bad copy/paster my bad

    – Ricocotam
    4 hours ago











  • @joulev That's exactly my problem, I don't want arrows being darkened

    – Ricocotam
    4 hours ago






  • 1





    Have you tried to print it? There are often aliasing problems with PDF viewers, and the line can seems darker or not depending on the zoom level.

    – Rmano
    4 hours ago

















Welcome to TeX.Stackexchange! Can you make your example compilable? When I try to run your code I get errors. I can debug them, but how would I know if this still reproduces the problem you are asking about?

– samcarter
4 hours ago







Welcome to TeX.Stackexchange! Can you make your example compilable? When I try to run your code I get errors. I can debug them, but how would I know if this still reproduces the problem you are asking about?

– samcarter
4 hours ago















Actually, as I know, if two lines overlapping each other in TikZ, they are darkened.

– JouleV
4 hours ago





Actually, as I know, if two lines overlapping each other in TikZ, they are darkened.

– JouleV
4 hours ago













@samcarter I fixed it, bad copy/paster my bad

– Ricocotam
4 hours ago





@samcarter I fixed it, bad copy/paster my bad

– Ricocotam
4 hours ago













@joulev That's exactly my problem, I don't want arrows being darkened

– Ricocotam
4 hours ago





@joulev That's exactly my problem, I don't want arrows being darkened

– Ricocotam
4 hours ago




1




1





Have you tried to print it? There are often aliasing problems with PDF viewers, and the line can seems darker or not depending on the zoom level.

– Rmano
4 hours ago





Have you tried to print it? There are often aliasing problems with PDF viewers, and the line can seems darker or not depending on the zoom level.

– Rmano
4 hours ago










2 Answers
2






active

oldest

votes


















3














The following example uses the calc library to print each line only once. If you still experience problems with varying line widths this is most probably an issue of your pdf viewer.



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{tikz}
usetikzlibrary{shapes.geometric, arrows, calc}

begin{document}
begin{tikzpicture}[node distance=2.3cm]
% Style
tikzset{
cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
arrow/.style={thick,->,>=stealth}
}

% Nodes

node (he) [tensor] {$h^e$};

node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
node (dn) [cell, right of=d2, xshift=2cm] {$d$};

node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


% Arrows
draw[arrow] (w1) -| (d1);
draw[arrow] (w2) -| (d2);
draw[arrow] (wn) -| (dn);

draw[arrow] (d1) -- (d2);
draw[arrow] (he) |- (d1);

draw[arrow] (he) -| (d1);
draw[arrow] let p1 = (he), p2 = (d1) in (x2,y1) -| (d2);
draw[arrow] let p1 = (he), p2 = (d2) in (x2,y1) -| (dn);

end{tikzpicture}
end{document}


enter image description here



Thanks to @marmot for suggesting this calc free version:



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{tikz}
usetikzlibrary{shapes.geometric, arrows}

begin{document}
begin{tikzpicture}[node distance=2.3cm]
% Style
tikzset{
cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
arrow/.style={thick,->,>=stealth}
}

% Nodes

node (he) [tensor] {$h^e$};

node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
node (dn) [cell, right of=d2, xshift=2cm] {$d$};

node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


% Arrows
draw[arrow] (w1) -| (d1);
draw[arrow] (w2) -| (d2);
draw[arrow] (wn) -| (dn);

draw[arrow] (d1) -- (d2);
draw[arrow] (he) |- (d1);

draw[arrow] (he) -| (d1);
draw[arrow] (d1|-he) -| (d2);
draw[arrow] (d2|-he) -| (dn);

end{tikzpicture}
end{document}





share|improve this answer


























  • Thanks a lot, you're awsome ! Could you give a bit background or give some resources so I understand how to reuse this kind of things ?

    – Ricocotam
    4 hours ago













  • @Ricocotam See tex.stackexchange.com/a/18393/36296 for a short example how the calc library works

    – samcarter
    2 hours ago











  • draw[arrow] (d1|-he) -| (d2); draw[arrow] (d2|-he) -| (dn); would also do, so you may not even need calc here. And perhaps tikzset{cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20}, tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth}}?

    – marmot
    42 mins ago











  • @marmot Thanks for your suggestions! I just fixed the tikzset and will soon post a second example without calc.

    – samcarter
    10 mins ago



















1














This is what I see (okular) at 100% zoom:



enter image description here



so I can't see any "darkening". Now, zooming in:



enter image description here



This is a rendering/aliasing problem for subpixel zooms, and it is mostly unsolvable (it depends on the anti-aliasing algorithm of the viewer).






share|improve this answer























    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "85"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });






    Ricocotam is a new contributor. Be nice, and check out our Code of Conduct.










    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f471444%2ftikz-overlapping-arrows-make-them-too-big%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    3














    The following example uses the calc library to print each line only once. If you still experience problems with varying line widths this is most probably an issue of your pdf viewer.



    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{tikz}
    usetikzlibrary{shapes.geometric, arrows, calc}

    begin{document}
    begin{tikzpicture}[node distance=2.3cm]
    % Style
    tikzset{
    cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
    tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
    arrow/.style={thick,->,>=stealth}
    }

    % Nodes

    node (he) [tensor] {$h^e$};

    node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
    node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
    node (dn) [cell, right of=d2, xshift=2cm] {$d$};

    node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
    node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
    node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


    % Arrows
    draw[arrow] (w1) -| (d1);
    draw[arrow] (w2) -| (d2);
    draw[arrow] (wn) -| (dn);

    draw[arrow] (d1) -- (d2);
    draw[arrow] (he) |- (d1);

    draw[arrow] (he) -| (d1);
    draw[arrow] let p1 = (he), p2 = (d1) in (x2,y1) -| (d2);
    draw[arrow] let p1 = (he), p2 = (d2) in (x2,y1) -| (dn);

    end{tikzpicture}
    end{document}


    enter image description here



    Thanks to @marmot for suggesting this calc free version:



    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{tikz}
    usetikzlibrary{shapes.geometric, arrows}

    begin{document}
    begin{tikzpicture}[node distance=2.3cm]
    % Style
    tikzset{
    cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
    tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
    arrow/.style={thick,->,>=stealth}
    }

    % Nodes

    node (he) [tensor] {$h^e$};

    node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
    node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
    node (dn) [cell, right of=d2, xshift=2cm] {$d$};

    node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
    node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
    node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


    % Arrows
    draw[arrow] (w1) -| (d1);
    draw[arrow] (w2) -| (d2);
    draw[arrow] (wn) -| (dn);

    draw[arrow] (d1) -- (d2);
    draw[arrow] (he) |- (d1);

    draw[arrow] (he) -| (d1);
    draw[arrow] (d1|-he) -| (d2);
    draw[arrow] (d2|-he) -| (dn);

    end{tikzpicture}
    end{document}





    share|improve this answer


























    • Thanks a lot, you're awsome ! Could you give a bit background or give some resources so I understand how to reuse this kind of things ?

      – Ricocotam
      4 hours ago













    • @Ricocotam See tex.stackexchange.com/a/18393/36296 for a short example how the calc library works

      – samcarter
      2 hours ago











    • draw[arrow] (d1|-he) -| (d2); draw[arrow] (d2|-he) -| (dn); would also do, so you may not even need calc here. And perhaps tikzset{cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20}, tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth}}?

      – marmot
      42 mins ago











    • @marmot Thanks for your suggestions! I just fixed the tikzset and will soon post a second example without calc.

      – samcarter
      10 mins ago
















    3














    The following example uses the calc library to print each line only once. If you still experience problems with varying line widths this is most probably an issue of your pdf viewer.



    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{tikz}
    usetikzlibrary{shapes.geometric, arrows, calc}

    begin{document}
    begin{tikzpicture}[node distance=2.3cm]
    % Style
    tikzset{
    cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
    tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
    arrow/.style={thick,->,>=stealth}
    }

    % Nodes

    node (he) [tensor] {$h^e$};

    node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
    node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
    node (dn) [cell, right of=d2, xshift=2cm] {$d$};

    node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
    node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
    node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


    % Arrows
    draw[arrow] (w1) -| (d1);
    draw[arrow] (w2) -| (d2);
    draw[arrow] (wn) -| (dn);

    draw[arrow] (d1) -- (d2);
    draw[arrow] (he) |- (d1);

    draw[arrow] (he) -| (d1);
    draw[arrow] let p1 = (he), p2 = (d1) in (x2,y1) -| (d2);
    draw[arrow] let p1 = (he), p2 = (d2) in (x2,y1) -| (dn);

    end{tikzpicture}
    end{document}


    enter image description here



    Thanks to @marmot for suggesting this calc free version:



    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{tikz}
    usetikzlibrary{shapes.geometric, arrows}

    begin{document}
    begin{tikzpicture}[node distance=2.3cm]
    % Style
    tikzset{
    cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
    tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
    arrow/.style={thick,->,>=stealth}
    }

    % Nodes

    node (he) [tensor] {$h^e$};

    node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
    node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
    node (dn) [cell, right of=d2, xshift=2cm] {$d$};

    node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
    node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
    node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


    % Arrows
    draw[arrow] (w1) -| (d1);
    draw[arrow] (w2) -| (d2);
    draw[arrow] (wn) -| (dn);

    draw[arrow] (d1) -- (d2);
    draw[arrow] (he) |- (d1);

    draw[arrow] (he) -| (d1);
    draw[arrow] (d1|-he) -| (d2);
    draw[arrow] (d2|-he) -| (dn);

    end{tikzpicture}
    end{document}





    share|improve this answer


























    • Thanks a lot, you're awsome ! Could you give a bit background or give some resources so I understand how to reuse this kind of things ?

      – Ricocotam
      4 hours ago













    • @Ricocotam See tex.stackexchange.com/a/18393/36296 for a short example how the calc library works

      – samcarter
      2 hours ago











    • draw[arrow] (d1|-he) -| (d2); draw[arrow] (d2|-he) -| (dn); would also do, so you may not even need calc here. And perhaps tikzset{cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20}, tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth}}?

      – marmot
      42 mins ago











    • @marmot Thanks for your suggestions! I just fixed the tikzset and will soon post a second example without calc.

      – samcarter
      10 mins ago














    3












    3








    3







    The following example uses the calc library to print each line only once. If you still experience problems with varying line widths this is most probably an issue of your pdf viewer.



    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{tikz}
    usetikzlibrary{shapes.geometric, arrows, calc}

    begin{document}
    begin{tikzpicture}[node distance=2.3cm]
    % Style
    tikzset{
    cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
    tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
    arrow/.style={thick,->,>=stealth}
    }

    % Nodes

    node (he) [tensor] {$h^e$};

    node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
    node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
    node (dn) [cell, right of=d2, xshift=2cm] {$d$};

    node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
    node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
    node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


    % Arrows
    draw[arrow] (w1) -| (d1);
    draw[arrow] (w2) -| (d2);
    draw[arrow] (wn) -| (dn);

    draw[arrow] (d1) -- (d2);
    draw[arrow] (he) |- (d1);

    draw[arrow] (he) -| (d1);
    draw[arrow] let p1 = (he), p2 = (d1) in (x2,y1) -| (d2);
    draw[arrow] let p1 = (he), p2 = (d2) in (x2,y1) -| (dn);

    end{tikzpicture}
    end{document}


    enter image description here



    Thanks to @marmot for suggesting this calc free version:



    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{tikz}
    usetikzlibrary{shapes.geometric, arrows}

    begin{document}
    begin{tikzpicture}[node distance=2.3cm]
    % Style
    tikzset{
    cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
    tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
    arrow/.style={thick,->,>=stealth}
    }

    % Nodes

    node (he) [tensor] {$h^e$};

    node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
    node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
    node (dn) [cell, right of=d2, xshift=2cm] {$d$};

    node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
    node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
    node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


    % Arrows
    draw[arrow] (w1) -| (d1);
    draw[arrow] (w2) -| (d2);
    draw[arrow] (wn) -| (dn);

    draw[arrow] (d1) -- (d2);
    draw[arrow] (he) |- (d1);

    draw[arrow] (he) -| (d1);
    draw[arrow] (d1|-he) -| (d2);
    draw[arrow] (d2|-he) -| (dn);

    end{tikzpicture}
    end{document}





    share|improve this answer















    The following example uses the calc library to print each line only once. If you still experience problems with varying line widths this is most probably an issue of your pdf viewer.



    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{tikz}
    usetikzlibrary{shapes.geometric, arrows, calc}

    begin{document}
    begin{tikzpicture}[node distance=2.3cm]
    % Style
    tikzset{
    cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
    tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
    arrow/.style={thick,->,>=stealth}
    }

    % Nodes

    node (he) [tensor] {$h^e$};

    node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
    node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
    node (dn) [cell, right of=d2, xshift=2cm] {$d$};

    node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
    node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
    node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


    % Arrows
    draw[arrow] (w1) -| (d1);
    draw[arrow] (w2) -| (d2);
    draw[arrow] (wn) -| (dn);

    draw[arrow] (d1) -- (d2);
    draw[arrow] (he) |- (d1);

    draw[arrow] (he) -| (d1);
    draw[arrow] let p1 = (he), p2 = (d1) in (x2,y1) -| (d2);
    draw[arrow] let p1 = (he), p2 = (d2) in (x2,y1) -| (dn);

    end{tikzpicture}
    end{document}


    enter image description here



    Thanks to @marmot for suggesting this calc free version:



    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{tikz}
    usetikzlibrary{shapes.geometric, arrows}

    begin{document}
    begin{tikzpicture}[node distance=2.3cm]
    % Style
    tikzset{
    cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20},
    tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth},
    arrow/.style={thick,->,>=stealth}
    }

    % Nodes

    node (he) [tensor] {$h^e$};

    node (d1) [cell, right of=he, below of=he, xshift=1.5cm, yshift=-2cm] {$d$};
    node (d2) [cell, right of=d1, xshift=1.5cm] {$d$};
    node (dn) [cell, right of=d2, xshift=2cm] {$d$};

    node (w1) [tensor, above of=d1, left of=d1, minimum width=1.25cm] {$w_1$};
    node (w2) [tensor, above of=d2, left of=d2, minimum width=1.25cm] {$w_2$};
    node (wn) [tensor, above of=dn, left of=dn, minimum width=1.25cm] {$w_n$};


    % Arrows
    draw[arrow] (w1) -| (d1);
    draw[arrow] (w2) -| (d2);
    draw[arrow] (wn) -| (dn);

    draw[arrow] (d1) -- (d2);
    draw[arrow] (he) |- (d1);

    draw[arrow] (he) -| (d1);
    draw[arrow] (d1|-he) -| (d2);
    draw[arrow] (d2|-he) -| (dn);

    end{tikzpicture}
    end{document}






    share|improve this answer














    share|improve this answer



    share|improve this answer








    edited 11 mins ago

























    answered 4 hours ago









    samcartersamcarter

    87.8k796280




    87.8k796280













    • Thanks a lot, you're awsome ! Could you give a bit background or give some resources so I understand how to reuse this kind of things ?

      – Ricocotam
      4 hours ago













    • @Ricocotam See tex.stackexchange.com/a/18393/36296 for a short example how the calc library works

      – samcarter
      2 hours ago











    • draw[arrow] (d1|-he) -| (d2); draw[arrow] (d2|-he) -| (dn); would also do, so you may not even need calc here. And perhaps tikzset{cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20}, tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth}}?

      – marmot
      42 mins ago











    • @marmot Thanks for your suggestions! I just fixed the tikzset and will soon post a second example without calc.

      – samcarter
      10 mins ago



















    • Thanks a lot, you're awsome ! Could you give a bit background or give some resources so I understand how to reuse this kind of things ?

      – Ricocotam
      4 hours ago













    • @Ricocotam See tex.stackexchange.com/a/18393/36296 for a short example how the calc library works

      – samcarter
      2 hours ago











    • draw[arrow] (d1|-he) -| (d2); draw[arrow] (d2|-he) -| (dn); would also do, so you may not even need calc here. And perhaps tikzset{cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20}, tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth}}?

      – marmot
      42 mins ago











    • @marmot Thanks for your suggestions! I just fixed the tikzset and will soon post a second example without calc.

      – samcarter
      10 mins ago

















    Thanks a lot, you're awsome ! Could you give a bit background or give some resources so I understand how to reuse this kind of things ?

    – Ricocotam
    4 hours ago







    Thanks a lot, you're awsome ! Could you give a bit background or give some resources so I understand how to reuse this kind of things ?

    – Ricocotam
    4 hours ago















    @Ricocotam See tex.stackexchange.com/a/18393/36296 for a short example how the calc library works

    – samcarter
    2 hours ago





    @Ricocotam See tex.stackexchange.com/a/18393/36296 for a short example how the calc library works

    – samcarter
    2 hours ago













    draw[arrow] (d1|-he) -| (d2); draw[arrow] (d2|-he) -| (dn); would also do, so you may not even need calc here. And perhaps tikzset{cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20}, tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth}}?

    – marmot
    42 mins ago





    draw[arrow] (d1|-he) -| (d2); draw[arrow] (d2|-he) -| (dn); would also do, so you may not even need calc here. And perhaps tikzset{cell/.style={rectangle, minimum width=1.5cm, minimum height=1.5cm, text centered, draw=black, fill=green!20}, tensor/.style={circle, minimum width=1cm, text centered, draw=black, fill=green!10}, arrow/.style={thick,->,>=stealth}}?

    – marmot
    42 mins ago













    @marmot Thanks for your suggestions! I just fixed the tikzset and will soon post a second example without calc.

    – samcarter
    10 mins ago





    @marmot Thanks for your suggestions! I just fixed the tikzset and will soon post a second example without calc.

    – samcarter
    10 mins ago











    1














    This is what I see (okular) at 100% zoom:



    enter image description here



    so I can't see any "darkening". Now, zooming in:



    enter image description here



    This is a rendering/aliasing problem for subpixel zooms, and it is mostly unsolvable (it depends on the anti-aliasing algorithm of the viewer).






    share|improve this answer




























      1














      This is what I see (okular) at 100% zoom:



      enter image description here



      so I can't see any "darkening". Now, zooming in:



      enter image description here



      This is a rendering/aliasing problem for subpixel zooms, and it is mostly unsolvable (it depends on the anti-aliasing algorithm of the viewer).






      share|improve this answer


























        1












        1








        1







        This is what I see (okular) at 100% zoom:



        enter image description here



        so I can't see any "darkening". Now, zooming in:



        enter image description here



        This is a rendering/aliasing problem for subpixel zooms, and it is mostly unsolvable (it depends on the anti-aliasing algorithm of the viewer).






        share|improve this answer













        This is what I see (okular) at 100% zoom:



        enter image description here



        so I can't see any "darkening". Now, zooming in:



        enter image description here



        This is a rendering/aliasing problem for subpixel zooms, and it is mostly unsolvable (it depends on the anti-aliasing algorithm of the viewer).







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered 4 hours ago









        RmanoRmano

        7,88721647




        7,88721647






















            Ricocotam is a new contributor. Be nice, and check out our Code of Conduct.










            draft saved

            draft discarded


















            Ricocotam is a new contributor. Be nice, and check out our Code of Conduct.













            Ricocotam is a new contributor. Be nice, and check out our Code of Conduct.












            Ricocotam is a new contributor. Be nice, and check out our Code of Conduct.
















            Thanks for contributing an answer to TeX - LaTeX Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f471444%2ftikz-overlapping-arrows-make-them-too-big%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            SQL Server 17 - Attemping to backup to remote NAS but Access is denied

            Always On Availability groups resolving state after failover - Remote harden of transaction...

            Restoring from pg_dump with foreign key constraints