Update:
- Up to trivial comments, the default latex output has not changed
since Sage 6.7beta3 (at least). view fails similarly with that
version.
- A slightly smaller example:
sage: t = Partition([1])
sage: G = DiGraph([[t,t]], loops=True)
sage: latex(G)
\begin{tikzpicture}
\definecolor{cv0}{rgb}{0.0,0.0,0.0}
\definecolor{cfv0}{rgb}{1.0,1.0,1.0}
\definecolor{clv0}{rgb}{0.0,0.0,0.0}
\definecolor{cv0v0}{rgb}{0.0,0.0,0.0}
%
\Vertex[style={minimum
size=1.0cm,draw=cv0,fill=cfv0,text=clv0,shape=circle},LabelOut=false,L=\hbox{${\def\lr#1{\multicolumn{1}{|@{\hspace{.6ex}}c@{\hspace{.6ex}}|}{\raisebox{-.3ex}{$#1$}}}
\raisebox{-.6ex}{$\begin{array}[b]{*{1}c}\cline{1-1}
\lr{\phantom{x}}\\\cline{1-1}
\end{array}$}
}$},x=2.5cm,y=2.5cm]{v0}
%
\Loop[dist=3.0cm,dir=NO,style={color=cv0v0,},](v0)
%
\end{tikzpicture}
sage: view(G)
**boom**
So I suspect that either that error went undetected for a long time,
or it comes from a change in tikz which makes the above code more
fragile.
Anyone a suggestion on how to tweak the above output to make it robust?
Cheers,
Nicolas
On Wed, May 31, 2017 at 09:16:05AM -0400, Nicolas M. Thiery wrote:
> Remember that graphs can be latex rendered in two ways: either by
> having Sage produce tikz manually (1), or through dot2tex (2). For
> general graphs, the former is the default. For graphs produced from
> crystals, the default is to use (2) if dot2tex is installed, and (1)
> otherwise. At the end the issue is not in dot2tex: its presence just
> hides the bug.
>
> Here is my current minimal example, which breaks independently of
> dot2tex:
>
> sage: t = StandardTableaux(4).random_element()
> sage: G = DiGraph([[t,t]], loops=True)
> sage: latex(G)
> **produces something**
> sage: view(G)
> **boom**
>
> On Tue, May 30, 2017 at 11:43:13PM -0700, Dima Pasechnik wrote:
> > I can confirm that
> > B = crystals.Tableaux(['A',2], shape=[2,1]); view(B, tightpage=True)
> > does not work with the latest Sage beta.
> > It looks as if some tikz-related stuff in the TeX file header
> > is messed up.
> > On Wednesday, May 31, 2017 at 7:38:29 AM UTC+1, Dima Pasechnik wrote:
> >
> > Perhaps SMC people can explain where the discrepancy in the TeX output
> > comes from.
> > I cc to the relevant group.
> > On Monday, May 29, 2017 at 9:48:45 PM UTC+1, Julie Beier wrote:
> >
> > I have been trying to use the tableaux crystal pictures in Sage and,
> > while it works on the cloud, it does not work on my computer. I have
> > updated Sage (then reverted to the version of Sage used on the cloud),
> > updated on my LaTeX packages, and installed dot2tex. The code I'm
> > using is from the help pages: B = crystals.Tableaux(['A',2],
> > shape=[2,1]); view(B, tightpage=True). The Tex files generated by the
> > cloud and by my computer are different. The one generated by the cloud
> > compiles, but the one from my computer does not. I've attached these.
> > Any ideas? Thanks for your help!
> >
> > --
> > You received this message because you are subscribed to the Google
> > Groups "sage-combinat-devel" group.
> > To unsubscribe from this group and stop receiving emails from it, send
> > an email to [1][email protected].
> > To post to this group, send email to
> > [2][email protected].
> > Visit this group at
> > [3]https://groups.google.com/group/sage-combinat-devel.
> > For more options, visit [4]https://groups.google.com/d/optout.
> >
> > References
> >
> > 1. mailto:[email protected]
> > 2. mailto:[email protected]
> > 3. https://groups.google.com/group/sage-combinat-devel
> > 4. https://groups.google.com/d/optout
>
> Nicolas
> --
> Nicolas M. Thiéry "Isil" <[email protected]>
> http://Nicolas.Thiery.name/
>
> --
> You received this message because you are subscribed to the Google Groups
> "sage-combinat-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at https://groups.google.com/group/sage-combinat-devel.
> For more options, visit https://groups.google.com/d/optout.
Nicolas
--
Nicolas M. Thiéry "Isil" <[email protected]>
http://Nicolas.Thiery.name/
--
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.