[Date Index]
[Thread Index]
[Author Index]
Re: Getting Mathematica CellTags to export to TeX?
*To*: mathgroup at smc.vnet.net
*Subject*: [mg67154] Re: Getting Mathematica CellTags to export to TeX?
*From*: bghiggins at ucdavis.edu
*Date*: Sun, 11 Jun 2006 02:17:02 -0400 (EDT)
*References*: <e6e1kb$1kg$1@smc.vnet.net>
*Sender*: owner-wri-mathgroup at wolfram.com
Craig,
Here is one possible way. The essential idea is to turn the CellTags
information into Text cells.
Let us suppose I have the following notebook with a title and two
entries with CellTags
Notebook[{Cell[CellGroupData[{
Cell[My Title, Title, TextAlignment -> Center, TextJustification
-> 0],
Cell[Plateau's Problem, Text, CellTags -> {mytag:
Zero Mean Curvature, mytag:Capillarity}],
Cell[Young-Laplace
Equation, Text, CellTags -> {mytag:Two-Dimensional,
mytag:Finite Element
Method, mytag:Capillarity}]}, Open]]}, FrontEndVersion ->
5.2 for Macintosh, ScreenRectangle -> {{0,
1280}, {0,
964}}, WindowToolbars -> EditBar, WindowSize -> {764, 761},
WindowMargins -> {{
Automatic, 252}, {70, Automatic}}, CellLabelAutoDelete ->
True]
I Use Save=>Save As Special=>Notebook Expression
and I save it as myTest.m
Then I open up a new notebook
and import that notebook expression using
data = Import["/Users/brian/Desktop/myTest.m"]
Now I use a rule to change the cell structure of the notebook using
data2 = data /.
Cell[X_String, "
Text", CellTags -> List[x__]] :> Sequence[Cell[RowBox[{x}], "Text",
TextAlignment -> Left], Cell[X, "Text"]]
Then I creat a new notebook using
NotebookPut[data2]
which I can then save as TeX file. The CellTags entries will now be
visible. There are more ways to embelish the CellTags by using an
approppriate cell structure.
Hope this helps or at least gives you some ideas,
Cheers,
Brian
W. Craig Carter wrote:
> Hello,
> I have very many notebooks that I have
> indexed carefully with CellTags.
> I'd like to export all of them to LaTeX and
> then use the CellTags to create index
> entries.
>
> *Any* solution, however kludgy, will save me
> lots of time. And would be geatly
> appreciated.
>
>
> I simply want to have each celltag be printed
> as text near its cell in the latex
> conversion. E.g.,
> Cell["Plateau's Problem", "Text",
> CellTags->{"mytag:Zero Mean
> Curvature","mytag:Capillarity"}]
>
> Should get mapped to something like:
> ----
> mytag:Zero Mean Curvature
> mytag:Capillarity
>
> Plateau's Problem
> --------
> in the TeX conversion.
>
> W. Craig Carter
Prev by Date:
**Re: Selecting Real Roots, Again**
Next by Date:
**Re: List Comparison**
Previous by thread:
**Getting Mathematica CellTags to export to TeX?**
Next by thread:
**No StringCompare in Mathematica?**
| |