Re: weighted graph, edges thickness

• To: mathgroup at smc.vnet.net
• Subject: [mg105017] Re: weighted graph, edges thickness
• From: cherifrahal <cherif.rahal at gmail.com>
• Date: Wed, 18 Nov 2009 06:57:30 -0500 (EST)
• References: <hd8rus\$5ks\$1@smc.vnet.net> <hdgps4\$i1a\$1@smc.vnet.net>

```Thank's a lot for your answer,
Cheers
Cherif Rahal

On Nov 17, 11:15 am, "Sjoerd C. de Vries" <sjoerd.c.devr... at gmail.com>
wrote:
> Just replace the radius of the cylinder with the (scaled) weight of
> the graph like I did before with the thickness of the line:
>
> m = {{0, 2, 0, 0}, {0, 0, 1, 0}, {1, 0, 0, 5}, {1, 0, 0, 0}};
>
> GraphPlot3D[m,
>  EdgeRenderingFunction -> (Cylinder[{#1},
>      m[[#2[[1]], #2[[2]]]]/20] &)]
>
> Cheers -- Sjoerd
>
> On Nov 13, 1:09 pm, cherifrahal <cherif.ra... at gmail.com> wrote:
>
> > Thank you very much, It works very well for 2 D graphs
> > But if i have a 3D graph does it work ?
>
> > An example of a 3D graph :
>
> > GraphPlot3D[{1 -> 2, 1 -> 4, 1 -> 5, 2 -> 3, 2 -> 6, 3 -> 4, 3 -> 7,
> >  4 -> 8, 5 -> 6, 5 -> 8, 6 -> 7, 7 -> 8, 5 -> 10, 6 -> 11, 10 -> 11,
> >  10 -> 12, 11 -> 12, 12 -> 13, 9 -> 13},
> >  EdgeRenderingFunction -> (Cylinder[{#1}, 0.15] &),
> >  VertexCoordinateRules -> {1 -> {-1, 1, 2}, 2 -> {1, 1, 2},
> >   4 -> {-1, -1, 2}, 3 -> {1, -1, 2}, 5 -> {-2, 2, 0}, 6 -> {2, 2, 0},
> >    7 -> {2, -2, 0}, 8 -> {-2, -2, 0}, 9 -> {0, 0, 2},
> >   10 -> {-2, 4, 0}, 11 -> {2, 4, 0}, 12 -> {0, 3, 3},
> >   13 -> {0, 2.2, 3.5}}]
>
> > Cheers
>
> > Cherif Rahal

```

• Prev by Date: Re: Sound Functions Crash Kernel
• Next by Date: How to instruct Math to take a certain (e.g. real) type of results
• Previous by thread: Re: weighted graph, edges thickness
• Next by thread: Re: Simplification problem updated