I know it is an easy and quite specific request but I've been on it all day and I cannot really understand what's wrong!
\documentclass[12pt,a4paper]{report}
\usepackage[T1]{fontenc}
\usepackage[italian]{babel}
\usepackage[utf8]{inputenc}
\usepackage{amssymb,amsthm,mathtools}
\usepackage{amsmath, textcomp}
\usepackage{titling}
\theoremstyle{definition}
\newtheorem{Gcal}{Grande Caloria \textit{Cal} o \textit{kcal}}[section]
\theoremstyle{definition}
\newtheorem{Pcal}[Gcal]{Piccola Caloria \textit{cal}}
\theoremstyle{definition}
\newtheorem{CalS}[Pcal]{Calore Specifico}
\begin{document}
\chapter{1}
blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah
\chapter{2}
\section{2.1}
blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah
\begin{itemize}
\itemsep0em
\item[] \begin{Gcal}
blah blah blah blah blah blah blah blah blah blah blah blah blah blah
\end{Gcal}
\item[] \begin{Pcal}
blah blah blah blah blah blah blah blah blah blah blah blah blah
\end{Pcal}
\end{itemize}
blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah
\begin{CalS}
blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah
\end{CalS}
\end{document}
Errors Report
! LaTeX Error: No counter 'Pcal' defined. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... l.22 \newtheorem{CalS}[Pcal]{Calore Specifico} Your command was ignored.
! LaTeX Error: Environment CalS undefined. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... l.45 \begin{CalS} Your command was ignored. Type I to replace it with another command, or to continue without it. ! LaTeX Error: \begin{document} ended by \end{CalS}. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... l.47 \end{CalS} Your command was ignored.
! LaTeX Error: \begin{document} ended by \end{CalS}. See the LaTeX manual or LaTeX Companion for explanation. Type H for immediate help. ... l.47 \end{CalS} Your command was ignored.
Can someone explain what did I do wrong? Why only the third enviroment gives problem even if I've copyed/pasted them all?
\documentclass{...}
, the required\usepackage
's,\begin{document}
, and\end{document}
. That may seem tedious to you, but think of the extra work it represents for TeX.SX users willing to give you a hand. Help them help you: remove that one hurdle between you and a solution to your problem.Pcal
counter, because thePcal
environment is defined to share theGcal
counter. Try\newtheorem{CalS}[Gcal]{Calore Specifico}
and it will work.