I was wondering if there is a command to change the counter to adjust its numbeing to having different chapters saved as separate files. This seems possible with page numbers but not section numbers.

  • $\begingroup$ Could you elaborate? This question is not entirely clear to me. $\endgroup$ – Sjoerd C. de Vries May 28 '13 at 13:37
  • $\begingroup$ I am writing a book using Mathematica. If I save in 2 files, the 2nd file will restart numbering at Chapter 1. There is a way to fix page numbers for printing, but I am not aware of one for chapter numbers. Thanks. $\endgroup$ – Nero Jun 3 '13 at 23:11

In the notebook you want to have the chapter be numbered other than 1, select the title cell (to which you have inserted automatic numbering for "Title", assuming your chapter titles are in cells of style "Title" -- otherwise change as needed). Go to the Options Inspector and search for CounterAssigments. Add {"Title", 1}, to the list to have the chapter numbered 2, or {"Title", 2}, to have the chapter numbered 3, etc.

The whole list for CounterAssignments will (probably) look like this:

{{"Title", 1}, {"Section", 0}, {"Equation", 0}, {"Figure", 0},
 {"Subtitle", 0}, {"Subsubtitle", 0}, {"Item", 0}, {"Subitem", 0},
 {"Subsubitem", 0}, {"ItemNumbered", 0}, {"SubitemNumbered", 0},
 {"SubsubitemNumbered", 0}}
  • $\begingroup$ Reference (John Fultz) $\endgroup$ – Mr.Wizard Jul 21 '13 at 7:12
  • $\begingroup$ @Mr.Wizard Yes, although I learned it from Stan Wagon some years ago, who probably learned it from someone else, perhaps John! :). I was going to answer, got interrupted, and John beat me - with a better answer most likely. Later, checking for a duplicate, I found this neglected question. $\endgroup$ – Michael E2 Jul 21 '13 at 13:25
  • $\begingroup$ Michael, pardon me, I just realized how that "reference" comment might have been taken (poorly). I only meant to provide a supporting example from what I consider an authoritative source, and I did not mean to imply you were not yourself a trustworthy source of information. $\endgroup$ – Mr.Wizard Jul 22 '13 at 14:46
  • $\begingroup$ @Mr.Wizard No problem. It occurred to me there were (at least) two ways to take the comment - one was to connect the two questions, valuable in itself. Another was as an acknowledgement of a source, which I extended. Your rationale is a third, and worthwhile, given the somewhat scant documentation on counter options. The fourth (the implication) would not have occurred to me. $\endgroup$ – Michael E2 Jul 22 '13 at 15:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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