Someone provided me the following class called existingclass.cls:


  right = 1in,
  left = 1.5in,
  top = 1in,
  bottom = 1in

\renewcommand{\contentsname}{TABLE OF CONTENTS} 

        \ifnum \c@secnumdepth >\m@ne
            \bfseries CHAPTER \thechapter
            \vskip 20\p@    
        \bfseries #1\par\nobreak
        \vskip 30\p@
        \bfseries  #1\par\nobreak
        \vskip 30\p@

and is loaded to the following tex file:


    \addcontentsline{toc}{chapter}{TABLE OF CONTENTS}

having inserted the following (minimal) chapter1.tex:

\chapter{THE PROBLEM}

When you run this code, it will output the following:

enter image description here enter image description here

MY QUESTION: How do I change the chapter (header) numbering found in the document to Arabic while retaining the chapter sectioning in the TOC (Table of Contents) to Roman Numerals?

I looked for the following similar problems:

Chapter Roman in tableofcontents

Roman number in chapter header but not in TOC

Roman numerals for table of contents, arabic for main text in footer

Change number after chapter in table of contents

Chapter headings and table of contents

Roman Numerals in ToC : Error in \settowidth

Table of contents with roman, arabic, and no page numbers

Page numbering with a mixed Roman numeral-Arabic numeral format

Roman numbering of pages on ToC, but arabic on document

Page numbering resets after table of contents (roman/arabic)

but none, so far, answered my question

P.S.: I am not an expert in pure TeX codes. :)

  • Are you sure you are allowed to share the class and/or change its name?
    – Johannes_B
    Commented Dec 14, 2019 at 4:23
  • @Johannes_B Any particular reason to think not?
    – cfr
    Commented Dec 14, 2019 at 5:14
  • \thechapter -> \arabic{chapter}? Are you expert in impure TeX codes? They're definitely the best kind ;).
    – cfr
    Commented Dec 14, 2019 at 5:16
  • @cfr License stuff.
    – Johannes_B
    Commented Dec 14, 2019 at 5:17
  • @Johannes_B Yes, but we don't routinely ask this about class files, so why this one? Or would you ask this about any code an OP included which the OP wanted to adapt?
    – cfr
    Commented Dec 14, 2019 at 5:27


You must log in to answer this question.

Browse other questions tagged .