1

I would like to define some new mathematical statements in my documents. With the capability of using some numbering system, I thought about using section as shown. But would like to know what possibilities exist.

I wish to have a title for myDefn. Currently the text is printed on the same line but would like to have only the title next to the definition number, With the actual text starting on the next line.

Although one could have all theorems under the same numbering scheme. And corollary under a different numbering scheme, I find that confusing at times, because a corollary is most often a follow up to a theorem.

\documentclass{article}

\newtheorem{myDefn}{Definition}[section]

\begin{document}

\section{Mathematical Statements}

\begin{myDefn} A \textit{prime number} is a natural number greater than 1 that has no positive divisors other than 1 and itself. \end{myDefn}

\end{document}

Veak
  • 1
  • 1
    Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Oct 09 '23 at 19:09
  • 3
    @Raksh, second hint from me today: your code needs to start with \documentclass, end with \end{document}, show your problem AND compile. By doing so you take away many comments, clarify your situation and obtain better answers. Please take that seriously. Thank you – MS-SPO Oct 09 '23 at 19:17
  • 2
    Nice that you finally gave up on the underscores! ... but a MWE would be even nicer. – samcarter_is_at_topanswers.xyz Oct 09 '23 at 19:30
  • Would it be better to define a completely new environment so as not to mess up with the standard ones ? – Veak Oct 09 '23 at 20:00
  • 1
    People tell you that it will depend on the class. And what's your reaction? A code fragment without a class ... – samcarter_is_at_topanswers.xyz Oct 09 '23 at 20:03
  • 4
    @Raksh 'better' depends really on what you want: we are going to need some wider context to have a chance to help – Joseph Wright Oct 09 '23 at 20:04
  • 1
    OK that's better I'll retract my close vote and delete my answer (as it no longer matches the question) – David Carlisle Oct 09 '23 at 20:44
  • See https://tex.stackexchange.com/a/37806/36296 or https://tex.stackexchange.com/a/257360/36296 how to add a linebreak after the title – samcarter_is_at_topanswers.xyz Oct 09 '23 at 20:49
  • I am not quite sure whether one can categorise by subsection, subsubsection, as well. Would that make any sense ? – Veak Oct 09 '23 at 21:00
  • 1
    How to categorise your theorems is not a latex problem. – samcarter_is_at_topanswers.xyz Oct 09 '23 at 21:01
  • I am only saying so, because I used [section] in my \newtheorem{myDefn}{Definition}[section]. – Veak Oct 09 '23 at 21:21
  • Is the style just for your own use or do you intend for others to use it, as your(?) earlier questions suggested? Because if it is just for you, you don't need to worry about people wanting to use styles you don't know about or about them loading amsthm or whatever. If you plan to share it, that's obviously a very different case. – cfr Oct 10 '23 at 02:13

0 Answers0