Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I would like to write a book using Mathematica, but I will write one chapter on several files. How to tell Mathematica that the BookChapterNumber pointer has the value pointing to the next file in the same chapter ?

share|improve this question
3  
Hi wono. Is this QandA any use? –  cormullion Sep 20 '13 at 9:00
    
Yes you are right. Thank you very much. –  wono Sep 20 '13 at 13:56

1 Answer 1

I wrote a book with Mathematica 10 years ago. The way I set it up was to create a counter called "Chapter" but you could also use "Title". In your title style you need to ensure all counters are reset. Also in the section style you will want to reset the subsection counter etc.

Cell[StyleData["Title"],
...
 CounterAssignments->{{"Section", 0}, {"Subsection", 0}, {"Subsubsection", 0}, {"FigureCaption", 0}, {"Table", 0}, {"BulletedList", 0}, {"EquationNumbered", 0} etc etc},
...]

To number equations you need to include the chapter counter:

Cell[StyleData["EquationNumbered"],
...
 CellFrameLabels->{{None, 
    Cell[
     TextData[{"(", 
       CounterBox["Chapter"], ".", 
       CounterBox["EquationNumbered"], ")   "}]]}, {None, None}},
...]

In each chapter notebook include the chapter counter in the title cell:

Cell["Your Title for Chapter 3", "Title",
 CounterAssignments->{{"Chapter", 3}}]

And add the chapter counter to your sections:

Cell[TextData[{
 CounterBox["Chapter"],".",CounterBox["Section"],
 "\tSection Title"
}], "Section"]

Cell[BoxData[
 FormBox[Cell["x+1"], TraditionalForm]], "EquationNumbered"]

enter image description here

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.