In a certain document, I want to make the two counters “theorem” and “subsection” to be one and the same thing. Any ideas?
Edit: Since the math parts are potentially confusing, I rephrase the question as follows without any such references.
I use a certain counter “mycounter” for counting something, and this counter is predefined in a certain package. When the subsection goes up, I want “mycounter” to go up. And vice-versa. When subsection is reset, I want “mycounter” to be reset.
This is what I hope to achieve by identifying the two counters.
Herbert Sizt is almost there.
\newtheorem{theorem}{Theorem}[subsection]would number theorems within subsections (ie, the theorems within Section 1.2 would be 1.2.1, 1.2.2, etc). Instead\newtheorem{theorem}[subsection]{Theorem}appears to do what the OP requires. Section 1.5 (say) would be followed by theorem 1.6, which would be followed by section 1.7. The theorem is formatted differently from sections.An alternative way is to do
That’s slightly more ‘home-made’, but makes the theorems have exactly the same layout as
\subsection, which may or may not be what’s required.