Difference in "layout = 'acyclic'" between local copy of sage and cocalc

33 views
Skip to first unread message

Nikos Apostolakis

unread,
Jul 7, 2017, 7:33:38 AM7/7/17
to sage-s...@googlegroups.com
Dear group,

The following:

   sage: foo = DiGraph([(1,4), (1,5), (2,4), (3,5)])
   sage: foo.show(layout = 'acyclic')

produces different output in CoCalc and in my local copy of Sage (7.2) and , see the attached images.  The difference is much more pronounced in other examples.  

Can I get my local copy to produce the same result as in CoCalc?

Thanks,
Nikos




digraph_cloud.png
digraph_local.png

William Stein

unread,
Jul 7, 2017, 10:41:18 AM7/7/17
to sage-s...@googlegroups.com
What happens if you install the latest stable release (7.6) of Sage locally?  Sage v 7.2 is pretty old.


Thanks,
Nikos




--
You received this message because you are subscribed to the Google Groups "sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sage-support...@googlegroups.com.
To post to this group, send email to sage-s...@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.
--
-- William Stein

Nikos Apostolakis

unread,
Jul 7, 2017, 12:57:08 PM7/7/17
to sage-support

On Friday, July 7, 2017 at 10:41:18 AM UTC-4, William wrote:

On Fri, Jul 7, 2017 at 4:33 AM Nikos Apostolakis <niko...@gmail.com> wrote:
Dear group,

The following:

   sage: foo = DiGraph([(1,4), (1,5), (2,4), (3,5)])
   sage: foo.show(layout = 'acyclic')

produces different output in CoCalc and in my local copy of Sage (7.2) and , see the attached images.  The difference is much more pronounced in other examples.  

Can I get my local copy to produce the same result as in CoCalc?

What happens if you install the latest stable release (7.6) of Sage locally?  Sage v 7.2 is pretty old.


Thanks for the reply.

I'll upgrade and let you know if this solves the problem.  

Nikos


Nikos Apostolakis

unread,
Jul 8, 2017, 8:04:57 AM7/8/17
to sage-support
I installed 7.6 and the output is still the same.

Nikos

Nikos Apostolakis

unread,
Jul 8, 2017, 3:16:28 PM7/8/17
to sage-support
Sorry for replying to my own post, but I realized that my post is ambiguous.  I meant that the problem persists even after I installed 7.6. The layout I get locally is different than the layout I get from CoCalc.  

In my local sage, it seems that the vertices of the digraph are integers they are always laid from left to right according to their order as integers.

Nikos

William Stein

unread,
Jul 8, 2017, 4:13:49 PM7/8/17
to sage-s...@googlegroups.com
On Sat, Jul 8, 2017 at 12:16 PM Nikos Apostolakis <niko...@gmail.com> wrote:
Sorry for replying to my own post, but I realized that my post is ambiguous.  I meant that the problem persists even after I installed 7.6. The layout I get locally is different than the layout I get from CoCalc.  

In my local sage, it seems that the vertices of the digraph are integers they are always laid from left to right according to their order as integers.

The layout is likely being impacted by an optional Sage package that is installed on CoCalc’s sage, but not yours.
You’ll probably have to dive into the source code to get at which/what/why...



Nikos


On Saturday, July 8, 2017 at 8:04:57 AM UTC-4, Nikos Apostolakis wrote:
On Friday, July 7, 2017 at 12:57:08 PM UTC-4, Nikos Apostolakis wrote:

On Friday, July 7, 2017 at 10:41:18 AM UTC-4, William wrote:

On Fri, Jul 7, 2017 at 4:33 AM Nikos Apostolakis <niko...@gmail.com> wrote:
Dear group,

The following:

   sage: foo = DiGraph([(1,4), (1,5), (2,4), (3,5)])
   sage: foo.show(layout = 'acyclic')

produces different output in CoCalc and in my local copy of Sage (7.2) and , see the attached images.  The difference is much more pronounced in other examples.  

Can I get my local copy to produce the same result as in CoCalc?

What happens if you install the latest stable release (7.6) of Sage locally?  Sage v 7.2 is pretty old.


Thanks for the reply.

I'll upgrade and let you know if this solves the problem.  


I installed 7.6 and the output is still the same.

Nikos

--
You received this message because you are subscribed to the Google Groups "sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sage-support...@googlegroups.com.
To post to this group, send email to sage-s...@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.
--
-- William Stein

Nikos Apostolakis

unread,
Jul 8, 2017, 4:49:00 PM7/8/17
to sage-support
On Saturday, July 8, 2017 at 4:13:49 PM UTC-4, William wrote:

On Sat, Jul 8, 2017 at 12:16 PM Nikos Apostolakis <niko...@gmail.com> wrote:
Sorry for replying to my own post, but I realized that my post is ambiguous.  I meant that the problem persists even after I installed 7.6. The layout I get locally is different than the layout I get from CoCalc.  

In my local sage, it seems that the vertices of the digraph are integers they are always laid from left to right according to their order as integers.

The layout is likely being impacted by an optional Sage package that is installed on CoCalc’s sage, but not yours.
You’ll probably have to dive into the source code to get at which/what/why...



Thanks for the reply.  I will look at the source code.

Nikos

Nikos Apostolakis

unread,
Jul 13, 2017, 2:52:13 PM7/13/17
to sage-support
Ok, so I finally got around to it. 

As William suggested, this occurred because I didn't have graphviz and dot2tex install in my local box.  I installed them and now everything works fine.

Thanks for your help,
Nikos
Reply all
Reply to author
Forward
0 new messages