summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/subeqn/subeqn.sty
blob: fab4e5ddebfea6b6da878b729f8d2ca1d52acd1a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
%%
%% This is file `subeqn.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% subeqn.dtx  (with options: `package')
%% This is a generated file.
%% 
%% Copyright (C) 1999-2024 Johannes Braams. All rights reserved.
%% 
%% This file was generated from file(s) of the subeqn package.
%% -----------------------------------------------------------
%% 
%% It may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3с
%% of this license or (at your option) any later version.
%% The latest version of this license is in
%%   http://www.latex-project.org/lppl.txt
%% and version 1.3с or later is part of all distributions of LaTeX
%% version 2008 or later.
%% 
%% This work has the LPPL maintenance status "maintained".
%% 
%% The Current Maintainer of this work is Johannes Braams.
%% 
%% This file may only be distributed together with a copy of the
%% subeqn package. You may however distribute the subeqn package
%% without such generated files.
%% 
%% The list of all files belonging to the subeqn package is
%% given in the file `MANIFEST'.
%% 
%% The list of derived (unpacked) files belonging to the distribution
%% and covered by LPPL is defined by the unpacking scripts (with
%% extension .ins) which are part of the distribution.
\NeedsTeXFormat{LaTeX2e}[1998/06/01]
\ProvidesPackage{subeqn}
              [2024/07/21 v2.0c subnumbering of equations]
\newenvironment{subequations}{%
  \refstepcounter{equation}%
  \mathchardef\c@mainequation\c@equation
  \protected@edef\themainequation{\theequation}%
  \let\theequation\thesubequation
  \global\c@equation\z@
  }{%
  \global\c@equation\c@mainequation
  \global\@ignoretrue
  }
\newcommand{\thesubequation}{\themainequation\alph{equation}}
\newenvironment{subeqnarray}{%
  \subequations
  \@ifnextchar\label{\@lab@subeqnarray}{\eqnarray}
  }{%
  \endeqnarray\endsubequations
  }
\newcommand*{\@lab@subeqnarray}[2]{#1{#2}\eqnarray}
\endinput
%%
%% End of file `subeqn.sty'.