]> git.lyx.org Git - lyx.git/blob - lib/layouts/theorems-ams-extended-chap-bytype.module
update layout formats
[lyx.git] / lib / layouts / theorems-ams-extended-chap-bytype.module
1 #\DeclareLyXModule{AMS Theorems (Extended, Numbered by Type within Chapters)}
2 #\DeclareCategory{Maths}
3 #DescriptionBegin
4 #Defines some additional theorem environments for use with the
5 #AMS theorems packages. Includes Criterion, Algorithm, Axiom,
6 #Condition, Note, Notation, Summary, Acknowledgement, Conclusion,
7 #Assumption, and Case, in both numbered and non-numbered forms.
8 #Contrary to the plain AMS-Extended module, the different theorem
9 #types provided here each have a separate counter, restarted with each
10 #new chapter (e.g., criterion 1.1, criterion 1.2, axiom 1.1, assumption 1.1, #criterion 2.1, criterion 2.2, axiom 2.1..., as opposed to criterion 1,
11 #criterion 2, axiom 3, assumption 4...)
12 #DescriptionEnd
13 #Requires: theorems-ams-chap-bytype
14
15 # Original Author : David L. Johnson <dlj0@lehigh.edu>
16 # Probably broken by Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
17 # modified and modularized by Emmanuel GUREGHIAN <gureghia@boston.bertin.fr>
18 # Tinkered with Sep. '07 by Paul Rubin <rubin@msu.edu>
19 # Modularized Jan 08 by Richard Heck <rgheck@comcast.net>
20 # Hacked June '09 by Paul Rubin <rubin@msu.edu> to use separate counters
21 # Chapter dependence added Oct '16 by Andrew Parsloe <aparsloe@clear.net.nz>
22
23 Format 78
24
25 Requires        amsmath
26
27 # The environnements defined (regular and starred) are :
28 # - Criterion
29 # - Algorithm
30 # - Axiom
31 # - Condition
32 # - Note
33 # - Notation
34 # - Summary
35 # - Acknowledgement
36 # - Conclusion
37 # - Assumption
38 # - Question
39
40 # We need separate counters for each theorem-like style.
41 Counter criterion
42 End
43 Counter algorithm
44 End
45 Counter axiom
46 End
47 Counter condition
48 End
49 Counter note
50 End
51 Counter notation
52 End
53 Counter summary
54 End
55 Counter acknowledgement
56 End
57 Counter conclusion
58 End
59 Counter assumption
60 End
61 Counter question
62 End
63
64
65 # additional (AMS-extended) environments
66
67 Style Criterion
68         CopyStyle             Theorem
69         LatexName             criterion
70         LabelString           "Criterion \thechapter.\thecriterion."
71         Preamble
72           \theoremstyle{plain}
73     \ifx\thechapter\undefined
74       \newtheorem{criterion}{\protect\criterionname}
75     \else
76       \newtheorem{criterion}{\protect\criterionname}[chapter]
77     \fi
78         EndPreamble
79         LangPreamble
80           \providecommand{\criterionname}{_(Criterion)}
81         EndLangPreamble
82         BabelPreamble
83           \addto\captions$$lang{\renewcommand{\criterionname}{_(Criterion)}}
84         EndBabelPreamble
85         LabelCounter          criterion
86 End
87
88
89 Style Criterion*
90         CopyStyle             Theorem*
91         LatexName             criterion*
92         LabelString           "Criterion."
93         Preamble
94           \theoremstyle{plain}
95           \newtheorem*{criterion*}{\protect\criterionname}
96         EndPreamble
97         LangPreamble
98           \providecommand{\criterionname}{_(Criterion)}
99         EndLangPreamble
100         BabelPreamble
101           \addto\captions$$lang{\renewcommand{\criterionname}{_(Criterion)}}
102         EndBabelPreamble
103 End
104
105
106 Style Algorithm
107         CopyStyle             Theorem
108         LatexName             lyxalgorithm
109         LabelString           "Algorithm \thechapter.\thealgorithm."
110         Preamble
111           \theoremstyle{plain}
112     \ifx\thechapter\undefined
113       \newtheorem{lyxalgorithm}{\protect\algorithmname}
114     \else
115       \newtheorem{lyxalgorithm}{\protect\algorithmname}[chapter]
116     \fi
117         EndPreamble
118         LangPreamble
119           \providecommand{\algorithmname}{_(Algorithm)}
120         EndLangPreamble
121         BabelPreamble
122           \addto\captions$$lang{\renewcommand{\algorithmname}{_(Algorithm)}}
123         EndBabelPreamble
124         LabelCounter          algorithm
125 End
126
127
128 Style Algorithm*
129         CopyStyle             Theorem*
130         LatexName             lyxalgorithm*
131         LabelString           "Algorithm."
132         Preamble
133           \theoremstyle{plain}
134           \newtheorem*{lyxalgorithm*}{\protect\algorithmname}
135         EndPreamble
136         LangPreamble
137           \providecommand{\algorithmname}{_(Algorithm)}
138         EndLangPreamble
139         BabelPreamble
140           \addto\captions$$lang{\renewcommand{\algorithmname}{_(Algorithm)}}
141         EndBabelPreamble
142 End
143
144
145 Style Axiom
146         CopyStyle             Theorem
147         LatexName             ax
148         LabelString           "Axiom \thechapter.\theaxiom."
149         Preamble
150           \theoremstyle{plain}
151     \ifx\thechapter\undefined
152       \newtheorem{ax}{\protect\axiomname}
153     \else
154       \newtheorem{ax}{\protect\axiomname}[chapter]
155     \fi
156         EndPreamble
157         LangPreamble
158           \providecommand{\axiomname}{_(Axiom)}
159         EndLangPreamble
160         BabelPreamble
161           \addto\captions$$lang{\renewcommand{\axiomname}{_(Axiom)}}
162         EndBabelPreamble
163         LabelCounter          axiom
164 End
165
166
167 Style Axiom*
168         CopyStyle             Theorem*
169         LatexName             ax*
170         LabelString           "Axiom."
171         Preamble
172           \theoremstyle{plain}
173           \newtheorem*{ax*}{\protect\axiomname}
174         EndPreamble
175         LangPreamble
176           \providecommand{\axiomname}{_(Axiom)}
177         EndLangPreamble
178         BabelPreamble
179           \addto\captions$$lang{\renewcommand{\axiomname}{_(Axiom)}}
180         EndBabelPreamble
181 End
182
183
184 Style Condition
185         CopyStyle             Definition
186         LatexName             condition
187         LabelString           "Condition \thechapter.\thecondition."
188         Preamble
189           \theoremstyle{definition}
190     \ifx\thechapter\undefined
191       \newtheorem{condition}{\protect\conditionname}
192     \else
193       \newtheorem{condition}{\protect\conditionname}[chapter]
194     \fi
195         EndPreamble
196         LangPreamble
197           \providecommand{\conditionname}{_(Condition)}
198         EndLangPreamble
199         BabelPreamble
200           \addto\captions$$lang{\renewcommand{\conditionname}{_(Condition)}}
201         EndBabelPreamble
202         LabelCounter          condition
203 End
204
205
206 Style Condition*
207         CopyStyle             Definition*
208         LatexName             condition*
209         LabelString           "Condition."
210         Preamble
211           \theoremstyle{definition}
212           \newtheorem*{condition*}{\protect\conditionname}
213         EndPreamble
214         LangPreamble
215           \providecommand{\conditionname}{_(Condition)}
216         EndLangPreamble
217         BabelPreamble
218           \addto\captions$$lang{\renewcommand{\conditionname}{_(Condition)}}
219         EndBabelPreamble
220 End
221
222
223 Style Note
224         CopyStyle             Remark
225         LatexName             note
226         LabelString           "Note \thechapter.\thenote."
227         Preamble
228           \theoremstyle{remark}
229     \ifx\thechapter\undefined
230       \newtheorem{note}{\protect\notename}
231     \else
232       \newtheorem{note}{\protect\notename}[chapter]
233     \fi
234         EndPreamble
235         LangPreamble
236           \providecommand{\notename}{_(Note)}
237         EndLangPreamble
238         BabelPreamble
239           \addto\captions$$lang{\renewcommand{\notename}{_(Note)}}
240         EndBabelPreamble
241         LabelCounter          note
242 End
243
244
245 Style Note*
246         CopyStyle             Remark*
247         LatexName             note*
248         LabelString           "Note."
249         Preamble
250           \theoremstyle{remark}
251           \newtheorem*{note*}{\protect\notename}
252         EndPreamble
253         LangPreamble
254           \providecommand{\notename}{_(Note)}
255         EndLangPreamble
256         BabelPreamble
257           \addto\captions$$lang{\renewcommand{\notename}{_(Note)}}
258         EndBabelPreamble
259 End
260
261
262 Style Notation
263         CopyStyle             Remark
264         LatexName             notation
265         LabelString           "Notation \thechapter.\thenotation."
266         Preamble
267           \theoremstyle{remark}
268     \ifx\thechapter\undefined
269       \newtheorem{notation}{\protect\notationname}
270     \else
271       \newtheorem{notation}{\protect\notationname}[chapter]
272     \fi
273         EndPreamble
274         LangPreamble
275           \providecommand{\notationname}{_(Notation)}
276         EndLangPreamble
277         BabelPreamble
278           \addto\captions$$lang{\renewcommand{\notationname}{_(Notation)}}
279         EndBabelPreamble
280         LabelCounter          notation
281 End
282
283
284 Style Notation*
285         CopyStyle             Remark*
286         LatexName             notation*
287         LabelString           "Notation."
288         Preamble
289           \theoremstyle{remark}
290           \newtheorem*{notation*}{\protect\notationname}
291         EndPreamble
292         LangPreamble
293           \providecommand{\notationname}{_(Notation)}
294         EndLangPreamble
295         BabelPreamble
296           \addto\captions$$lang{\renewcommand{\notationname}{_(Notation)}}
297         EndBabelPreamble
298 End
299
300
301 Style Summary
302         CopyStyle             Remark
303         LatexName             summary
304         LabelString           "Summary \thechapter.\thesummary."
305         Preamble
306           \theoremstyle{remark}
307     \ifx\thechapter\undefined
308       \newtheorem{summary}{\protect\summaryname}
309     \fi
310     \else
311       \newtheorem{summary}{\protect\summaryname}[chapter]
312     \fi
313         EndPreamble
314         LangPreamble
315           \providecommand{\summaryname}{_(Summary)}
316         EndLangPreamble
317         BabelPreamble
318           \addto\captions$$lang{\renewcommand{\summaryname}{_(Summary)}}
319         EndBabelPreamble
320         LabelCounter          summary
321 End
322
323
324 Style Summary*
325         CopyStyle             Remark*
326         LatexName             summary*
327         LabelString           "Summary."
328         Preamble
329           \theoremstyle{remark}
330           \newtheorem*{summary*}{\protect\summaryname}
331         EndPreamble
332         LangPreamble
333           \providecommand{\summaryname}{_(Summary)}
334         EndLangPreamble
335         BabelPreamble
336           \addto\captions$$lang{\renewcommand{\summaryname}{_(Summary)}}
337         EndBabelPreamble
338 End
339
340
341 Style Acknowledgement
342         CopyStyle             Remark
343         LatexName             acknowledgement
344         LabelString           "Acknowledgement \thechapter.\theacknowledgement."
345         Preamble
346           \theoremstyle{remark}
347     \ifx\thechapter\undefined
348       \newtheorem{acknowledgement}{\protect\acknowledgementname}
349     \else
350       \newtheorem{acknowledgement}{\protect\acknowledgementname}[chapter]
351     \fi
352         EndPreamble
353         LangPreamble
354           \providecommand{\acknowledgementname}{_(Acknowledgement)}
355         EndLangPreamble
356         BabelPreamble
357           \addto\captions$$lang{\renewcommand{\acknowledgementname}{_(Acknowledgement)}}
358         EndBabelPreamble
359         LabelCounter          acknowledgement
360 End
361
362
363 Style Acknowledgement*
364         CopyStyle             Remark*
365         LatexName             acknowledgement*
366         LabelString           "Acknowledgement."
367         Preamble
368           \theoremstyle{remark}
369           \newtheorem*{acknowledgement*}{\protect\acknowledgementname}
370         EndPreamble
371         LangPreamble
372           \providecommand{\acknowledgementname}{_(Acknowledgement)}
373         EndLangPreamble
374         BabelPreamble
375           \addto\captions$$lang{\renewcommand{\acknowledgementname}{_(Acknowledgement)}}
376         EndBabelPreamble
377 End
378
379
380 Style Conclusion
381         CopyStyle             Remark
382         LatexName             conclusion
383         LabelString           "Conclusion \thechapter.\theconclusion."
384         Preamble
385           \theoremstyle{remark}
386     \ifx\thechapter\undefined
387       \newtheorem{conclusion}{\protect\conclusionname}
388     \else
389       \newtheorem{conclusion}{\protect\conclusionname}[chapter]
390     \fi
391         EndPreamble
392         LangPreamble
393           \providecommand{\conclusionname}{_(Conclusion)}
394         EndLangPreamble
395         BabelPreamble
396           \addto\captions$$lang{\renewcommand{\conclusionname}{_(Conclusion)}}
397         EndBabelPreamble
398         LabelCounter          conclusion
399 End
400
401
402 Style Conclusion*
403         CopyStyle             Remark*
404         LatexName             conclusion*
405         LabelString           "Conclusion."
406         Preamble
407           \theoremstyle{remark}
408           \newtheorem*{conclusion*}{\protect\conclusionname}
409         EndPreamble
410         LangPreamble
411           \providecommand{\conclusionname}{_(Conclusion)}
412         EndLangPreamble
413         BabelPreamble
414           \addto\captions$$lang{\renewcommand{\conclusionname}{_(Conclusion)}}
415         EndBabelPreamble
416 End
417
418
419 Style Assumption
420         CopyStyle             Theorem
421         LatexName             assumption
422         LabelString           "Assumption \thechapter.\theassumption."
423         Preamble
424           \theoremstyle{plain}
425     \ifx\thechapter\undefined
426       \newtheorem{assumption}{\protect\assumptionname}
427     \else
428       \newtheorem{assumption}{\protect\assumptionname}[chapter]
429     \fi
430         EndPreamble
431         LangPreamble
432           \providecommand{\assumptionname}{_(Assumption)}
433         EndLangPreamble
434         BabelPreamble
435           \addto\captions$$lang{\renewcommand{\assumptionname}{_(Assumption)}}
436         EndBabelPreamble
437         LabelCounter          assumption
438 End
439
440
441 Style Assumption*
442         CopyStyle             Theorem*
443         LatexName             assumption*
444         LabelString           "Assumption."
445         Preamble
446           \theoremstyle{plain}
447           \newtheorem*{assumption*}{\protect\assumptionname}
448         EndPreamble
449         LangPreamble
450           \providecommand{\assumptionname}{_(Assumption)}
451         EndLangPreamble
452         BabelPreamble
453           \addto\captions$$lang{\renewcommand{\assumptionname}{_(Assumption)}}
454         EndBabelPreamble
455 End
456
457 Style Question
458         CopyStyle             Theorem
459         DependsOn             Theorem
460         LatexName             question
461         LabelString           "Question \thechapter.\thequestion."
462         Preamble
463           \theoremstyle{plain}
464     \ifx\thechapter\undefined
465       \newtheorem{question}{\protect\questionname}
466     \else
467       \newtheorem{question}{\protect\questionname}[chapter]
468     \fi
469         EndPreamble
470         LangPreamble
471           \providecommand{\questionname}{_(Question)}
472         EndLangPreamble
473         BabelPreamble
474           \addto\captions$$lang{\renewcommand{\questionname}{_(Question)}}
475         EndBabelPreamble
476         LabelCounter          question
477 End
478
479 Style Question*
480         CopyStyle             Theorem*
481         LatexName             question*
482         LabelString           "Question."
483         Preamble
484           \theoremstyle{plain}
485           \newtheorem*{question*}{\protect\questionname}
486         EndPreamble
487         LangPreamble
488           \providecommand{\questionname}{_(Question)}
489         EndLangPreamble
490         BabelPreamble
491           \addto\captions$$lang{\renewcommand{\questionname}{_(Question)}}
492         EndBabelPreamble
493 End
494
495 Input theorems-refprefix.inc