% \iffalse meta-comment -*- tab-width: 2; fill-column: 76; -*- % !TEX program = pdflatex % !Mode:: "DTX:UNIX:UTF-8" % % This is the source file for the DSTU bundle used with BibTeX, % heavily based on the GOST bundle. % % Current version is 1.4, 2025-02-24. % % It contains set of bibliographic styles that % attempt to format the bibliography according to % DSTU 8302:2015 with some conventional modifications. % % For a bibliographic entry in Ukrainian or Russian you need % to add the field % language = {ukrainian} % or % language = {russian} % correspondingly. % % German, French, Italian languages are % also partially supported. Default language is English. % % Advices and bug reports about what in particular is not currently % implemented (but should be) for Ukrainian language are welcome. % % Book entry should have the pagetotal field % showing total number of pages. Optional field % url will format URL (using hyperref, if loaded). % % See examples in dstu2015*.pdf. % % Requires 8-bit bibtex with switch -B and csf file supporting cyrillic. % bibtex8 -B -c .csf % % Alternatively, you can use Unicode version of bibtex. % bibtexu -B -l ukr -o ukr % % Download from https://codeberg.org/mdmisch/dstu . % % To unpack run % pdflatex dstu.dtx % To produce the documentation run % pdflatex dstu.dtx \ % makeindex -r -s gind.ist dstu % makeindex -r -s gglo.ist -o dstu.gls dstu.glo % pdflatex dstu.dtx % pdflatex dstu.dtx % To succeed you must have Cyrillic fonts (LH of cm-super) installed. % %<*internal> \iffalse % %<*internal> \fi \def\nameofplainTeX{plain} \ifx\fmtname\nameofplainTeX\else \expandafter\begingroup \fi \input docstrip.tex \keepsilent \askforoverwritefalse \preamble ------------------------------------------------------------------- This file is a part of DSTU package, which is a bundle of BibTEX styles to format bibliographic references according to DSTU 8302:2015. Current version is 1.4, 2025/02/24. Released under the LaTeX Project Public License v1.3c or later See http://www.latex-project.org/lppl.txt ------------------------------------------------------------------- Copyright 2022-2025 Mykhailo Mishchenko Version 1.4 Copyright 2012-2020 Igor A. Kotelnikov. Copyright 2017 Leonid Sinev. Version 1.2k* of the original GOST bundle Copyright 1996-2005 Maksym Polyakov. Version 2005.08.12 of the original GOST bundle Released under the LaTeX Project Public License v1.3c or later See https://www.latex-project.org/lppl.txt Current version is 1.4, 2025/02/25. This work is derived from the GOST bundle. The only way this work is related to the authors of the GOST package is that it is based on their code. In particular, this means that all requests for support, including (but not limited to) the reporting and handling of errors in the DSTU package should be directed to its current maintainer and not to the authors of the GOST package. This work has the LPPL maintenance status `maintained'. The Current Maintainer of this work is Mykhailo Mishchenko. Please, send bug report via e-mail: mdmisch@firemail.cc or via an issue tracker at https://codeberg.org/mdmisch/dstu/issues . Please, don't write me to the @firemail.cc address from Gmail, because Google will silently drop my reply. It will not even appear in Spam folder. If you really need to use your Gmail email, you can use an alternative email address: mdmisch@protonmail.com ------------------------------------------------------------------- This work consists of the file dstu.dtx and the derived files dstu.pdf, dstu*.bst, udstu*.bst, uudstu*.bst. It also contains some examples (*.tex, *.pdf files). ------------------------------------------------------------------- \endpreamble % %<*install> \input docstrip \usedir{source/bibtex/dstu} \askonceonly \nopostamble %%\ProvidesFile{dstu.ins}[2024/02/10 1.3] \generate{% %% BST styles that mimics DSTU 8302:2015 for bibliographic *references* \file{dstu2015.bst} {\from{dstu.dtx} {bst,eprint,dstu2015}} \file{dstu2015l.bst} {\from{dstu.dtx} {bst,eprint,long,dstu2015}} %% %% Same styles with sorting \file{dstu2015s.bst} {\from{dstu.dtx} {bst,eprint,sort,dstu2015}} \file{dstu2015ls.bst} {\from{dstu.dtx} {bst,eprint,long,sort,dstu2015}} %% ` %% -------------------------------------------------------------------------- %% Unicode BST styles that mimics DSTU 8302:2015 for bibliographic *references* %% (for BibTeX implementations other than bibtexu) \file{udstu2015.bst} {\from{dstu.dtx} {bst,utf8,eprint,dstu2015}} \file{udstu2015l.bst} {\from{dstu.dtx} {bst,utf8,eprint,long,dstu2015}} %% %% Same styles with sorting \file{udstu2015s.bst} {\from{dstu.dtx} {bst,utf8,eprint,sort,dstu2015}} \file{udstu2015ls.bst} {\from{dstu.dtx} {bst,utf8,eprint,long,sort,dstu2015}} %% %% -------------------------------------------------------------------------- %% Unicode BST styles that mimics DSTU 8302:2015 for bibliographic *references* %% (for BibTeX implementation bibtexu) \file{uudstu2015.bst} {\from{dstu.dtx} {bst,utf8,eprint,dstu2015,bibtexu}} \file{uudstu2015l.bst} {\from{dstu.dtx} {bst,utf8,eprint,long,dstu2015,bibtexu}} %% %% Same styles with sorting \file{uudstu2015s.bst} {\from{dstu.dtx} {bst,utf8,eprint,sort,dstu2015,bibtexu}} \file{uudstu2015ls.bst} {\from{dstu.dtx} {bst,utf8,eprint,long,sort,dstu2015,bibtexu}} %% %% -------------------------------------------------------------------------- %% Experimental styles compatible with natbib package. \file{dstu2015n.bst} {\from{dstu.dtx} {bst,natbib,eprint,dstu2015}} \file{dstu2015ns.bst} {\from{dstu.dtx} {bst,natbib,eprint,sort,dstu2015}} %% \file{udstu2015n.bst} {\from{dstu.dtx} {bst,utf8,natbib,eprint,dstu2015}} \file{udstu2015ns.bst} {\from{dstu.dtx} {bst,utf8,natbib,eprint,sort,dstu2015}} %% \file{uudstu2015n.bst} {\from{dstu.dtx} {bst,utf8,natbib,eprint,dstu2015,bibtexu}} \file{uudstu2015ns.bst} {\from{dstu.dtx} {bst,utf8,natbib,eprint,sort,dstu2015,bibtexu}} %% %% -------------------------------------------------------------------------- %% DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) refactored styles \file{dstu2006.bst} {\from{dstu.dtx} {bst,strict,eprint}} \file{dstu2006s.bst} {\from{dstu.dtx} {bst,strict,eprint,sort}} \file{udstu2006.bst} {\from{dstu.dtx} {bst,utf8,strict,eprint}} \file{udstu2006s.bst} {\from{dstu.dtx} {bst,utf8,strict,eprint,sort}} \file{uudstu2006.bst} {\from{dstu.dtx} {bst,utf8,strict,eprint,bibtexu}} \file{uudstu2006s.bst} {\from{dstu.dtx} {bst,utf8,strict,eprint,sort,bibtexu}} } % %\endbatchfile %<*internal> \ifx\fmtname\nameofplainTeX \expandafter\endbatchfile \else \expandafter\endgroup \fi % %<*driver> \ProvidesFile{dstu.dtx}[2025/02/24 v.1.4 BibTEX support for DSTU 8302:2015 bibliographies] \NeedsTeXFormat{LaTeX2e} \documentclass{ltxdoc} \usepackage{geometry} \usepackage{ifluatex,ifxetex} \ifnum 0\ifxetex 1\fi\ifluatex 1\fi>0 \usepackage{fontspec} \defaultfontfeatures{Ligatures={TeX},Renderer=Basic} \setmainfont{CMU Serif} \setsansfont{CMU Sans Serif} \setmonofont{CMU Typewriter Text} \else \usepackage[utf8]{inputenc} % UTF-8: PDFLaTeX \usepackage[T2A]{fontenc} \usepackage{cmap} \fi \usepackage[russian,english]{babel} \usepackage{makeidx}\makeindex %\usepackage{xcolor} %\definecolor{darkblue}{rgb}{0,0,.6} \usepackage[ unicode ,pdfusetitle ,colorlinks = true %,linkcolor = darkblue %,citecolor = darkblue, filecolor = darkblue %,menucolor = darkblue, urlcolor = darkblue ,bookmarksnumbered = true, ,pdfdisplaydoctitle = true% display document title instead of file ,pdfpagemode = UseOutlines% (show bookmarks) ]{hyperref} \usepackage{ulem} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % \def\file#1{\texttt{#1}} \def\pkg#1{\textsf{#1}} \def\cmd#1{\texttt{#1}} \newcommand{\note}[2][N$\!\!$B: ]{\textcolor{red}{\ensuremath{\langle}#1#2\ensuremath{\rangle}}} % \newcommand\DescribeEntry[1]{% \DescribeMacro{#1}\index{Entry!\texttt{#1}}% } \newcommand\DescribeFunction[1]{% \DescribeMacro{#1}\index{\texttt{#1}}% } \newcommand\DescribeField[1]{% \DescribeMacro{#1}\index{Field!\texttt{#1}}% } \newcommand{\BibTeXu}{{{\BibTeX}\kern-.175em\rmfamily\textsc{u}}} % %\OnlyDescription % uncomment to hide the Implementation section \EnableCrossrefs \CodelineIndex \RecordChanges \begin{document} \DocInput{\jobname.dtx} \end{document} % % \fi % % \CheckSum{0} % % \DoNotIndex{\cyra,\cyrb,\cyrv,\cyrg,\cyrd,\cyre} % \DoNotIndex{\CYRP,\cyrii,\cyrr,\cyre,\cyro,\CYRU,\cyrk,\cyrl,\CYRS,\cyrs} % \DoNotIndex{\cyrt,\cyri,\cyrz,\CYRT,\cyrm} % \DoNotIndex{\cyr,\cyrc,\CYRD,\cyrery,\cyrh,\CYRK,\CYRM,\CYRN,\cyrn} % \DoNotIndex{\cyrp,\cyrs,\cyrshch,\cyru,\CYRV,\cyrya} % \DoNotIndex{\CYRA,\CYRB,\cyrch,\CYRE,\CYREREV,\CYRF,\cyrf,\CYRI,\cyrishrt} % \DoNotIndex{\CYRO,\CYRR,\cyrsftsn,\CYRYA,\cyryu,\cyrzh} % \DoNotIndex{\CYRCH, \CYRG, \CYRL, \CYRZH} % \DoNotIndex{\z@skip,\z@} % \DoNotIndex{\|,\~,\ ,\,} % % \begingroup % \makeatletter % \lccode`9=32\relax % \lowercase{%^^A % \edef\x{\noexpand\DoNotIndex{\@backslashchar9}}%^^A % }%^^A % \expandafter\endgroup\x % \expandafter\DoNotIndex\expandafter{\string\&} % % \DoNotIndex{\',\(,\),\`,\\,\/,\.,\ } % \DoNotIndex{\begin,\DeclareUTFcharacter} % \DoNotIndex{\csname,\def} % \DoNotIndex{\else,\endcsname,\end} % \DoNotIndex{\expandafter,\fi} % \DoNotIndex{\hbox,\hss} % \DoNotIndex{\iffalse,\ifx,\ignorespaces,\iflanguage} % \DoNotIndex{\language,\lastskip,\ldots,\let,\natexlab,\newblock,\nobreak} % \DoNotIndex{\providecommand,\ProvideTextCommandDefault,\relax,\renewcommand} % \DoNotIndex{\selectlanguage,\selectlanguageifdefined,\small,\textemdash} % \DoNotIndex{\textnumero,\unskip,\url,\UTFencname} % \DoNotIndex{\catcode,\cite,\citeauthor,\citet,\citeyear,\href,\hskip,\ifdim} % %\GetFileInfo{\jobname.ins} % %\title{The DSTU package} %\author{ % Mykhailo Mishchenko\thanks{E-mail: mdmisch@firemail.cc}\hspace{0.25em}; \\ \\ % heavily based on the GOST package by \\ % Igor Kotelnikov\thanks{E-mail: kia999@mail.ru}, % Leonid Sinev %} %\date{Version 1.4 released 2025.02.24} %\maketitle % % \begin{abstract} % % DSTU is a bundle of BibTeX styles designed to meet the DSTU 8302:2015 % standard % on bibliographic references issued by the ДП «УкрНДНЦ» % and Державна наукова установа «Книжкова палата України імені Івана Федорова», % and the DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) standard on biblographic % recording and bibliographic description. % % It comprises 18 BibTeX styles to format bibliography according to DSTU % 8302:2015 and 6 styles according to DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT). % Bibliographic records in English, Russian and Ukrainian are supported. % Both 8-bit and Unicode (UTF-8) versions of each BibTeX style, in each case % offering a choice of sorted and unsorted. % % \end{abstract} % % \section{Introduction}\label{s1} % % DSTU package is a modification of the GOST package which implements changes % required to comply with the current Ukrainian standard on bibliography % DSTU 8302:2015, which relaxes many archaic requirements of % DSTU GOST 7.1:2006 (i.\,e.\ GOST 7.1-2003, IDT). % While bibliography prepared according to GOST 7.1-2003 is still considered % valid under DSTU 8302:2015, following recommendations of DSTU 8302:2015 is % preferential. In some cases it is also explicitly required to prepare % bibliography specifically according to advices from DSTU 8302:2015. % For example, to follow typesetting style of a journal you are publishing % in. % % Although DSTU 8302:2015 can be used almost in every situation where % Ukrainian bibliographic standards are honored, there is a rumor that there % are some obscure cases when DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) must be % used and usage of DSTU 8302:2015 is prohibited. Thus, |*dstu2006*| % bibliographic styles % implementing DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) are also provided. It % seems like the DSTU GOST 7.1:2006 is actually a copy-paste of the Russian % GOST 7.1-2003. Thus, they are based on the |gost2003*| styles from the GOST % package. Nevertheless it appeared that the implementation of this % particular standard there was partial. |*dstu2006*| styles contain some % improvements made to better meet the DSTU GOST 7.1:2006 standard's % requirements, but there may be some yet unknown cases when it fails to meet % the standard. In addition, Ukrainian localization for was added where it % was missing. % % The GOST package was initially developed by Maksym Polyakov. It was later % updated by Igor Kotelnikov to the present status and some code was borrowed % from \pkg{disser} package developed by Stanislav Kruchinin and unpublished % work by Artem Petrenkov. % % Currently, DSTU contains 24 \BibTeX{} styles to format bibliography in % English, Ukrainian and % Russian according to DSTU 8302:2015 or DSTU GOST 7.1:2006 % (GOST 7.1-2003, IDT). Both 8-bit and Unicode (UTF-8) versions of each % \BibTeX{} style, in each case offering a choice of sorted and unsorted. % % All styles in the DSTU bundle are derived from single master file % \file{dstu.dtx} by applying different set of options as shown in the table % below. % % \noindent % \begin{minipage}{\linewidth} % \begin{verbatim} %------------------------------------------------------------------------------------ % Style | utf8 | bibtexu | strict | eprint | long | sort | natbib | dstu2015 %------------------------------------------------------------------------------------ % dstu2015 | | | | + | | | | + % dstu2015l | | | | + | + | | | + % dstu2015s | | | | + | | + | | + % dstu2015ls | | | | + | + | + | | + % dstu2015n | | | | + | | | + | + % dstu2015ns | | | | + | | + | + | + %------------------------------------------------------------------------------------ % udstu2015 | + | | | + | | | | + % udstu2015l | + | | | + | + | | | + % udstu2015s | + | | | + | | + | | + % udstu2015ls | + | | | + | + | + | | + % udstu2015n | + | | | + | | | + | + % udstu2015ns | + | | | + | | + | + | + %------------------------------------------------------------------------------------ % uudstu2015 | + | + | | + | | | | + % uudstu2015l | + | + | | + | + | | | + % uudstu2015s | + | + | | + | | + | | + % uudstu2015ls | + | + | | + | + | + | | + % uudstu2015n | + | + | | + | | | + | + % uudstu2015ns | + | + | | + | | + | + | + %------------------------------------------------------------------------------------ % dstu2006 | | | + | + | | | | % dstu2006s | | | + | + | | + | | % udstu2006 | + | | + | + | | | | % udstu2006s | + | | + | + | | + | | % uudstu2006 | + | + | + | + | | | | % uudstu2006s | + | + | + | + | | + | | %------------------------------------------------------------------------------------ % Style | utf8 | bibtexu | strict | eprint | long | sort | natbib | dstu2015 %------------------------------------------------------------------------------------ % \end{verbatim} % \end{minipage} % % |uudstu2015| style is recommended for most applications. It corresponds to the % currently effective DSTU 8302:2015 and intended to be used with UTF-8 encoded % documents and bibliography databases. Usage of other styles is best explained % through the meaning of options used to compile those styles from the master % source. % % All styles with |dstu2015| option and without |strict| option (|*dstu2015*| % styles) make best effort to implement DSTU 8302:2015. All styles without % |dstu2015| option and with |strict| option (|*dstu2006*| styles) make best % effort to implement DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT). % % If the number of authors exceeds 4, modern styles cut the list of authors % to at most 4 persons as prescibed by the Standards. Option % |long| overrides this rule to provide backward compatibility with the % package \pkg{disser} by Stanislav Kruchinin. % % Major effect of the |long| option is that the list of authors always % precedes book or article title no matter how long is it. % Modern styles compiled without |long| place long list of authors behind % the title. The names of styles compiled with the option |long| has the % suffix |l|. Recall that those styles do not conform effective Standards and % their use is discouraged. % % The |eprint| option enables formatting electronic publications. In particular, % it enables |eprint|, |eprinttype|, |eprintclass|, and |doi| fields for a % bibliographic entry. The styles generated without the |eprint| option, % ignore the these fields. % % The |natbib| option provides compatibility with the |natbib| package. The names % of styles compiled with the option |natbib| bear the suffix |n|. Currently % 4 styles with that option are available for beta testing. % % The |sort| option enables sorting bibliographic references by author names % and references titles. The names of styles compiled with the option |sort| % bear the suffix |s|. % % Finally, the |utf8| option produces bibliographic styles in Unicode rather % that in 8-bit encoding. The |utf8| without |bibtexu| option are intended % to be used with \BibTeX8 and have some functionality (involving typesetting % initials and letter case changing) disabled to prevent glitches appearing when % using \BibTeX8 with UTF-8 encoded bibliography. Names of those styles bear % the prefix |u|. % % The |utf8| styles with |bibtexu| option are fully functional styles in % Unicode intended to be used with \BibTeXu. As of 2022 % \BibTeXu{} works pretty decently, but beware that its older % versions often crash with "Segmentation fault" and thus are unusable. % % Styles without |utf8| option are intended for documents in one-byte 8-bit % encodings (e.\,g.\ cp1251) and not for Unicode. % % The original GOST bundle contains CS files (codepage and % sorting order) which are recommended to be used with the DSTU bundle. % % \noindent % \begin{minipage}{\linewidth} % \begin{verbatim} % ---------------------------------------------------------------- % Encoding | CSF | Sorting order % ---------------------------------------------------------------- % cp866 | ruscii.csf | Cyrillic first, Latin % cp1251 | cp1251.csf | Cyrillic first, Latin % koi8-u | koi8u.csf | Cyrillic first, Latin % utf8 | utf8cyrillic.csf | Cyrillic first, Latin % ---------------------------------------------------------------- % \end{verbatim} % \end{minipage} % % In addition, \BibTeX8 distribution comes with few more CSFs. % % \noindent % \begin{minipage}{\linewidth} % \begin{verbatim} % --------------------------------------------------------------- % Encoding | CSF | Sorting order % --------------------------------------------------------------- % cp866 | cp866rus.csf | Latin first, Cyrillic % --------------------------------------------------------------- % \end{verbatim} % \end{minipage} % % \section{How to use}\label{s2} % % \begin{enumerate} % \item % Select bibliography style by adding appropriate |\bibliographystyle| % declaration to your source file \file{.tex}, e.g. % \begin{verbatim} % \bibliographystyle{dstu2015} % \bibliography{database} % \end{verbatim} % % \item % Add the field |langid="ukrainian"| or |langid="russian"| to the % bibliographic entries in Ukrainian or Russian languages in your % database; English is the default language. German, Italian and % French are partially supported. |language| field with the same % meaning is available, but deprecated. % % \item % To compile list of references from your database use \file{bibtex8} % program rather than \file{bibtex}. Depending on the codepage of your % bibliographic database, indicate one of the CS files % listed above as option to \file{bibtex8}. Run LaTeX, then run % \file{bibTeX8} and LaTeX again: % \begin{verbatim} % latex .tex % bibtex8 -B -c .csf .aux % latex .tex % \end{verbatim} % % Alternatively, you can use \file{bibtexu} instead of \file{bibtex8} as % following: % \begin{verbatim} % latex .tex % bibtexu -B -l ukr -o ukr .aux % latex .tex % \end{verbatim} % % \item % \begin{sloppypar} % For details on preparing bibliographic database see examples in % \file{dstu2015*.pdf}, \file{udstu2015*.pdf} and \file{uudstu2015*.pdf}. % \end{sloppypar} % % \item % \file{udstu2015*} and \file{uudstu2015*} styles are primarily intended for % use with unicode compilers (\file{xelatex} and \file{lualatex}). They % should be preferred as well when using 8bit compilers % (\file{latex} and \file{pdflatex}) if source file is in utf8 encoding % \textit{and} you are using \file{bibtex} or \file{bibtex8}. % % You can also use \file{dstu2015*} styles if you use the % \file{bibtexu} program to build your bibliography instead of % \file{bibtex} or \file{bibtex8}. % % \item % Neither \file{bibtex} nor \file{bibtex8} provides % correct sorting order of unicode text. It means that using % \file{udstu2015s} or \file{udstu2015ns} may produce unexpected result % for documents in \texttt{utf8} encoding. % Consider using \file{bibtexu} if you need correct sorting in this case. % % \item % \file{bibtex8} fails to change case of a string if it contains Cyrillic % letter in unicode. Therefore \file{ugost2008*} styles do not change case of % titles and other parts of bibliographic record while 8-bit styles % do the case change where appropriate. % % \item % Either \file{bibtex} or \file{bibtex8} fail to cut Cyrillic names to % initials. Therefore \file{udstu2015*} styles do not modify name of % authors. % % \item % Package |natbib| is required when choosing styles with % suffix |n| in their names. % % \end{enumerate} % % % \section{Customization}\label{s3} % % Every DSTU style defines few commands to format some parts of a % reference. You can redefine these commands prior to % the |\bibliography{}| command. Initial % definitions are listed below. % \begin{verbatim} % \providecommand*{\url}[1]{{\small #1}} % \providecommand*{\BibUrl}[1]{\url{#1}} % \providecommand{\BibAnnote}[1]{} % \providecommand*{\BibEmph}[1]{#1} % \providecommand*{\BibEnNo}{no.} % \providecommand*{\BibFirstNameSpace}{\,} % \providecommand*{\BibSemicolonSpace}{~} % \end{verbatim} % % \DescribeMacro{\DSTUAllowBibDash} % By default, dstu styles separate logical parts of a bibliography % record by a period. It is still legitimate to separate them by a period and % cyrdash (|. "---|) instead, like required by DSTU GOST 7.1:2006, but it is % strongly discouraged (while allowed) in DSTU 8302:2015. You can enable the % dash separator in |dstu2015*| and |udstu2015*| styles by overriding the % command |\DSTUAllowBibDash| as follows: % % \begin{verbatim} % \newcommand*{\DSTUAllowBibDash}{1} % \end{verbatim} % % \DescribeMacro{\DSTUResponsibilityName} % By default, names are formatted in a way so that initials appear % \textit{after} last name. But it seems like the exact order is not % defined by the standards. Some journals (e.\,g.\ Problems of Control and % Informatics) require to have this order in names before the title and % reverse order in names after the title (i.\,e. in the "responsibility" % section of bibliographic reference). % % To address this all names after the title are formatted twice for both % variants of formatting. Each two variants of formatting of the same name % are used as two arguments of |\DSTUResponsibilityName| custom \LaTeX{} % macro. This commant by default uses the first its argument (with % normal order) and ignores its second argument (with reverse order). You % can make styles use the reverse order in the "responsibility" section by % overriding it as follows: % % \begin{verbatim} % \newcommand*{\DSTUResponsibilityName}[2]{#2} % \end{verbatim} % % \DescribeMacro{\DSTUAllowNamesAnd} % By default, lists of names containing more than 4 names will have "and", % "и", or "і" (depending on language) before the last name in such list. % Some journals (e.\,g.\ Problems of Control and Informatics) prohibit it. % |\DSTUAllowNamesAnd| allows to disable adding "and", "и", or "і" with % following command: % % \begin{verbatim} % \newcommand*{\DSTUAllowNamesAnd}{0} % \end{verbatim} % % \DescribeMacro{\BibDOIFullURL} % By default, the DOI identifier is printed as is, and is not formatted as % an URL to the \url{https://doi.org/}. Placing full URL instead of a DOI % identifier is explicitly discouraged (but still allowed) by % DSTU~8302:2015. Nevertheless, some journals (e.\,g.\ Problems of Control % and Informatics) require to place full DOI URLs into bibliographic % references. % % You can make this style print full DOI URLs by placing the following % definition somewhere before bibliography in your document. % \begin{verbatim} % \newcommand*{\BibDOIFullURL}{1} % \end{verbatim} % % \textbf{TODO:} Test |\DSTUAllowBibDash| in % |dstu2015*| and |udstu2015*|. % % By default, |\BibDash| is equivalent to the shorthand |"---| % defined by the babel package with the option |russian|. % It prints a so called Cyrillic dash (|\cyrdash|), % which is 20\% shorter then ordinary LaTeX dash (|---|), and puts % unbreakable space before |\cyrdash| so that dash never appears % in the beginning of a line. % % \DescribeMacro{\BibEnNo} % |\BibEnNo|, obviously, defines every occurance of prefix of a number in % bibliography. In some cases, you may wish to replace it with something like % |N.| or |№|. % % % \DescribeMacro{\BibFirstNameSpace} % |\BibFirstNameSpace| represents space between initials, for example, % between initials for first name and patronymic. It seems like everyone has % their own opinion on what it should be: nonbreakng whitespace |~|, short % unstretchable space |\,|, no space at all or something else. See % \href % {https://ukrainian.stackexchange.com/questions/999/%D0%9D%D0%B0%D0%BF%D0%B8%D1%81%D0%B0%D0%BD%D0%BD%D1%8F-%D1%96%D0%BD%D1%96%D1%86%D1%96%D0%B0%D0%BB%D1%96%D0%B2-%D1%80%D0%B0%D0%B7%D0%BE%D0%BC-%D1%87%D0%B8-%D0%BE%D0%BA%D1%80%D0%B5%D0%BC%D0%BE} % {\nolinkurl{https://ukrainian.stackexchange.com/questions/999/}\texttt{Написання-\linebreak[1]ініціалів-\linebreak[1]разом-\linebreak[1]чи-\linebreak[1]окремо}} \linebreak[1] % for discussion on this topic regaring Ukrainian language. % % \DescribeMacro{\BibSemicolonSpace} % |\BibSemicolonSpace| defines space before semicolon dividing bibliographic % record's sections. Normally it is nonbreaking space |~|. Redefining it % would violate standards. Nevertheess, some journals may require, for % example, not to have space before semicolons. % % \DescribeMacro{\BibDiscouragedbreakSpace} % \phantomsection\label{macro:BibDiscouragedbreakSpace} % Line breaks between "Vol." (or its translations) and corresponding % volume numbers do not look good in general. This bibliographic style % inserts nonbreaking space (|~|) if the volume number is shorter than 3 % characters. Otherwise it inserts |\BibDiscouragedbreakSpace| which by % default discourages line break at this point, but do not prohibit it % completely. Thus, \TeX{} can still decide to make a line break at this % point if otherwise too wide whitespaces emerge. % % Its default definition is equivalent to the following: % \begin{verbatim} % \newcommand*{\BibDiscouragedbreakSpace}{ \nolinebreak[3] } % \end{verbatim} % You can redefine it in your document to something else if required. For % example, you can change weight argument of |\nolinebreak| to something % else, or you can explicitly prohibit breaking a line at this place by % changing its definition to |~|. % % \DescribeMacro{\BibISBNandISSNcolon} % \DescribeMacro{\BibISBNcolon} % \DescribeMacro{\BibISSNcolon} % Starting from v1.4 colons \texttt{:} are not prnted after \texttt{ISBN} % and \texttt{ISSN} in accordance to DSTU~GOST~7.1-2006. If for some % reason you need to place colons there, like it is done after % \texttt{URL} and \texttt{DOI}, you can define one of these macro % according to what you need: % \begin{verbatim} % \newcommand*{\BibISBNcolon}{:} % \newcommand*{\BibISSNcolon}{:} % \newcommand*{\BibISBNandISSNcolon}{:} % \end{verbatim} % % \DescribeMacro{\DSTUAllowSeriesParentheses} % \phantomsection\label{macro:DSTUAllowSeriesParentheses} % Starting from v1.4 the information related to series is properly % represented as the "series" section in accordance to DSTU~GOST~7.1-2006. % % The "series" section, according to DSTU~GOST~7.1-2006, must be put in % braces. In DSTU~8303:2015 nothing is said about these braces, which % implicitly means that they must be inherited from DSTU~GOST~7.1-2006. % % Nevertheles, these braces are rarely seen in examples of bibliographic % references formatted according to DSTU~8303:2015 because this standard % \textit{allows} to skip the series section completely. Thus, editors % \sout{may be freaked by} may not be familiar with these braces and thus % may insist on removing them. Set \cs{DSTUAllowSeriesParentheses} as % following if you need to remove these braces: % \begin{verbatim} % \newcommand*{\DSTUAllowSeriesParentheses}{0} % \end{verbatim} % % \section{Where to get}\label{s4} % % Latest versions are published at % \url{https://codeberg.org/mdmisch/dstu/releases}. % % \section{Version history}\label{s5} % % \subsection{Version 1.4 (2025.02.24)} % % \begin{enumerate} % \item Include the series bibliographic record's section in a proper % position (instead of just mentioning corresponding information % somewhere) in accordance to the DSTU~GOST~7.1-2006. % \item Changed how and where the \texttt{volume} field is printed. From % now on \texttt{volume} is printed as a book volume only if there is no % \texttt{series} section in bibliographic record. Otherwise it is % treated as a volume within series. % \end{enumerate} % % \subsection{Version 1.3 (2025.02.10)} % \begin{enumerate} % \item Name formatting rewritten. This fixes bug with disappearing second % part in hyphenated double first names and ansures no linebreak after % hyphens in this position (if the |\nobreakdash| from \texttt{amsmath} % is available). % \end{enumerate} % % \subsection*{Version 1.2 (2025.02.04)} % % \begin{enumerate} % \item Renamed |uudstu2015sc.bst|, |uudstu2015lsc.bst| to % |uudstu2015s.bst|, |uudstu2015ls.bst| (correspondingly) for naming % consistency. % \item Added generation of bibliography example consistent with % requirements of the Problems of Control and Informatics journal: % |uudstu2015-pcijournal.{tex,pdf}|. % \item Added a bibliography example |ex78.bib| with four and more authors % in English. % \item Added a macro \cs{DSTUResponsibilityName} which can be redefined % by user to change order of corresponding initials and surnames % appearing after title. % \item Added macro \cs{DSTUAllowNamesAnd} which determines whether to use % "and", "і" or "и" in name lists. % \item User can now change the kind of whitespace inserted between "Vol." % (or its translations) and corresponding volume numbers longer than 2 % characters. Previously it was a normal whitespace (which allows line % break). Now it is | \nolinebreak[3] | by default and can be changed by % user. See the description of % \hyperref[macro:BibDiscouragedbreakSpace]{\textbackslash BibDiscouragedbreakSpace}. % \end{enumerate} % % \subsection*{Version 1.1 (2023.09.12)} % % \begin{enumerate} % \item % Added ISSN to articles. % \end{enumerate} % % \subsection*{Version 1.0 (2023.08.04)} % % \begin{enumerate} % \item % Codebase inherited from the GOST bundle 1.2k (2020.12.29). % % \item % Added some tweaks to comply with the DSTU 8302:2015. % % \item % Building of original styles from the GOST bundle removed to avoid % filename clashes. % % \item % Added `polyglossia` support for language changing in bibliography entries. % \end{enumerate} % % \StopEventually{ % \IndexPrologue{\section{Index} % Numbers written in dark blue refer to the page where the corresponding % entry is described; numbers in black roman refer to the code lines where % the entry is used. % } % \GlossaryPrologue{\newpage\section{Change History}} % \PrintChanges % \PrintIndex % } % % \section{Implementation}\label{s6} % % We need Russian fonts to produce documentation of the code below. % Therefore we switch current language to Russian by issuing the command % |\selectlanguage{russian}|. % % \selectlanguage{russian} % % \begin{macrocode} %<*bst> % \end{macrocode} % % \begin{macrocode} %% This bibstyle attempts to format bibliography according to %%% strange mix of DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) and DSTU 8302:2015. Do not use it! %%% DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) for bibliographic records. %%% (probaly) GOST 7.0.5-2008 for bibliographic reference. %%% DSTU 8302:2015 for bibliographic reference. %<*natbib>%% %%------------------------------------------------------------------- %% This is an author-year citation style bibliography. %% It requires a special package file to function properly %% such as natbib.sty by Patrick W. Daly. %% The form of the \bibitem entries is %% \bibitem[Jones et al.(1990)]{key}... %% \bibitem[Jones et al.(1990)Jones, Baker, and Smith]{key}... %% where the label part [in brackets] consists of the author names, %% as they should appear in the citation, with the year in parentheses following. %% There must be no space before the opening parenthesis! %% A full list of authors may also follow the year. %% In natbib.sty, it is possible to define the type of enclosures that is %% really wanted (brackets or parentheses), but in either case, there must %% be parentheses in the label. %% The \cite command functions as follows: %% \citet{key} => Jones et al. (1990) %% \citet*{key} => Jones, Baker, and Smith (1990) %% \cite{key} => (Jones et al., 1990) %% \cite*{key} => (Jones, Baker, and Smith, 1990) %% \cite[chap. 2]{key} => (Jones et al., 1990, chap. 2) %% \cite[e.g.][]{key} => (e.g. Jones et al., 1990) %% \cite[e.g.][p. 32]{key} => (e.g. Jones et al., p. 32) %% \citeauthor{key} => Jones et al. %% \citeauthor*{key} => Jones, Baker, and Smith %% \citeyear{key} => 1990 %%--------------------------------------------------------------------- % % \end{macrocode} % \subsection{Fields}\label{s6.1} % % Enlist all entry fields allowed in a bibliographic database. % Most fields are common for many standard |bst| styles. Nonlisted fields % are just ignored by \BibTeX. % \changes{GOST v1.2i}{12 Jan 2017}{field \texttt{date} added} % \changes{GOST v1.2i}{12 Jan 2017}{field \texttt{specialitycode} added} % \changes{GOST v1.2f}{12 Jul 2016}{entry \texttt{patent} added} % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{langid} added} % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{eid} added} % \changes{GOST v1.2}{01 Feb 2012}{entry field \texttt{medium} added} % \changes{GOST v0.8}{06 Jun 2003}{entry field \texttt{annote} added} % \begin{macrocode} ENTRY { address annote author booktitle bookauthor chapter edition editor compiler howpublished institution journal key %major % new in v.1.2i, alias for speciality, not implemented majorcode % new in v.1.2i, alias for specialitycode month note number organization pages eid % new in v1.2c publisher school % alias for institution series %speciality % new in v.1.2i, eqv. to major in biblatex-gost, not implemented yet... specialitycode % new in v.1.2i, alias of number, eqv. to majorcode in biblatex-gost title %medium % new in v1.2; renamed to media. media % new in v1.2f type volume year language langid % new in v1.2c booklanguage % \end{macrocode} % Entries borrowed from biblatex. % \changes{GOST v1.2b}{19 Jan 2014}{entry field \texttt{numpages} renamed to % \texttt{pagetotal}} % \changes{GOST v1.2}{26 Jan 2012}{entry fields \texttt{eprint}, \texttt{eprintclass}, % \texttt{eprinttype} added} % \changes{v1.1}{12 Sep 2023}{entry field \texttt{issn} added} % \begin{macrocode} date % new in v1.2i pagetotal url urldate isbn issn doi eprint eprinttype % = archivePrefix eprintclass % = primaryClass % new in v1.2f: % appear in biblatex: %addendum % not implemented yet... holder % see patent location % new in v.1.2i, alias of address %subtitle % not implemented yet... titleaddon % new in v.1.2i, see @thesis %version % not implemented yet... % Appear in biblatex-gost for @patent entry: authorcountry % country of the patent authors credits % statement of responsibility, other than provided in Biblatex ipc % Code of the International Patent Classification %media % General material designation NOTE: medium in the above requestnumber % Registration number of the application to the patent document publicationdate % Date of publication publication % and information on the official gazette, which published patent prioritydate % Information about the convention priority: the date of filing of the application, prioritynumber % number and prioritycountry % country name of convention priority. requestdate % ?? } {} % { label } % { label extra.label sort.label short.list } % \end{macrocode} % % \subsection{Output functions}\label{s6.2} % % Declare internal variables and constants used for formatting bibliographic % records. Other variables are defined below when needed. % \begin{macrocode} INTEGERS { output.state before.all mid.sentence after.sentence after.block after.dblslash after.slash after.colon after.semicolon output.needitalic fmt.responsibility.name } STRINGS { curlanguage } STRINGS { s t } STRINGS { y m d } % new in v.1.2j % \end{macrocode} % % \DescribeFunction{init.state.consts}% % Set constants that designate various output states which are kept by % `output.state` integer. The latter is checked and updated by a set of functions % such as `output` to be defined below. % \begin{macrocode} FUNCTION {init.state.consts} { #0 'before.all := #1 'mid.sentence := #2 'after.sentence := #3 'after.block := #4 'after.dblslash := #5 'after.slash := #6 'after.colon := #7 'after.semicolon := } % \end{macrocode} % % \DescribeFunction{set.language} % Sets current language |curlanguage|. % Called by |bibitem.output| before any other function. % \begin{macrocode} FUNCTION {set.language} { langid empty$ { language empty$ { "english" 'curlanguage := } { language 'curlanguage := } if$ } { langid 'curlanguage := } if$ } % \end{macrocode} % % \DescribeFunction{reset.language} % Reset current language to |booklanguage| if provided. Called by % |output.nonnull| after double slash so that the rest of the record is formatted % with |booklanguage|. % \begin{macrocode} FUNCTION {reset.language} { booklanguage empty$ { "" } { booklanguage 'curlanguage := "\selectlanguageifdefined{" curlanguage * "}" * } if$ } % \end{macrocode} % % Declare various functions to output various parts of a bibliographic record. % % \DescribeFunction{format.italicize} % This function is supposed to be used in \texttt{output.nonnull}. It wraps % last string on stack in \sc{textit} if \texttt{output.needitalic} is set and % resets this variable it to zero. % % This hack is needed to italicize entries together with punctuation appended % to it in some other place. % % \changes{v1.0}{11 Sep 2022}{Added \texttt{output.needitalic} for delayed % italicising of entries.} % % \begin{macrocode} FUNCTION {format.italicize} { output.needitalic { "\textit{" swap$ * "}" * #0 'output.needitalic := } 'skip$ if$ } % \end{macrocode} % % \DescribeFunction{output.nonnull} % Writes the last literal in the stack to output buffer % assuming that it is not empty and adds an appropriate punctuation symbol. % \changes{GOST v1.2c}{17 Jan 2015}{fix Gost2003: \texttt{"}\texttt{-}\texttt{-}\texttt{-} replaced by macro \cs{BibDash}} % \changes{v1.0}{11 Sep 2022}{Replace double dash with dot for \texttt{dstu2015} and mark anything after supposed double dash as italicized.} % \changes{v1.0}{20 Mar 2023}{Removed \cs{BibDash} by default (can be enabled back by user).} % \changes{v1.0}{19 Jun 2023}{Added \cs{BibSemicolonSpace}.} % \begin{macrocode} FUNCTION {output.nonnull} { swap$ output.state mid.sentence = { format.italicize ", " * write$ } { output.state after.block = { add.period$ format.italicize write$ % " \BibDash " write$ % " \DSTUBibDash " write$ newline$ "\newblock " write$ } { output.state before.all = { format.italicize write$ } { output.state after.dblslash = % { format.italicize "~//" * reset.language * " " * write$ } %<*dstu2015> { add.period$ format.italicize reset.language * " " * write$ #1 'output.needitalic := } % { output.state after.slash = { format.italicize "~/ " * write$ } { output.state after.colon = { format.italicize "~: " * write$ } { output.state after.semicolon = { format.italicize "\BibSemicolonSpace ; " * write$ } { add.period$ format.italicize " " * write$ } if$ } if$ } if$ } if$ } if$ } if$ mid.sentence 'output.state := } if$ } % \end{macrocode} % % \DescribeFunction{output} % Calls |output.nonnull| if the last literal string in the stack % is not empty; otherwise it discards the literal. % \begin{macrocode} FUNCTION {output} { duplicate$ empty$ 'pop$ 'output.nonnull if$ } % \end{macrocode} % % \DescribeFunction{output.check} % Does the same but also warns if the indicated field is empty. Needs two % literals in the stack: the field and the name of the field, e.g., % |author "author" output.check|. % \begin{macrocode} FUNCTION {output.check} { 't := duplicate$ empty$ { pop$ "empty " t * " in " * cite$ * warning$ } 'output.nonnull if$ } % \end{macrocode} % % \DescribeFunction{fin.entry} % |fin.entry| finalizes current entry. It writes dot, if no dot is found in % stack, and starts new line. % \begin{macrocode} FUNCTION {fin.entry} { add.period$ write$ newline$ } % \end{macrocode} % % Declare a family of functions to put punctuation marks depending on the current % status of the output stack. % % \DescribeFunction{new.block}% % This just checks output state and revert it to another state if required. % Checking output state prevents occasional doubling of punctuation marks. % \begin{macrocode} FUNCTION {new.block} { output.state before.all = 'skip$ { after.block 'output.state := } if$ } % \end{macrocode} % \DescribeFunction{new.dblslash}% % \begin{macrocode} FUNCTION {new.dblslash} { output.state before.all = 'skip$ { after.dblslash 'output.state := } if$ } % \end{macrocode} % \changes{v1.2}{09 Jan 2025}{Add automatic switch to the % responsibility-section mode of name formatting % after slash.} % \DescribeFunction{new.slash}% % \begin{macrocode} FUNCTION {new.slash} { output.state before.all = 'skip$ { after.slash 'output.state := } if$ #1 'fmt.responsibility.name := } % \end{macrocode} % \DescribeFunction{new.colon}% % \begin{macrocode} FUNCTION {new.colon} { output.state before.all = 'skip$ { after.colon 'output.state := } if$ } % \end{macrocode} % \DescribeFunction{new.semicolon}% % \begin{macrocode} FUNCTION {new.semicolon} { output.state before.all = 'skip$ { after.semicolon 'output.state := } if$ } % \end{macrocode} % \DescribeFunction{new.sentence}% % \begin{macrocode} FUNCTION {new.sentence} { output.state after.block = 'skip$ { output.state before.all = 'skip$ { after.sentence 'output.state := } if$ } if$ } % \end{macrocode} % % \DescribeFunction{add.blank}% % \begin{macrocode} FUNCTION {add.blank} { " " * before.all 'output.state := } % \end{macrocode} % % \subsection{Logical functions and various checks}\label{s6.3} % % Declare few logical functions. % % \DescribeFunction{not} % \begin{macrocode} FUNCTION {not} { { #0 } { #1 } if$ } % \end{macrocode} % \DescribeFunction{and} % \begin{macrocode} FUNCTION {and} { 'skip$ { pop$ #0 } if$ } % \end{macrocode} % \DescribeFunction{or} % \begin{macrocode} FUNCTION {or} { { pop$ #1 } 'skip$ if$ } % \end{macrocode} % % \DescribeFunction{non.stop} % \note{What's the hell? Never used.} % \begin{macrocode} %FUNCTION {non.stop} %{ duplicate$ % "}" * add.period$ % #-1 #1 substring$ "." = %} % % \end{macrocode} % \DescribeFunction{new.block.checka} % Adds |new.block| if the last literal in stack is not empty. % \begin{macrocode} FUNCTION {new.block.checka} { empty$ 'skip$ 'new.block if$ } % \end{macrocode} % \DescribeFunction{new.block.checkb} % Adds |new.block| if either of the two last literals in the stack is not empty. % \begin{macrocode} FUNCTION {new.block.checkb} { empty$ swap$ empty$ and 'skip$ 'new.block if$ } % \end{macrocode} % \DescribeFunction{new.sentence.checka} % Adds |new.sentence| if the last literal in stack is not empty. % \begin{macrocode} FUNCTION {new.sentence.checka} { empty$ 'skip$ 'new.sentence if$ } % \end{macrocode} % \DescribeFunction{new.sentence.checkb} % Adds |new.sentence| if either of the two last literals in the stack is not empty. % \begin{macrocode} FUNCTION {new.sentence.checkb} { empty$ swap$ empty$ and 'skip$ 'new.sentence if$ } % \end{macrocode} % \DescribeFunction{new.dblslash.checka} % For |online| entry. % \changes{GOST v1.1}{15 Jan 2012}{entry type \texttt{@online} added} % \begin{macrocode} FUNCTION {new.dblslash.checka} { empty$ 'skip$ 'new.dblslash if$ } % \end{macrocode} % \DescribeFunction{field.or.null} % Replaces an empty field with null string |""|. % \begin{macrocode} FUNCTION {field.or.null} { duplicate$ empty$ { pop$ "" } 'skip$ if$ } % \end{macrocode} %% % \DescribeFunction{either.or.check} % \note{Move upwards} % \begin{macrocode} FUNCTION {either.or.check} { empty$ 'pop$ { "can't use both " swap$ * " fields in " * cite$ * warning$ } if$ } % \end{macrocode} % % \subsection{String Functions}\label{s6.4} % % \DescribeFunction{spaces.around} % Inserts a space before and after last literal in the stack. % \begin{macrocode} FUNCTION {spaces.around} { " " swap$ * " " * } % \end{macrocode} % % \DescribeFunction{emphasize} % Emphasizes the last literal in the stack if it is not empty. % v1.2k: |emphasize| now returns empty field if last literal in the stack % was empty. % \changes{GOST v1.2k}{25 Dec 2020}{function emphasize modified} % \changes{GOST v0.8}{10 Aug 2003}{macro \cs{BibEmph} added} % \begin{macrocode} FUNCTION {emphasize} { duplicate$ empty$ %{ pop$ "" } 'skip$ % v.1.2k { "\BibEmph{" swap$ * "}" * } if$ } % \end{macrocode} % % \DescribeFunction{bracify} % New in v.1.2. An idea borrowed from apsrev4-1.bst. % Encloses last literal in the stack by braces even if it is empty. Note that % braces are normally not printed by \LaTeX. % \begin{macrocode} FUNCTION {bracify} { duplicate$ empty$ { pop$ "{}" } { "{" swap$ * "}" * } if$ } % \end{macrocode} % \DescribeFunction{bracketise} % This and the next functions are used to enclose last word by square and round % brackets. In contrast to |bracify| function they push null string if the % last literal is empty. % \begin{macrocode} FUNCTION {bracketise} { duplicate$ empty$ { pop$ "" } { "[" swap$ * "]" * } if$ } % \end{macrocode} % \DescribeFunction{paranthesify} % \begin{macrocode} FUNCTION {paranthesify} { duplicate$ empty$ { pop$ "" } { "(" swap$ * ")" * } if$ } % \end{macrocode} % \DescribeFunction{paranthesify.seies} % Enclose series reference section in braces, while allowing to % conditionally skip these braces. See % \hyperref[macro:DSTUAllowSeriesParentheses]{the description of % \cs{DSTUAllowSeriesParentheses}} for details. % \begin{macrocode} FUNCTION {paranthesify.series} { duplicate$ empty$ { pop$ "" } { "\ifnum \DSTUAllowSeriesParentheses>0(\fi " swap$ * "\ifnum \DSTUAllowSeriesParentheses>0)\fi{}" * } if$ } % \end{macrocode} % % \DescribeFunction{chop.word} % % The function |chop.word| in the context `\emph{sstr} \emph{len} \emph{str} % |chop.word|' tries to remove given substring \emph{sstr} of the length \emph{len} % from the beginning of the string \emph{str}. It trims \emph{str} only if first % \emph{len} symbols in \emph{str} coinsides with \emph{sstr}. % See examples in Section~\ref{s6.6}. % \begin{macrocode} %<*sort|natbib> INTEGERS { len } FUNCTION {chop.word} { 's := 'len := s #1 len substring$ = { s len #1 + global.max$ substring$ } 's if$ } % % \end{macrocode} % % \DescribeFunction{is.num} % Currently not used. % % \note{Можно использовать для проверки года, извлечённого из |date|.} % \begin{macrocode} %<*debug> FUNCTION {is.num} { chr.to.int$ duplicate$ "0" chr.to.int$ < not swap$ "9" chr.to.int$ > not and } % % \end{macrocode} % % \DescribeFunction{extract.num} % Currently not used. % \begin{macrocode} %<*debug> FUNCTION {extract.num} { duplicate$ 't := "" 's := { t empty$ not } { t #1 #1 substring$ t #2 global.max$ substring$ 't := duplicate$ is.num { s swap$ * 's := } { pop$ "" 't := } if$ } while$ s empty$ 'skip$ { pop$ s } if$ } % % \end{macrocode} % % \DescribeFunction{tie.connect} % Inserts unbreakable space between last two literals in the stack. % \begin{macrocode} FUNCTION {tie.connect} {"~" swap$ * * } % \end{macrocode} % % \DescribeFunction{tie.or.space.connect} % Inserts space or unbreakable space between last two literals in the stack % depending on the length of last literal. % \begin{macrocode} FUNCTION {tie.or.space.connect} { duplicate$ text.length$ #3 < { "~" } { " " } if$ swap$ * * } % \end{macrocode} % % \DescribeFunction{tie.or.discouragedbreak.connect} % Inserts space with discouraged line break or unbreakable space between % last two literals in the stack depending on the length of last literal. % \changes{1.2}{2025/02/04}{\texttt{tie.or.discouragedbreak.connect} added % to add normal spaces with discouraged line break % between two strings if second string is too % long.} % \begin{macrocode} FUNCTION {tie.or.discouragedbreak.connect} { duplicate$ text.length$ #3 < { "~" } { "\BibDiscouragedbreakSpace " } if$ swap$ * * } % \end{macrocode} % % \DescribeFunction{n.dashify} % \begin{macrocode} FUNCTION {n.dashify} { 't := "" { t empty$ not } { t #1 #1 substring$ "-" = { t #1 #2 substring$ "--" = not { "--" * t #2 global.max$ substring$ 't := } { { t #1 #1 substring$ "-" = } { "-" * t #2 global.max$ substring$ 't := } while$ } if$ } { t #1 #1 substring$ * t #2 global.max$ substring$ 't := } if$ } while$ } % \end{macrocode} % % \DescribeFunction{multi.page.check} % Returns 1 if the last literal (usually |page|) contains either `|-|', `|,|' % or `|+|'; otherwise returns 0. % Used in connection with |n.dashify|. % % \note{Заметим несогласованность функций |multi.page.check| и % |n.dashify|. Последняя функция проверяет дефис, а первая ещё и минус и % запятую.} % % \begin{macrocode} INTEGERS { multiresult } FUNCTION {multi.page.check} { 't := #0 'multiresult := { multiresult not t empty$ not and } { t #1 #1 substring$ duplicate$ "-" = swap$ duplicate$ "," = swap$ "+" = or or { #1 'multiresult := } { t #2 global.max$ substring$ 't := } if$ } while$ multiresult } % \end{macrocode} % % % \subsection{Language-sensitive abbreviations}\label{s6.5} % % Declare language-sensitive abbreviations. % We provide two versions of any abbreviation for unicode and non-Unicode styles. % The language-sensitive functions push to the stack a string that depends of the % the current value of the string |curlanguage|. It is set for every entry by % |output.bibitem| function. Abbreviations for |russian|, |ukrainian| and |english| % values of the string |curlanguage| are always provided, and sometimes for % |french| and |german|. % % \changes{v1.0}{13 Apr. 2023}{Changed \texttt{"під ред."} to more correct % \texttt{"за ред."} in Ukrainian.} % \DescribeFunction{bbl.edby} % \begin{macrocode} FUNCTION {bbl.edby} { curlanguage "english" = {"ed.\ by"} { curlanguage "ukrainian" = % {"{\cyr\cyrz\cyra\ \cyrr\cyre\cyrd.}"} % {"за ред."} { curlanguage "russian" = % {"{\cyr\cyrp\cyro\cyrd\ \cyrr\cyre\cyrd.}"} % {"под ред."} { curlanguage "german" = { "ed." } {"language is not defined: " curlanguage " in bbl.edby" * * warning$ "Ed.\ by"} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.compiler} % \begin{macrocode} FUNCTION {bbl.compiler} { curlanguage "english" = { "Compiler"} { curlanguage "german" = { "Hrsg." } { curlanguage "ukrainian" = % {"{\cyr\CYRU\cyrk\cyrl.}"} % {"{Укл.}"} { curlanguage "russian" = % {"{\cyr\CYRS\cyro\cyrs\cyrt.}"} % {"{Сост.}"} {"language is not defined: " curlanguage " in bbl.compiler" * * warning$ "Compiler"} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.edition} % \begin{macrocode} FUNCTION {bbl.edition} { curlanguage "english" = {"ed."} { curlanguage "ukrainian" = % {"{\cyr\cyrv\cyri\cyrd.}"} % {"{вид.}"} { curlanguage "russian" = % {"{\cyr\cyri\cyrz\cyrd.}"} % {"{изд.}"} { curlanguage "german" = {" {aus.}" } %%%% { "Aufl." } ?? { curlanguage "italian" = {"edizione"} { curlanguage "french" = {"\'{e}dition"} {"language is not defined: " curlanguage " in bbl.edition" * * warning$ "ed."} if$} if$} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.vvolume} % \begin{macrocode} FUNCTION {bbl.vvolume} { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or {"Volume"} { curlanguage "ukrainian" = curlanguage "russian" = or % { "\CYRT\cyro\cyrm" } % { "Том" } { curlanguage "german" = {"{Band}"} %%%% { "Volumen" } {"language is not defined: " curlanguage " in bbl.vvolume" * * warning$ "Volume"} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.vvol} % \begin{macrocode} FUNCTION {bbl.vvol} { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or {"Vol."} { curlanguage "ukrainian" = curlanguage "russian" = or % {"\CYRT."} % {"Т."} { curlanguage "german" = {"{Bd.}"} %%%% { "Vol." } {"language is not defined: " curlanguage " in bbl.vvol" * * warning$ "Vol."} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.iissue} % \begin{macrocode} FUNCTION {bbl.iissue} { curlanguage "english" = {"Issue"} { curlanguage "ukrainian" = % {"\CYRV\cyri\cyrp\cyru\cyrs\cyrk"} % {"Випуск"} { curlanguage "russian" = % {"\CYRV\cyrery\cyrp\cyru\cyrs\cyrk"} % {"Выпуск"} { curlanguage "german" = {"{Heft}"} %%%% { "Ausgabe" } {"language is not defined: " curlanguage " in bbl.iissue" * * warning$ "Issue"} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.iiss} % \begin{macrocode} FUNCTION {bbl.iiss} { curlanguage "english" = {"Iss."} { curlanguage "ukrainian" = % {"\CYRV\cyri\cyrp."} % {"Вип."} { curlanguage "russian" = % {"\CYRV\cyrery\cyrp."} % {"Вып."} { curlanguage "german" = {"{H.}"} {"language is not defined: " curlanguage " in bbl.iiss" * * warning$ "Iss."} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.of} % \begin{macrocode} FUNCTION {bbl.of} { curlanguage "english" = {"of"} { curlanguage "german" = { "von" } { curlanguage "ukrainian" = % { "{\cyr\cyrii\cyrz}" } % { "{із}" } { curlanguage "russian" = % { "{\cyr\cyri\cyrz}" } % { "{из}" } {"language is not defined: " curlanguage " in bbl.of" * * warning$ "of"} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.etal} % \begin{macrocode} FUNCTION {bbl.etal} { curlanguage "english" = {"et~al."} { curlanguage "german" = { "u.~a." } { curlanguage "ukrainian" = % {"{\cyr\cyrt\cyra~\cyrii\cyrn.}"} % {"{та~ін.}"} { curlanguage "russian" = % {"{\cyr\cyri~\cyrd\cyrr.}"} % {"и~др."} {"language is not defined: " curlanguage " in bbl.etal" * * warning$ "et~al."} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.and} % \begin{macrocode} FUNCTION {bbl.and} { curlanguage "english" = {"and"} { curlanguage "german" = { "und" } { curlanguage "ukrainian" = % {"{\cyrii}"} % {"і"} { curlanguage "russian" = % {"{\cyri}"} % {"и"} { curlanguage "french" = {"et"} {"language is not defined: " curlanguage " in bbl.and" * * warning$ "and"} if$} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.nnumber} % \begin{macrocode} FUNCTION {bbl.nnumber} { curlanguage "english" = {"Number"} { curlanguage "ukrainian" = curlanguage "russian" = or % { "\CYRN\cyro\cyrm\cyre\cyrr" } % { "{Номер}" } { curlanguage "german" = {"{Heft}"} %%% { "Anzahl" } {"language is not defined: " curlanguage " in bbl.nnumber" * * warning$ "Number"} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.number} % \begin{macrocode} FUNCTION {bbl.number} { curlanguage "english" = {"number"} { curlanguage "ukrainian" = curlanguage "russian" = or % {"{\cyr\cyrn\cyro\cyrm\cyre\cyrr}"} % {"{номер}"} { curlanguage "german" = {"{Heft}"} %%% { "anzahl" }??? {"language is not defined: " curlanguage " in bbl.number" * * warning$ "number"} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.nr} % Put a "number" specifier corresponding to current language on stack. % % \changes{v1.0}{29 Sep 2022}{Make "no." number specifier replaceable through \cs{BibEnNo} macro.} % \begin{macrocode} FUNCTION {bbl.nr} { curlanguage "english" = {"{\BibEnNo}"} { curlanguage "italian" = { "no." } { curlanguage "ukrainian" = curlanguage "russian" = or % { "{\cyr\textnumero}" } % { "{№}" } { curlanguage "german" = {"{nu.}"} %%% { "an." } { curlanguage "french" = { "no." } {"language is not defined: " curlanguage " in bbl.nr" * * warning$ "\BibEnNo{}"} if$} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.nnr} % A capital letter version of number sign. % \begin{macrocode} FUNCTION {bbl.nnr} { curlanguage "english" = {"No."} { curlanguage "ukrainian" = curlanguage "russian" = or % { "{\cyr\textnumero}" } % { "{№}" } { curlanguage "german" = {"{H.}"} %%% { "an." } {"language is not defined: " curlanguage " in bbl.nnr" * * warning$ "No."} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.in} % \begin{macrocode} FUNCTION {bbl.in} { curlanguage "english" = curlanguage "german" = or {"in"} { curlanguage "ukrainian" = curlanguage "russian" = or % { "{\cyr\cyrv}" } % { "{в}" } {"language is not defined: " curlanguage " in bbl.in" * * warning$ "in"} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.iin} % Currently not used. % \begin{macrocode} FUNCTION {bbl.iin} { curlanguage "english" = curlanguage "german" = or {"In"} { curlanguage "ukrainian" = curlanguage "russian" = or % { "\CYRV" } % { "{В}" } {"language is not defined: " curlanguage " in bbl.iin" * * warning$ "In"} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.pages} % \begin{macrocode} FUNCTION {bbl.pages} { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or {"p."} %%% {"pp."} { curlanguage "ukrainian" = curlanguage "russian" = or % {"{\cyr\cyrs.}"} % {"{с.}"} { curlanguage "german" = {"S."} %%%% { "s." } {"language is not defined: " curlanguage " in bbl.pages" * * warning$ "p."} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.page} % \begin{macrocode} FUNCTION {bbl.page} { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or {"p."} { curlanguage "ukrainian" = curlanguage "russian" = or % {"{\cyr\cyrs.}"} % {"{с.}"} { curlanguage "german" = {"S."} %%%% { "s." } {"language is not defined: " curlanguage " in bbl.page" * * warning$ "p."} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.ppages} % \begin{macrocode} FUNCTION {bbl.ppages} { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or {"P."} %%%% { "Pp." } { curlanguage "ukrainian" = curlanguage "russian" = or % {"{\cyr\CYRS.}"} % {"{С.}"} { curlanguage "german" = {"S."} {"language is not defined: " curlanguage " in bbl.ppages" * * warning$ "P."} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.ppage} % \begin{macrocode} FUNCTION {bbl.ppage} { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or {"P."} { curlanguage "ukrainian" = curlanguage "russian" = or % {"{\cyr\CYRS.}"} % {"{С.}"} { curlanguage "german" = {"S."} {"language is not defined: " curlanguage " in bbl.ppage" * * warning$ "P."} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.url} % Added in version 2016.07.07. % \changes{GOST v1.2e}{07 Jul 2016}{\texttt{bbl.url} added to replace URL string} % \changes{v1.0}{10 Sep 2022}{Remove legacy "Access mode" notice before URLs % for \texttt{dstu2015}.} % \begin{macrocode} FUNCTION {bbl.url} %<*!dstu2015> { curlanguage "english" = {"Access mode"} { curlanguage "ukrainian" = % { "{\CYRR\cyre\cyrzh\cyri\cyrm\ \cyrd\cyro\cyrs\cyrt\cyru\cyrp\cyru}" } % { "{Режим доступу}" } { curlanguage "russian" = % { "{\CYRR\cyre\cyrzh\cyri\cyrm\ \cyrd\cyro\cyrs\cyrt\cyru\cyrp\cyra}" } % { "{Режим доступа}" } { curlanguage "german" = { "{online; abgerufen}" } { curlanguage "french" = { "Mode d'acc\`{e}s" } { "language is not defined: " curlanguage " in bbl.url" * * warning$ "online; accessed" } if$} if$} if$} if$} if$} % %<*dstu2015> { "URL" } % % \end{macrocode} % \DescribeFunction{bbl.urldate} % Added in version 2012.01.15. % \changes{GOST v1.2}{13 Feb 2012}{fix \texttt{bbl.urldate} for ukrainian (Andrey Shvajkoy)} % \changes{v1.0}{23 Apr 2023}{\texttt{bbl.urldate}: Make first letter capital % for \texttt{strict} styles.} % \begin{macrocode} FUNCTION {bbl.urldate} { curlanguage "english" = {"online; accessed"} { curlanguage "ukrainian" = % { "{\cyrd\cyra\cyrt\cyra\ \cyrz\cyrv\cyre\cyrr\cyrn\cyre\cyrn\cyrn\cyrya}" } % { "{дата звернення}" } % { "{\CYRD\cyrz\cyrv\cyre\cyrr\cyrn\cyre\cyrn\cyrn\cyrya}" } % { "{Дата звернення}" } { curlanguage "russian" = % { "{\cyrd\cyra\cyrt\cyra\ \cyro\cyrb\cyrr\cyra\cyrshch\cyre\cyrn\cyri\cyrya}" } % { "{дата обращения}" } % { "{\CYRD\cyra\cyrt\cyra\ \cyro\cyrb\cyrr\cyra\cyrshch\cyre\cyrn\cyri\cyrya}" } % { "{Дата обращения}" } { curlanguage "german" = % { "{online; abgerufen}" } % { "{Online; abgerufen}" } { curlanguage "french" = % { "{en ligne; acc\'{e}d\'{e}}" } % { "{En ligne; acc\'{e}d\'{e}}" } { "language is not defined: " curlanguage " in bbl.urldate" * * warning$ "online; accessed" } if$} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.techreport} % \begin{macrocode} FUNCTION {bbl.techreport} { curlanguage "english" = { "Rep." } { curlanguage "german" = { "Bericht" } { curlanguage "russian" = % { "{\cyr\CYRO\cyrt\cyrch\cyre\cyrt}" } % { "{Отчет}" } { "language is not defined: " curlanguage " in bbl.techrep" * * warning$ "Rep." } if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.mathesis} % \begin{macrocode} FUNCTION {bbl.mathesis} { curlanguage "english" = { "Master's thesis" } { curlanguage "german" = { "diss.~mag." } { curlanguage "russian" = % { "{\cyr\cyrk\cyrv\cyra\cyrl\cyri\cyrf\cyri\cyrk\cyra\cyrc\cyri" % "\cyro\cyrn\cyrn\cyra\cyrya\ \cyrr\cyra\cyrb\cyro\cyrt\cyra\ " * % "\cyrm\cyra\cyrg\cyri\cyrs\cyrt\cyrr\cyra}" * } % { "{квалификационная работа магистра}" } { "language is not defined: " curlanguage " in bbl.mthesis" * * warning$ "Master's thesis" } if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.phdthesis} % \changes{GOST v1.2i}{04 Jan 2017}{corrected bbl.phdthesis and bbl.docthesis to comply GOST} % \changes{v1.0}{05 Apr 2023}{Ukrainian translation for Ph.\,D..} % \begin{macrocode} FUNCTION {bbl.phdthesis} { curlanguage "english" = { "Ph.\,D. thesis" } { curlanguage "german" = { "diss.~Ph.\,D." } { curlanguage "russian" = % { "{\cyr\cyrd\cyri\cyrs.\ \ldots\ \cyrk\cyra\cyrn\cyrd. " % "\cyrn\cyra\cyru\cyrk}" * } % { "{дис.\ \ldots\ канд.\ наук}" } { curlanguage "french" = { "th\`{e}se de doctorat" } { curlanguage "ukrainian" = % {"\cyr\cyrd\cyri\cyrs.~Ph.\,D."} % {"дис.~Ph.\,D."} { "language is not defined: " curlanguage " in bbl.phdthesis" * * warning$ "Ph.\,D. thesis" } if$} if$} if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.docthesis} % \begin{macrocode} FUNCTION {bbl.docthesis} { curlanguage "english" = { "dr.\,sci. dissertation" } { curlanguage "german" = { "diss.~dr." } { curlanguage "russian" = % { "{\cyr\cyrd\cyri\cyrs.\ \ldots\ \cyrd-\cyrr\cyra\ " % "\cyrn\cyra\cyru\cyrk}" * } % { "{дис.\ \ldots\ д-ра наук}" } { "language is not defined: " curlanguage " in bbl.docthesis" * * warning$ "Dr.\,Sci. dissertation" } if$} if$} if$} % \end{macrocode} % % \DescribeFunction{bbl.nnoaddress} % \changes{v1.0}{23 Apr 2023}{|bbl.nnoaddress| - add "ukrainian".} % \begin{macrocode} FUNCTION {bbl.nnoaddress} { curlanguage "english" = { "S.\ l." } { curlanguage "russian" = curlanguage "ukrainian" = + % { "{\cyr\CYRB.\ \cyrm.}" } % { "{Б.\ м.}" } { "language is not defined: " curlanguage " in bbl.nnoaddress" * * warning$ "S.\ l." } if$} if$} % \end{macrocode} % \DescribeFunction{bbl.nopublisher} % \changes{v1.0}{23 Apr 2023}{|bbl.nopublisher| - add "ukrainian".} % \begin{macrocode} FUNCTION {bbl.nopublisher} { curlanguage "english" = { "s.\ n." } { curlanguage "russian" = % { "{\cyr\cyrb.\ \cyri.}" } % { "{б.\ и.}" } { curlanguage "ukrainian" = % "{\cyr\cyrb.\ \cyrv.}" % { "б.\ в."} { "language is not defined: " curlanguage " in bbl.nopublisher" * * warning$ "s.\ n." } if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.nnopublisher} % \changes{v1.0}{23 Apr 2023}{|bbl.nnopublisher| - add "ukrainian".} % \begin{macrocode} FUNCTION {bbl.nnopublisher} { curlanguage "english" = { "S.\ n." } { curlanguage "russian" = % { "{\cyr\CYRB.\ \cyri.}" } % { "{Б.\ и.}" } { curlanguage "ukrainian" = % "{\cyr\CYRB.\ \cyrv.}" % { "Б.\ в."} { "language is not defined: " curlanguage " in bbl.nnopublisher" * * warning$ "s.\ n." } if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.media.text} % \begin{macrocode} FUNCTION {bbl.media.text} { curlanguage "english" = { "Text" } { curlanguage "russian" = curlanguage "ukrainian" = or % { "{\cyr\CYRT\cyre\cyrk\cyrs\cyrt}" } % { "{Текст}" } { "language is not defined: " curlanguage " in bbl.media" * * warning$ "Text" } if$} if$} % \end{macrocode} % \DescribeFunction{bbl.media.eresource} % \begin{macrocode} FUNCTION {bbl.media.eresource} { curlanguage "english" = { "Electronic resource" } { curlanguage "russian" = % { "{\cyr\CYREREV\cyrl\cyre\cyrk\cyrt\cyrr\cyro\cyrn\cyrn\cyrery\cyrishrt\ " % "\cyrr\cyre\cyrs\cyru\cyrr\cyrs}" * } % { "{Электронный ресурс}" } { curlanguage "ukrainian" = % { "{\cyr\CYRE\cyrl\cyre\cyrk\cyrt\cyrr\cyro\cyrn\cyrn\cyri\cyrishrt\ " % "\cyrr\cyre\cyrs\cyru\cyrr\cyrs}" * } % { "{Електронний ресурс}" } { "language is not defined: " curlanguage " in bbl.media" * * warning$ "Electronic resource" } if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.media.online} % \changes{GOST v1.2i}{02 Jan 2017}{\texttt{media} field normalised} % \begin{macrocode} FUNCTION {bbl.media.online} { curlanguage "english" = { "Electronic resource online" } { curlanguage "russian" = % { "{\cyr\CYREREV\cyrl\cyre\cyrk\cyrt\cyrr\cyro\cyrn\cyrn\cyrery\cyrishrt\ " % "\cyrr\cyre\cyrs\cyru\cyrr\cyrs\ \cyro\cyrn\cyrl\cyra\cyrishrt\cyrn}" * } % { "{Электронный ресурс онлайн}" } { curlanguage "ukrainian" = % { "{\cyr\CYRE\cyrl\cyre\cyrk\cyrt\cyrr\cyro\cyrn\cyrn\cyri\cyrishrt\ " % "\cyrr\cyre\cyrs\cyru\cyrr\cyrs\ \cyro\cyrn\cyrl\cyra\cyrishrt\cyr}" * } % { "{Електронний ресурс онлайн}" } { "language is not defined: " curlanguage " in bbl.media" * * warning$ "Electronic resource" } if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.chief} % \begin{macrocode} FUNCTION {bbl.chief} { curlanguage "english" = { "chief" } { curlanguage "russian" = % { "\cyrr\cyru\cyrk." } % { "{рук.}" } { curlanguage "ukrainian" = % { "\cyrr\cyru\cyrk." } % { "{рук.}" } { "language is not defined: " curlanguage " in bbl.chief" * * warning$ "chief" } if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.executor} % \begin{macrocode} FUNCTION {bbl.executor} { curlanguage "english" = { "executor" } { curlanguage "russian" = % { "{\cyr\cyri\cyrs\cyrp\cyro\cyrl\cyrn.}" } % { "{исполн.}" } { curlanguage "ukrainian" = % { "{\cyr\cyrv\cyri\cyrk\cyro\cyrn\cyra\cyrv\cyre\cyrc\cyrsftsn}" } % { "{виконавець}" } { "language is not defined: " curlanguage " in bbl.executor" * * warning$ "executor" } if$} if$} if$} % \end{macrocode} % \DescribeFunction{bbl.media} % \begin{macrocode} FUNCTION {bbl.media} { media "online" = { bbl.media.online } { media "eresource" = { bbl.media.eresource } { bbl.media.text } if$} if$} % \end{macrocode} % \DescribeFunction{bbl.req} % \begin{macrocode} FUNCTION {bbl.req} { curlanguage "english" = { "req." } { curlanguage "german" = { "ang." } { curlanguage "russian" = % { "{\cyr\cyrz\cyra\cyrya\cyrv\cyrl.}" } % { "{заявл.}" } { "language is not defined: " curlanguage " in bbl.req" * * warning$ "req" } if$ } if$ } if$ } % \end{macrocode} % \DescribeFunction{bbl.publ} % \begin{macrocode} FUNCTION {bbl.publ} { curlanguage "english" = { "publ." } { curlanguage "german" = { "ausg." } { curlanguage "russian" = % { "{\cyr\cyro\cyrp\cyru\cyrb\cyrl.}" } % { "{опубл.}" } { "language is not defined: " curlanguage " in bbl.publication" * * warning$ "publication" } if$ } if$ } if$ } % \end{macrocode} % \DescribeFunction{bbl.priority} % \begin{macrocode} FUNCTION {bbl.priority} { curlanguage "english" = { "priority" } { curlanguage "german" = { "Prioritat" } { curlanguage "russian" = % { "{\cyr\cyrp\cyrr\cyri\cyro\cyrr\cyri\cyrt\cyre\cyrt}" } % { "{приоритет}" } { "language is not defined: " curlanguage " in bbl.priority" * * warning$ "priority" } if$ } if$ } if$ } % \end{macrocode} % % % \DescribeFunction{bbl.jan} % \DescribeFunction{bbl.feb} % \DescribeFunction{bbl.mar} % \DescribeFunction{bbl.apr} % \DescribeFunction{bbl.may} % \DescribeFunction{bbl.jun} % \DescribeFunction{bbl.jul} % \DescribeFunction{bbl.aug} % \DescribeFunction{bbl.sep} % \DescribeFunction{bbl.oct} % \DescribeFunction{bbl.nov} % \DescribeFunction{bbl.dec} % New in version 1.2k. % \changes{GOST v1.2k}{22 Jan 2017}{added \texttt{bbl.jan}, \texttt{bbl.feb}, etc.} % \begin{macrocode} FUNCTION {bbl.jan} { curlanguage "english" = {"Jan."} { curlanguage "ukrainian" = % {"\CYRS\cyrii\cyrch."} % {"Січ."} % Січень { curlanguage "russian" = % { "\CYRYA\cyrn\cyrv." } % { "Янв." } { curlanguage "german" = { "Jan." } % Januar { "language is not defined: bbl.jan for " curlanguage * warning$ "Jan." } if$} if$} if$} if$} FUNCTION {bbl.feb} { curlanguage "english" = {"Feb."} { curlanguage "ukrainian" = % {"\CYRL\cyryu\cyrt."} % {"Лют."} % Лютий { curlanguage "russian" = % { "\CYRF\cyre\cyrv\cyrr." } % { "Фев." } { curlanguage "german" = {"Feb."} % Februar {"language is not defined: bbl.feb for " curlanguage * warning$ "Feb."} if$} if$} if$} if$} FUNCTION {bbl.mar} { curlanguage "english" = {"Mar."} { curlanguage "ukrainian" = % {"\CYRB\cyre\cyrr."} % {"Бер."} % Березень { curlanguage "russian" = % { "\CYRM\cyra\cyrr\cyrt" } % { "Март" } { curlanguage "german" = {"März"} % März {"language is not defined: bbl.mar for " curlanguage * warning$ "Mar."} if$} if$} if$} if$} FUNCTION {bbl.apr} { curlanguage "english" = {"Apr."} { curlanguage "ukrainian" = % {"\CYRK\cyrv\cyrii\cyrt."} % {"Квіт."} % квітень { curlanguage "russian" = % { "\CYRA\cyrp\cyrr." } % { "Апр." } { curlanguage "german" = {"Apr."} % April { "language is not defined: bbl.apr for " curlanguage * warning$ "Apr." } if$} if$} if$} if$} FUNCTION {bbl.may} { curlanguage "english" = {"May"} { curlanguage "ukrainian" = % {"\CYRT\cyrr\cyra\cyrv."} % {"Трав."} % травень { curlanguage "russian" = % { "\CYRM\cyra\cyrishrt" } % { "Май" } { curlanguage "german" = {"Mai"} { "language is not defined: bbl.may for " curlanguage * warning$ "May" } if$} if$} if$} if$} FUNCTION {bbl.jun} { curlanguage "english" = {"June"} { curlanguage "ukrainian" = % {"\CYRCH\cyre\cyrr."} % {"Чер."} % червень { curlanguage "russian" = % { "\CYRI\cyryu\cyrn\cyrsftsn" } % { "Июнь" } { curlanguage "german" = {"Juni"} { "language is not defined: bbl.jun for " curlanguage * warning$ "June" } if$} if$} if$} if$} FUNCTION {bbl.jul} { curlanguage "english" = {"July"} { curlanguage "ukrainian" = % {"\CYRL\cyri\cyrp."} % {"Липень"} %Липень { curlanguage "russian" = % { "\CYRI\cyryu\cyrl\cyrsftsn" } % { "Июль" } { curlanguage "german" = {"Juli"} { "language is not defined: bbl.jul for " curlanguage * warning$ "July" } if$} if$} if$} if$} FUNCTION {bbl.aug} { curlanguage "english" = {"Aug."} { curlanguage "ukrainian" = % {"\CYRS\cyre\cyrr."} % {"Серпень"} % Серпень { curlanguage "russian" = % { "\CYRA\cyrv\cyrg\." } % { "Авг." } { curlanguage "german" = {"Aug."} % August { "language is not defined: bbl.aug for " curlanguage * warning$ "Aug." } if$} if$} if$} if$} FUNCTION {bbl.sep} { curlanguage "english" = {"Sep."} { curlanguage "ukrainian" = % {"\CYRV\cyre\cyrr."} % {"Вер."} % вересень { curlanguage "russian" = % { "\CYRS\cyre\cyrn\cyrt." } % { "Сент." } { curlanguage "german" = {"Sep."} % September { "language is not defined: bbl.sep for " curlanguage * warning$ "Sep." } if$} if$} if$} if$} FUNCTION {bbl.oct} { curlanguage "english" = {"Oct."} { curlanguage "ukrainian" = % {"\CYRZH\cyro\cyrn."} % {"Жов."} % жовтень { curlanguage "russian" = % { "\CYRO\cyrk\cyrt." } % { "Окт." } { curlanguage "german" = {"Okt."} % Oktober { "language is not defined: bbl.oct for " curlanguage * warning$ "Oct." } if$} if$} if$} if$} FUNCTION {bbl.nov} { curlanguage "english" = {"Nov."} { curlanguage "ukrainian" = % {"\CYRL\cyri\cyrs."} % {"Лис."} % листопад { curlanguage "russian" = % { "\CYRN\cyro\cyrya\cyrb." } % { "Нояб." } { curlanguage "german" = {"Nov."} % November { "language is not defined: bbl.nov for " curlanguage * warning$ "Nov." } if$} if$} if$} if$} FUNCTION {bbl.dec} { curlanguage "english" = {"Dec."} { curlanguage "ukrainian" = % {"\CYRG\cyrr\cyru\cyrd."} % {"Груд."} % грудень { curlanguage "russian" = % { "\CYRD\cyre\cyrk." } % { "Дек." } { curlanguage "german" = {"Dez."} % Dezember { "language is not defined: bbl.dec for " curlanguage * warning$ "Dec." } if$} if$} if$} if$} % \end{macrocode} % % \DescribeFunction{bbl.arxiv} % \DescribeFunction{bbl.jstor} % \DescribeFunction{bbl.pubmed} % \DescribeFunction{bbl.googlebooks} % \DescribeFunction{bbl.hdl} % New in version 1.2k. % \changes{GOST v1.2k}{25 Dec 2020}{added \texttt{bbl.arxiv}, \texttt{bbl.jstor}, etc.} % \begin{macrocode} FUNCTION {bbl.arxiv} { curlanguage "english" = { "ArXiv" } { curlanguage "ukrainian" = % {"ArXiv"} % {"ArXiv"} { curlanguage "russian" = % { "ArXiv" } % { "ArXiv" } { curlanguage "german" = { "ArXiv" } { "language is not defined: bbl.arxiv for " curlanguage * warning$ "ArXiv" } if$} if$} if$} if$} FUNCTION {bbl.jstor} { curlanguage "english" = { "JSTOR" } { curlanguage "ukrainian" = % {"JSTOR"} % {"JSTOR"} { curlanguage "russian" = % { "JSTOR" } % { "JSTOR" } { curlanguage "german" = { "JSTOR" } { "language is not defined: bbl.jstor for " curlanguage * warning$ "JSTOR" } if$} if$} if$} if$} FUNCTION {bbl.pubmed} { curlanguage "english" = { "PubMed" } { curlanguage "ukrainian" = % {"PubMed"} % {"PubMed"} { curlanguage "russian" = % { "PubMed" } % { "PubMed" } { curlanguage "german" = { "PubMed" } { "language is not defined: bbl.pubmed for " curlanguage * warning$ "PubMed" } if$} if$} if$} if$} FUNCTION {bbl.googlebooks} { curlanguage "english" = { "Google Books" } { curlanguage "ukrainian" = % {"Google \CYRK\cyrn\cyri\cyrg\cyri"} % {"Google Книги"} { curlanguage "russian" = % { "Google \CYRK\cyrn\cyri\cyrg\cyri" } % { "Google Книги" } { curlanguage "german" = { "Google Books" } { "language is not defined: bbl.googlebooks for " curlanguage * warning$ "Google Books" } if$} if$} if$} if$} FUNCTION {bbl.hdl} { curlanguage "english" = { "Handle.Net" } { curlanguage "ukrainian" = % {"Handle.Net"} % {"Handle.Net"} { curlanguage "russian" = % { "Handle.Net" } % { "Handle.Net" } { curlanguage "german" = { "Handle.Net" } { "language is not defined: bbl.hdl for " curlanguage * warning$ "Handle.Net" } if$} if$} if$} if$} % \end{macrocode} % % % \subsection{Aliases}\label{s6.10} % % Aliases to some fields are introduced with the help of % \emph{field1}|.or.|\emph{field2} functions. % % \DescribeFunction{address.or.location} % Pushes |address| field if not empty; otherwise pushes |location| value even % if it is empty. % \changes{GOST v1.2i}{02 Jan 2017}{\texttt{location} field added as alias to \texttt{address} field} % \begin{macrocode} %FUNCTION {address.or.location} %{ % address empty$ % { location empty$ % 'skip$ % { location } % if$ } % { address } % if$ %} FUNCTION {address.or.location} { address empty$ { location } { address } if$ } % \end{macrocode} % % \DescribeFunction{specialitycode.or.number} % Pushed |specialitycode| value if not empty; otherwise % returns |number| value even if the latter is empty. % \changes{GOST v1.2i}{13 Jan 2017}{\texttt{number} field is now alias to \texttt{specialitycode}} % \begin{macrocode} FUNCTION {specialitycode.or.number} { specialitycode empty$ { number } { specialitycode } if$ } % \end{macrocode} % % \DescribeFunction{institution.or.school} % Pushes |institution| value if not empty; otherwise % returns |school| value even if the latter is empty. % \changes{GOST v1.2i}{13 Jan 2017}{\texttt{school} field is now alias to \texttt{instituttion}} % \begin{macrocode} FUNCTION {institution.or.school} { institution empty$ { school} { institution } if$ } % \end{macrocode} % % % \subsection{Formatting dates}\label{s6.7} % % \note{NEEDS to be located before natbib labels. This is experimental section. % Needs to be upgraded.} % % \DescribeFunction{date.to.year} % New in version 1.2k. Extracts year from date. Currently, only the date % of the form either |YYYY-MM-DD|, or |YYYY-MM|, or |YYYY| can be processed as % expected. Returns |date| if it is empty or has wrong format. % \changes{GOST v1.2j}{15 Jan 2017}{new function \texttt{date.to.year}} % \begin{macrocode} FUNCTION {date.to.year} { date empty$ { date } { %<*debug> "date.to.year::: date in " cite$ * " =" * date * warning$ "date.to.year::: length of date is " date text.length$ int.to.str$ * warning$ % date text.length$ #3 > { date #1 #4 substring$ 'y := %<*debug> ":::::: y=" y * warning$ % y } { "wrong format of date in " cite$ * ": date=" * date * warning$ date } if$ } if$ } % \end{macrocode} % % \DescribeFunction{date.to.month} % New in version 1.2k. Extracts month from date. % Returns |date| if it is empty or has wrong format. % \changes{GOST v1.2j}{15 Jan 2017}{new function \texttt{date.to.month}} % \begin{macrocode} FUNCTION {date.to.month} { date empty$ { date } { %<*debug> "date.to.month::: date in " cite$ * " =" * date * warning$ "date.to.month::: length of date is " date text.length$ int.to.str$ * warning$ % date text.length$ #6 > { date #6 #2 substring$ 'm := %<*debug> ":::::: m=" m * warning$ % m } { "wrong format of date in " cite$ * ": date=" * date * warning$ date } if$ } if$ } % \end{macrocode} % % \DescribeFunction{date.to.day} % New in version 1.2k. Extracts year from date. % Returns |date| if it is empty or has wrong format. % \changes{GOST v1.2j}{15 Jan 2017}{new function \texttt{date.to.day}} % \begin{macrocode} FUNCTION {date.to.day} { date empty$ { date } { %<*debug> "date.to.day::: date in " cite$ * " =" * date * warning$ "date.to.day::: length of date is " date text.length$ int.to.str$ * warning$ % date text.length$ #10 = { date #9 #2 substring$ 'd := %<*debug> ":::::: d=" d * warning$ % d } { "wrong format of date in " cite$ * ": date=" * date * warning$ date } if$ } if$ } % \end{macrocode} % % \DescribeFunction{year.or.date.to.year} % New in version 1.2k. Returns |year| if not empty; otherwise call |date.to.year|. % % \note{ВОЗМОЖНО, ПОДОБНЫЕ ФУНКЦИИ ЛУЧШЕ назвать \texttt{this.year}.} % \changes{GOST v1.2j}{15 Jan 2017}{new function \texttt{year.or.date.to.year}} % \begin{macrocode} FUNCTION {year.or.date.to.year} { year empty$ { %<*debug> "year.or.date.to.year::: empty year in " cite$ * warning$ % date.to.year } { year } if$ } % \end{macrocode} % % \DescribeFunction{format.month} % Reads |month| field and translate standard % English abbreviation of months (as defined by |jan|, |feb|, etc. macros below) % to current language. % \note{НАДО ИЗОБРЕСТИ ЧТО-ТО ВРОДЕ |month.or.date.to.month| % (|this.month|).} % \changes{GOST v1.2i}{29 Dec 2016}{typo fix in \texttt{format.month}} % \begin{macrocode} FUNCTION {format.month} { month empty$ { "" } { month "Jan." = { bbl.jan } { month "Feb." = { bbl.feb } { month "Mar." = { bbl.mar } { month "Apr." = { bbl.apr } { month "May" = { bbl.may } { month "Jun." = { bbl.jun } { month "Jul." = { bbl.jul } { month "Aug." = { bbl.aug } { month "Sep." = { bbl.sep } { month "Oct." = { "Окт." } { month "Nov." = { bbl.nov } { month "Dec." = { bbl.dec } { "unknown month in " cite$ * warning$ month } if$}if$}if$}if$}if$}if$}if$}if$}if$}if$}if$}if$} if$ } % \end{macrocode} % % \DescribeFunction{format.date} % \changes{GOST v1.2c}{17 Jan 2015}{fix Gost2003: \texttt{"}\texttt{-}\texttt{-}\texttt{-} replaced by macro \cs{BibDash}} % \changes{GOST v1.2j}{15 Jan 2017}{extraction of year from date added} % \changes{v1.0}{12 Mar 2023}{Remove \cs{BibDash} by default after year in dates for \texttt{dstu2015}.} % \begin{macrocode} FUNCTION {format.date} %{ year empty$ { year.or.date.to.year empty$ { month empty$ { "" } { "there's a month but no year in " cite$ * warning$ format.month } if$ } { month empty$ % 'year % { year ". \BibDash " format.month * * } 'year.or.date.to.year % { year.or.date.to.year ". \BibDash " format.month * * } % { year.or.date.to.year ". \DSTUBibDash " format.month * * } if$ } if$ } % \end{macrocode} % % % \subsection{Formatting names}\label{s6.6} % % Declare functions to format separate elements of a bibliographic reference. % % \textbf{Important note} % % Neither \file{bibtex} nor \file{bibtex8} can handle unicoded text without % troubles. In particular, they fail to reduce a Cyrillic name to initials. % Therefore we avoid using |f.| primitive (which trims first name to first letter) % when option |utf8| is in effect; in the latter caase |ff| primitive is called % instead. % % \begin{macrocode} INTEGERS { nameptr namesleft numnames } % \end{macrocode} % % \DescribeFunction{fmt.names.spec} % \DescribeFunction{fmt.names.reversespec} % Specifications for name formatting with |format.name$|: one for normal % order of initials and last name and one for reverse order. % \begin{macrocode} FUNCTION {fmt.names.spec} { "{vv~}{ll}{~jj}" % "{," % "{" % "~f{.\BibFirstNameSpace{}}{.}}" % "~ff}" * * } FUNCTION {fmt.names.reversespec} { % "{f{.\BibFirstNameSpace{}}{.~}}" % "{ff}" "{vv~}{ll}{~jj}" * } FUNCTION {fmt.names.firstnamespec} { % "{f.}" % "{ff}" } FUNCTION {fmt.names.lastnamespec} { "{vv~}{ll}{~jj}" } % \end{macrocode} % \DescribeFunction{fmt.names.single} % Format single name from \BibTeX "name list" in variable |s| with % position in variable |nameptr|. % Takes into acount whether the name is in "responsibility" section of % the bibliographic reference and whether it is a special name |"others"| % or |"~others"|. % \begin{macrocode} FUNCTION {fmt.names.single} { s nameptr fmt.names.lastnamespec format.name$ duplicate$ duplicate$ "others" = swap$ "~others" = or not { s nameptr fmt.names.firstnamespec format.name$ duplicate$ "" = 'skip$ { "\BibReplaceFirstNameChars{" swap$ "}" * * % ",~" % "~" swap$ * } if$ * fmt.responsibility.name { "\DSTUResponsibilityName{" swap$ "}{" s nameptr fmt.names.firstnamespec format.name$ duplicate$ "" = 'skip$ { "\BibReplaceFirstNameChars{" swap$ "}~" * * } if$ s nameptr fmt.names.lastnamespec format.name$ * "}" * * * * } 'skip$ if$ } 'skip$ if$ } % \end{macrocode} % % \DescribeFunction{fmt.names.first} % \DescribeFunction{fmt.names.three} % \DescribeFunction{fmt.names.all} % New version of functions formating names. Function name indicates number % of persons printed. These functions look for last literal in the stack % which should not be empty; hence, they should be called by other functions % that checks if the last literal is empty. % % \changes{v1.2}{09 Jan 2025}{Add automatic usage of % \cs{DSTUResponsibilityName} in the % responsibility section of bibliographic record. % Remove \cs{BibDash} by default after year in % dates for \texttt{dstu2015}. Add % \cs{DSTUAllowNamesAnd}.} % \begin{macrocode} FUNCTION {fmt.names.first} { 's := #1 'nameptr := fmt.names.single } FUNCTION {fmt.names.three} { 's := #1 'nameptr := s num.names$ 'numnames := numnames 'namesleft := { namesleft #0 > } { fmt.names.single 't := nameptr #1 > { nameptr #4 = numnames #4 > and { "others" 't := #1 'namesleft := } 'skip$ if$ namesleft #1 > { ", " * t * } { t "others" = t "~others" = or % { " " * bbl.etal * } % { " " * bbl.etal bracketise *} { ", " * t * } if$ } if$ } 't if$ nameptr #1 + 'nameptr := namesleft #1 - 'namesleft := } while$ } FUNCTION {fmt.names.all} { 's := #1 'nameptr := s num.names$ 'numnames := numnames 'namesleft := { namesleft #0 > } { fmt.names.single 't := nameptr #1 > { namesleft #1 > { ", " * t * } { numnames #2 > curlanguage "english" = and { "\ifnum \DSTUAllowNamesAnd>0, \fi{}" * t "others" = t "~others" = or % { " " * bbl.etal * } % { " " * bbl.etal bracketise * } { "\ifnum \DSTUAllowNamesAnd>0 " bbl.and " \else, \fi " * * * t * } if$ } { t "others" = t "~others" = or % { " " * bbl.etal * } % { " " * bbl.etal bracketise * } { "\ifnum \DSTUAllowNamesAnd>0{} " bbl.and " \else, \fi " * * * t * } if$ } if$ } if$ } 't if$ nameptr #1 + 'nameptr := namesleft #1 - 'namesleft := } while$ } % \end{macrocode} % % % \subsection{Formatting names (cont.)}\label{s6.9} % % \DescribeFunction{format.author} % Formats a list of authors for the heading part of a bibliographic record % by appying either |fmt.names.first|, |fmt.names.three| or |fmt.names.all| to % the field |author|, if it is not empty; % otherwise it pushes empty |author|. % This allows making a check as in the case of % |format.author "author" output.check|. % % \note{Однако заметим, что все другие % функции |format....| пустое поле замещают пустой строкой.} % \begin{macrocode} %FUNCTION {format.author} %{ author empty$ % %%%{ "" } % < v.1.2k % { author } % v.1.2k % %{ author format.names emphasize} % 1st if strict, <=3 otherwise %% { author fmt.names.all emphasize} %% { author fmt.names.first emphasize} %% { author fmt.names.three emphasize} % if$ %} FUNCTION {format.author} { author empty$ { author } %%%'skip$ %<*long> { author fmt.names.all } % %<*!long> {author num.names$ #4 < { % author fmt.names.first % author fmt.names.three } { "" } %%%'skip$ if$} % if$ } % \end{macrocode} % % \DescribeFunction{format.bookauthors} % Is used only once by |bookauthor.head| called in |inbook| entry. % \note{Not used anymore!} % \begin{macrocode} %<*debug> %FUNCTION {format.bookauthors} %{ bookauthor empty$ % { "" } % { bookauthor format.names}% cuts to 4 persons if |!strict| option % if$ %} % % % \end{macrocode} % % \DescribeFunction{format.author.rest} % Formats |author| to be placed after a slash in the zone of responsibiloty of % a bibliographic record. In contrast to |output.author.rest| does not check % number of items in the |author| field; it is recommended to use % |output.author.rest| instead whenever possible. % \note{Not used any more.} % \begin{macrocode} %<*debug> FUNCTION {format.author.rest} { %<*long> %%% Does this work? %%%skip$ % this seemed to work %%% "" % this seemed to work % %<*!long> author empty$ %%%{ "" } % < v.1.2k { author } % v.1.2k { author fmt.names.three } if$ % } % % \end{macrocode} % \DescribeFunction{format.bookauthors.rest} % \begin{macrocode} FUNCTION {format.bookauthors.rest} { bookauthor empty$ { "" } % { bookauthor fmt.names.all emphasize } % { bookauthor fmt.names.three emphasize } if$ } % \end{macrocode} % \DescribeFunction{format.editors.rest} % \begin{macrocode} FUNCTION {format.editors.rest} { editor empty$ { "" } % { bbl.edby "\ " * editor fmt.names.all * } % { bbl.edby "\ " * editor fmt.names.three * } if$ } % \end{macrocode} % \DescribeFunction{format.chief.rest} % Formats |editor| field for |report| and |techreport| entries. % \begin{macrocode} FUNCTION {format.chief.rest} { editor empty$ { "" } % { bbl.chief "\ " * editor fmt.names.all * } % { bbl.chief "\ " * editor fmt.names.three * } if$ } % \end{macrocode} % \DescribeFunction{format.executor.rest} % \begin{macrocode} FUNCTION {format.executor.rest} { author empty$ { "" } % { bbl.executor ": " * author fmt.names.all * } % { bbl.executor ": " * author fmt.names.three * } if$ } % \end{macrocode} % \DescribeFunction{format.compiler.rest} % \begin{macrocode} FUNCTION {format.compiler.rest} { compiler empty$ { "" } % { bbl.compiler "\ " * compiler fmt.names.all * } % { bbl.compiler "\ " * compiler fmt.names.three * } if$ } % \end{macrocode} % % % \subsection{Formatting natbib keys}\label{s6.8} % % \begin{macrocode} %<*natbib> % \end{macrocode} % % \DescribeFunction{fmt.names.brief} % Formats all names like |fmt.names.all| except that first name of every person is dropped % (dropped |ff| and |f.| modifiers). % % \note{Вероятно, нужно сократить число персон до 3х максимум. Что говорит ГОСТ? % Где используется это? В метке ссылки это расгиренный список авторов после % краткого списка и года в необязательном аргументе \cs{bibitem}.} % \begin{macrocode} FUNCTION {fmt.names.brief} { 's := #1 'nameptr := s num.names$ 'numnames := numnames 'namesleft := { namesleft #0 > } { s nameptr "{vv~}{ll}" format.name$ 't := nameptr #1 > { namesleft #1 > { ", " * t * } { numnames #2 > curlanguage "english" = and { "," * } 'skip$ if$ t "others" = t "~others" = or { " " bbl.etal * * } { " " bbl.and " " * * * t * } if$ } if$ } 't if$ nameptr #1 + 'nameptr := namesleft #1 - 'namesleft := } while$ } % \end{macrocode} % % \DescribeFunction{format.names.key} % Declares function to go to left part of optional argument of |\bibitem| in % the bibstyles generated with the option |natbib|. It cuts the list of person % to 2 at most and drops first name of every person. % \begin{macrocode} FUNCTION {format.names.key} { 's := set.language %%% уже вызвана в output.bibitem, но вроде бы нужна и здесь s #1 "{vv~}{ll}" format.name$ s num.names$ duplicate$ #2 > { pop$ " " bbl.etal * * } { #2 < 'skip$ { s #2 "{ff }{vv }{ll}{ jj}" format.name$ "others" = { " " bbl.etal * * } { " " bbl.and " " * * * s #2 "{vv~}{ll}" format.name$ * } if$ } if$ } if$ } % \end{macrocode} % % \DescribeFunction{format.key} % Substitute an empty last literal in the stack (usually, |author|) with the |key| field % if provided. Used as a heading of bibliographic record of |author| is empty. % \begin{macrocode} FUNCTION {format.key} { empty$ { key field.or.null } { "" } if$ } % \end{macrocode} % % \DescribeFunction{author.key.label} % Composes a key to be used as a reference label with natbib % styles. If |author| field is empty an attempt is made to retrieve |key| field. % If it is also empty 3 first letters are retreived from the citation key |cite$|. % If |author| field is not empty |format.names.key| defined above is called. % \begin{macrocode} FUNCTION {author.key.label} { author empty$ { key empty$ { cite$ #1 #3 substring$ } 'key if$ } { author format.names.key } if$ } % \end{macrocode} % % \DescribeFunction{author.editor.key.label} % \DescribeFunction{author.key.organization.label} % \DescribeFunction{editor.key.organization.label} % These functions operate similarly but engage a different set of fields. They % are called below by |calc.short.list|. % \begin{macrocode} FUNCTION {author.editor.key.label} { author empty$ { editor empty$ { key empty$ { cite$ #1 #3 substring$ } %'key %% causes lost of year { "{}" key * } %% Bug in bibtex8 ?? if$ } { editor format.names.key } if$ } { author format.names.key } if$ } FUNCTION {author.key.organization.label} { author empty$ { key empty$ { organization empty$ { cite$ #1 #3 substring$ } { "The " #4 organization chop.word #3 text.prefix$ } if$ } 'key if$ } { author format.names.key } if$ } FUNCTION {editor.key.organization.label} { editor empty$ { key empty$ { organization empty$ { cite$ #1 #3 substring$ } { "The " #4 organization chop.word #3 text.prefix$ } if$ } 'key if$ } { editor format.names.key } if$ } % \end{macrocode} % % \DescribeFunction{calc.short.list} % Calculates |short.list| for |\bibitem| label in natbib styles depending on the type of entry. % % \note{Нужна внимательная ревизия логики вычислений. В общем-то, она имеет значения в особом % случае, когда поле |author| пустое. } % \begin{macrocode} FUNCTION {calc.short.list} { type$ "book" = type$ "inbook" = or 'author.editor.key.label { type$ "proceedings" = 'editor.key.organization.label { type$ "manual" = 'author.key.organization.label 'author.key.label if$ } if$ } if$ 'short.list := } % \end{macrocode} % % \DescribeFunction{calc.label} % % \note{Вопреки названию, вычисляет только часть метки в [] для % \cs{bibitem}. Скобка после года не закрыта, так как еще может % быть добавлено a, b, \dots. Лучше перенести весь код |output.bibitem|. } % \begin{macrocode} FUNCTION {calc.label} { calc.short.list short.list "(" * % year duplicate$ empty$ year.or.date.to.year duplicate$ empty$ short.list key field.or.null = or { pop$ "" } 'skip$ if$ * 'label := } % \end{macrocode} % % \DescribeFunction{calc.long.list} % In case of |natbib| option, we need |calc.long.list| to compose % |output.bibitem|, and the latter, in its turn, requires some more functions. % \begin{macrocode} FUNCTION {calc.long.list} %% called 1 time only { type$ "book" = type$ "inbook" = or %'format.author.editor.brief { author empty$ { editor empty$ { "" } { editor fmt.names.brief } if$ } { author fmt.names.brief } if$ } { type$ "proceedings" = %'format.editor.brief { editor empty$ { "" } { editor fmt.names.brief } if$ } %'format.author.brief { author empty$ { "" } { author fmt.names.brief } if$ } if$ } if$ } % \end{macrocode} % % \begin{macrocode} % % \end{macrocode} % % % \subsection{Output functions (continued)}\label{s6.11} % % \DescribeFunction{output.address.publisher} % Outputs |address| (or |location|) and |publisher| fields separated by colon % if both fields are available; otherwise outputs that field which is not % empty. % \begin{macrocode} %<*!strict> FUNCTION {output.address.publisher} { address empty$ location empty$ and 'skip$ { address.or.location output publisher empty$ 'skip$ { new.colon } if$ } if$ publisher output } % %<*strict> FUNCTION {output.address.publisher} { address empty$ { bbl.nnoaddress publisher empty$ { "~: " * bbl.nopublisher * bracketise } { bracketise "~: " * publisher * } if$ } { address output new.colon publisher empty$ { bbl.nopublisher bracketise } { publisher } if$ } if$ output } % % \end{macrocode} % % \DescribeFunction{output.bibitem} % Is called at the beginning of any entry. It sets |curlanguage| % string variable based on |langid| or |language| field. % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{langid} added} % \changes{v1.0}{11 Sep 2022}{Added cleanup of new \texttt{output.needitalic} % state variable into \texttt{output.bibitem}.} % \changes{v1.2}{08 Jan 2025}{Added cleanup of new \texttt{output.needitalic} % state variable into \texttt{output.bibitem}.} % \changes{v1.2}{09 Jan 2025}{Added cleanup of new \texttt{fmt.responsibility.name} % state variable into \texttt{output.bibitem}.} % \begin{macrocode} FUNCTION {output.bibitem} { set.language newline$ "\bibitem" write$ %<*natbib> label extra.label * ")" * calc.long.list * bracketise write$ % cite$ bracify write$ newline$ "\selectlanguageifdefined" curlanguage bracify * write$ newline$ "" before.all 'output.state := #0 'output.needitalic := #0 'fmt.responsibility.name := } % \end{macrocode} % % \begin{macrocode} %<*natbib> %FUNCTION {output.bibitem} %{ newline$ % "\bibitem" write$ %% author.key.label %% year parenthesify * %% "; lbl:" label * * %% "; mfn:" calc.long.list * * % label % calc.long.list * % bracketise write$ % cite$ bracify write$ % newline$ % language empty$ % { "english" 'curlanguage := } % {language 'curlanguage := } % if$ % "\selectlanguageifdefined" curlanguage bracify * write$ % newline$ % "" % before.all 'output.state := %} % % \end{macrocode} % % % \subsection{Formatting title, booktitle, etc.}\label{s6.13} % % \textbf{Important note} % % Neither \file{bibtex.exe} nor \file{bibtex8.exe} can handle unicoded text without % troubles. In particular, \file{bibtex8} fails to change case of a string if it % contains Cyrillic letter. Therefore we avoid using |change.case$| when % option |utf8| is applied. % % \changes{v1.4}{15 Feb 2025}{Book volume is printed only if there is no % "series" and/or "issn". Otherwise it is a volume of series. I hope it is % always the case.} % % \DescribeFunction{format.bvolume} % \begin{macrocode} FUNCTION {format.bvolume} { series empty$ issn empty$ and { volume empty$ { "" } { bbl.vvol volume tie.connect "volume and number if they are not related to series" number either.or.check } if$ } { "" } if$ } % \end{macrocode} % \DescribeFunction{format.issn} % \changes{v1.1}{12 Sep 2023}{Added |format.issn|.} % \changes{v1.4}{24 Feb 2025}{Do not print colon symbol (\texttt{:}) by % default after ISSN in accordance to % DSTU~GOST~7.1-2006.} % \begin{macrocode} FUNCTION {format.issn} { issn empty$ { "" } { "ISSN\BibISSNcolon~\href{https://portal.issn.org/resource/ISSN/" issn * "}{" * issn * "}" * } if$ } % \end{macrocode} % \DescribeFunction{format.series.and.issn} % \changes{v1.4}{24 Feb 2025}{Do not print colon symbol (\texttt{:}) by % default after ISSN in accordance to % DSTU~GOST~7.1-2006.} % \begin{macrocode} FUNCTION {format.series.and.issn} { format.issn duplicate$ empty$ { pop$ series field.or.null } { series empty$ { "there's an issn, but no series in " cite$ * warning$ } { series swap$ ", " swap$ * * } if$ } if$ } % \end{macrocode} % % \DescribeFunction{format.number.series} % Represents the "series section" of bibliographic reference. % % \changes{v1.0}{29 Sep 2022} % {Force nonbreakable space ("tie") between "number sign" and number in % series number in \texttt{dstu2015}.} % \changes{v1.4}{15 Feb 2025} % {Replace nonbreakable space ("tie") between "number sign" and % number in series number with % \texttt{tie.or.discouragedbreak.connect}.} % \changes{v1.4}{24 Feb 2025}{\texttt{format.number.series} from now on % prints complete series section in accordance % to DSTU~GOST~7.1-2006.} % \begin{macrocode} FUNCTION {format.number.series} { number empty$ { format.series.and.issn duplicate$ empty$ volume empty$ or 'skip$ { "~; " * bbl.vvol volume tie.connect * } if$ } { series empty$ issn empty$ and { "there's a number but no series or issn in " cite$ * warning$ bbl.nnr number tie.or.discouragedbreak.connect } { %new.dblslash new.sentence format.series.and.issn volume empty$ 'skip$ { "~; " bbl.vvol volume tie.connect * * } if$ "~; " bbl.nr number tie.or.discouragedbreak.connect * * } if$ } if$ paranthesify.series } % \end{macrocode} % % \DescribeFunction{eng.ord} % Is not currently used. % \note{Note that |bbl.st|, |bbl.nd|, |bbl.rd|, |bbl.th| % are not defined.} % \begin{macrocode} %<*debug> FUNCTION {eng.ord} { duplicate$ "1" swap$ * #-2 #1 substring$ "1" = { bbl.th * } { duplicate$ #-1 #1 substring$ duplicate$ "1" = { pop$ bbl.st * } { duplicate$ "2" = { pop$ bbl.nd * } { "3" = { bbl.rd * } { bbl.th * } if$ } if$ } if$ } if$ } % % \end{macrocode} % % \DescribeFunction{convert.edition} % \begin{macrocode} FUNCTION {convert.edition} { edition % edition extract.num "l" change.case$ 's := % s "first" = s "1" = or % { bbl.first 't := } % { s "second" = s "2" = or % { bbl.second 't := } % { s "third" = s "3" = or % { bbl.third 't := } % { s "fourth" = s "4" = or % { bbl.fourth 't := } % { s "fifth" = s "5" = or % { bbl.fifth 't := } % { s #1 #1 substring$ is.num % { s eng.ord 't := } % { edition 't := } % if$ % } % if$ % } % if$ % } % if$ % } % if$ % } % if$ % t } % \end{macrocode} % % \DescribeFunction{format.edition} % \begin{macrocode} FUNCTION {format.edition} { edition empty$ { "" } { output.state mid.sentence = % { convert.edition "l" change.case$ " " * bbl.edition * } % { convert.edition "t" change.case$ " " * bbl.edition * } % { convert.edition " " * bbl.edition * } % { convert.edition " " * bbl.edition * } if$ } if$ } % \end{macrocode} % % \DescribeFunction{format.pages} % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{eid} added} % \begin{macrocode} FUNCTION {format.pages} { eid empty$ { pages empty$ { "" } { pages multi.page.check { bbl.ppages pages n.dashify tie.connect } { bbl.ppage pages tie.connect } if$ } if$ } { eid multi.page.check { bbl.ppages eid n.dashify tie.connect } { bbl.ppage eid tie.connect } if$ } if$ } % \end{macrocode} % % \DescribeFunction{format.pages.page} % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{eid} added} % \changes{GOST v1.2b}{19 Jan 2014}{entry field \texttt{numpages} renamed to \texttt{pagetotal}} % \begin{macrocode} FUNCTION {format.pages.page} { eid empty$ { pages empty$ { pagetotal empty$ { "" } { pagetotal bbl.pages tie.connect } if$ } { format.pages} if$ } { format.pages } if$ } % \end{macrocode} % % \DescribeFunction{format.vol.num.pages} % \changes{v1.0}{29 Sep 2022}{Force nonbreakable space ("tie") between % "number sign" and number in volume's number of pages.} % \begin{macrocode} FUNCTION {format.vol.num.pages} { volume field.or.null number empty$ 'skip$ { % ", {\BibEnNo}" number tie.or.space.connect * % ", {\BibEnNo}~" number * volume empty$ { "there's a number but no volume in " cite$ * warning$ } 'skip$ if$ } if$ pages empty$ 'skip$ { duplicate$ empty$ { pop$ format.pages } { ": " * pages n.dashify * } if$ } if$ } % \end{macrocode} % % \DescribeFunction{format.volume} % \changes{v1.2}{2025/02/03}{From now on after "Vol." (or its translation) % nonbreaking space is always inserted.} % \begin{macrocode} FUNCTION {format.volume} { volume empty$ { "" } { bbl.vvol volume tie.or.discouragedbreak.connect } if$ } % \end{macrocode} % \DescribeFunction{format.number} % \changes{v1.0}{29 Sep 2022} % {Force nonbreakable space ("tie") between "number sign" and number in % arbitrary formatted "numbers" in \texttt{dstu2015}.} % \begin{macrocode} FUNCTION {format.number} { number empty$ { "" } % { bbl.nr number tie.or.space.connect } % { bbl.nr "~" number * * } if$ } % \end{macrocode} % % \DescribeFunction{format.chapter.pages} % \begin{macrocode} %<*debug> FUNCTION {format.chapter.pages} { chapter empty$ 'format.pages { type empty$ { bbl.chapter } { type "l" change.case$ } if$ chapter tie.or.space.connect pages empty$ 'skip$ { ", " * format.pages * } if$ } if$ } % % \end{macrocode} % % \DescribeFunction{empty.misc.check} % \begin{macrocode} FUNCTION {empty.misc.check} { author empty$ title empty$ howpublished empty$ month empty$ year empty$ note empty$ and and and and and key empty$ not and { "all relevant fields are empty in " cite$ * warning$ } 'skip$ if$ } % \end{macrocode} % % \DescribeFunction{bbl.thesis.type} % % \note{ЭТУ ФУНКЦИЮ ПЕРЕНЕСТИ КУДА-ТО ВНИЗ ближе к |format.thesis.type| % И объединить с ней (?)} % \begin{macrocode} FUNCTION {bbl.thesis.type} { type "mathesis" = { bbl.mathesis } { type "phdthesis" = { bbl.phdthesis } { type "docthesis" = { bbl.docthesis } %%{ "!!!" type * "t" change.case$ } % { type "t" change.case$ } % { type } if$} if$} if$} % \end{macrocode} % % \DescribeFunction{format.thesis.type} % \begin{macrocode} %FUNCTION {format.thesis.type} %{ type empty$ % 'skip$ % { pop$ %% bbl.thesis.type "t" change.case$ %% bbl.thesis.type % } % if$ %} FUNCTION {format.thesis.type} { type empty$ 'skip$ { pop$ bbl.thesis.type } if$ } % \end{macrocode} % % \DescribeFunction{format.techrep.type.number} % Function to format report type and number. % \begin{macrocode} %FUNCTION {format.techrep.type.number} %{ type empty$ % { bbl.techreport } % 'type % if$ % number empty$ %% { "t" change.case$ } %% { "" } % { number tie.or.space.connect } % if$ %} FUNCTION {format.techreport.type} { type empty$ { bbl.techreport } 'type if$ } % \end{macrocode} % % \DescribeFunction{output.author.head} % Formats and writes list of authors in the heading of a bibliographic record. % The GOST bibstyles skip the list of authors in the beginning of the % bibliographic record if the number of authors is 4 or larger except for the % styles with suffix |l| which prints all authors in the % heading. The bibstyles compiled with the option |struct| print at most 1 person % name in the heading. % \begin{macrocode} FUNCTION {output.author.head} { author empty$ 'skip$ %<*long> { author fmt.names.all output.nonnull %new.sentence } % %<*!long> {author num.names$ #4 < { % author fmt.names.first output % author fmt.names.three output new.sentence } 'skip$ if$} % if$ } % \end{macrocode} % % \DescribeFunction{bookauthor.head} % There are also 2 version of the function |bookauthor.head|. % Not used anymore! % \begin{macrocode} % \end{macrocode} % % \DescribeFunction{output.author.rest} % Writes the rest of authors list after the entry title followed by a slash. % In modern bibstyles, the list of authors in the heading part of a bibliographic % record is cut to either 3 persons (if no |!strict| option is applied) or 1 % person (if |strict| option). By idea, |output.author.rest| should print the rest % of the authors in the |author| field but currently it also repeats the persons % printed in the heading part. |output.author.rest| returns a null string (|""|) % if all persons are printed in the heading part of the record. Note that all % persons are alwats printed in the heading part if |long| option is applied. % \begin{macrocode} FUNCTION {output.author.rest} { %<*!long> author empty$ 'skip$ % {author num.names$ #1 > % {author num.names$ #3 > { author fmt.names.all output new.semicolon } 'skip$ if$} if$ % } % \end{macrocode} % % \DescribeFunction{bookauthor.rest} % This function is used only in |inbook| entry. It always cuts list to 4 persons % since |format.bookauthors.rest| does that. % \begin{macrocode} FUNCTION {bookauthor.rest} { bookauthor empty$ 'skip$ { % bookauthor fmt.names.all output % bookauthor fmt.names.three output new.semicolon } if$ } % \end{macrocode} % \DescribeFunction{editor.organization.rest} % \begin{macrocode} FUNCTION {editor.organization.rest} { compiler empty$ {} { format.compiler.rest output new.semicolon } if$ editor empty$ {} { format.editors.rest output.nonnull new.semicolon } if$ organization empty$ {} {organization output.nonnull new.semicolon } if$ } % \end{macrocode} % \DescribeFunction{format.doi} % DOI entry formatting function. % \changes{v1.0}{11 Sep 2022}{Added DOI entry formatting function % \texttt{format.doi}.} % \changes{v1.2}{04 Feb 2025}{Added \cs{BibDOIFullURL} switch which makes % This style print URLs to |doi.org| instead of % just short identifiers.} % \begin{macrocode} FUNCTION {format.doi} { doi empty$ { "" } { "DOI: \ifnum \BibDOIFullURL>0\BibUrl{https://doi.org/" doi * "}\else\href{https://doi.org/" * doi * "}{{\urlstyle{same}\nolinkurl{" * doi * "}}}\fi" * } if$ } % \end{macrocode} % \DescribeFunction{format.url} % \changes{GOST v0.8}{06 Jun 2003}{macro \cs{BibUrl} added} % \changes{v1.0}{23 Apr 2023}{|format.url| - remove braced |urldate| for % |strict| styles.} % \begin{macrocode} FUNCTION {format.url} { url empty$ { "" } { bbl.url ": \BibUrl{" * url * "}" * %<*!strict> urldate empty$ { "" } { " (" bbl.urldate * ": " * urldate * ")" * } if$ * % } if$ } % \end{macrocode} % \DescribeFunction{output.url} % \changes{v1.0}{23 Apr 2023}{|output.url| - output |urldate| as separate block % for |strict| styles.} % \begin{macrocode} FUNCTION {output.url} { url empty$ 'skip$ { format.url output } if$ %<*strict> urldate empty$ 'skip$ { new.block bbl.urldate ": " * urldate * output } if$ % } % \end{macrocode} % \DescribeFunction{format.annote} % \changes{GOST v0.8}{06 Jun 2003}{macro \cs{BibAnnote} added} % \changes{v1.0}{23 Apr 2023}{|annote| prints as separate block for |strict| % styles.} % \begin{macrocode} FUNCTION {format.annote} { annote empty$ { "" } { % after.sentence 'output.state := % new.block "\BibAnnote{" annote add.period$ * "}" * } if$ } % \end{macrocode} % % \DescribeFunction{format.isbn} % \note{Do we really need to provide electronic search for ISBN?} % \changes{v1.0}{11 Sep 2022}{Fix broken ISBN URL.} % \changes{v1.4}{24 Feb 2025}{Do not print colon symbol (\texttt{:}) by % default after ISBN in accordance to % DSTU~GOST~7.1-2006.} % \begin{macrocode} FUNCTION {format.isbn} { isbn empty$ { "" } { "ISBN\BibISBNcolon~\href{https://isbndb.com/book/" isbn * "}{" * isbn * "}" * } if$ } % \end{macrocode} % % \DescribeFunction{add.doi} % The Digital Object Identifier (DOI) System is for identifying content % objects in the digital environment. DOI names are assigned to any entity % for use on digital networks. They are used to provide current information, % including where they (or information about them) can be found on the % Internet. Information about a digital object may change over time, % including where to find it, but its DOI name will not change. % % Function |add.doi| embraces last string in stack into hyperlink % that links it to specified |doi| identificator at https://doi.org/ web-site. % \changes{GOST v1.2k}{25 Dec 2020}{formatting of \texttt{doi} field updated} % \changes{v1.0}{10 Sep 2022}{\texttt{dstu2015} adds separate DOI entry, so % suppressing adding clickable DOI URL anywhere % else.} % \begin{macrocode} %<*eprint&!dstu2015> FUNCTION {add.doi} { duplicate$ empty$ 'skip$ { doi empty$ 'skip$ { "\href{https://doi.org/" doi * "}{" * swap$ * "}" * } if$ } if$ } % % \end{macrocode} % % If \file{.bst} style is compiled without |eprint| option, we just ignore % |doi| field. % \begin{macrocode} %<*!eprint|dstu2015> FUNCTION {add.doi} { } % % \end{macrocode} % % \DescribeFunction{add.media} % New in version 1.2. Adds |media| field if |strict| options is in effect. % If the |media| field is empty |add.media| prints a value based on the |type| % field. If the |type| is also empty |add.media| prints equivalent of the % word |text| in current language. % \begin{macrocode} %<*!strict> FUNCTION {add.media} { duplicate$ empty$ 'skip$ { media empty$ 'skip$ { " " * bbl.media bracketise * } if$ } if$ } % %<*strict> FUNCTION {add.media} { duplicate$ empty$ 'skip$ { media empty$ { type$ "online" = { " " * bbl.media.online bracketise * } { " " * bbl.media.text bracketise * } if$ } { " " * bbl.media bracketise * } if$ } if$ } % % \end{macrocode} % % \subsection{Electronic Publishing Information}\label{s6.14} % % The biblatex package provides three fields for electronic publishing % information: |eprint|, |eprinttype|, and |eprintclass|. The |eprint| field % is a verbatim field similar to |doi| which holds the identifier of the item. % The |eprinttype| field holds the resource name, i. e., the name of the % site or electronic archive. Optional |eprintclass| field is intended % for additional information specific to the resource indicated by the % |eprinttype| field. This could be a section, a path, classification % information, etc. If the |eprinttype| field is available, the standard styles % will use it as a literal label. In the following example, they would print % ``Resource: identifier'' rather than the generic ``eprint: identifier'': % \begin{verbatim} % eprint = {identifier}, % eprinttype = {Resource}, % \end{verbatim} % % \DescribeFunction{format.eprint} % The electronic identifier of an online publication. % This is roughly comparable to a |doi| but specific to a certain archive, % repository, service, or system. % Also see eprinttype and eprintclass. % % \note{This function should use url. TO BE DONE YET.} % \changes{GOST v1.2}{26 Jan 2012}{entry fields \texttt{eprint}, \texttt{eprintclass}, \texttt{eprinttype}} % \begin{macrocode} %<*eprint> %FUNCTION {format.eprint} %{ eprint empty$ % { "" } % { eprintclass empty$ % { " \href{http://arxiv.org/abs/" eprint * "}" * "{" * eprint * "}" * } % { eprinttype empty$ % { " \href{http://arxiv.org/abs/" eprint * "}" * % "{" * eprintclass * "/" * eprint * "}" * % } % { " \href{http://arxiv.org/abs/" eprint * "}" * % "{" * eprinttype * ":" * eprintclass * "/" * eprint * "}" * % } % if$} % if$} %if$} %FUNCTION {format.eprint} %{ eprint empty$ % { "" } % { eprinttype empty$ % { "" } % { eprinttype "~: " *} % if$ % eprintclass empty$ % { } % { eprintclass * "/" *} % if$ % eprint * % } % if$ % url empty$ % { } % { "\href{" url * "}{" * swap$ * "}" *} % if$ %} FUNCTION {format.eprint} { eprint empty$ { "" } { eprinttype empty$ { "" } { eprinttype "~: " *} if$ eprintclass empty$ { } { eprintclass * "/" *} if$ url empty$ { eprint * } { "\href{" * url * "}{" * eprint * "}" *} if$ } if$ } FUNCTION {output.eprint.url} { eprint empty$ { output.url } { format.eprint output } if$ } % %<*!eprint> FUNCTION {output.eprint.url} { output.url } % % \end{macrocode} % % Functions added in v1.2f to format patent entry (thanks to Stanislav Kruchinin). % % \changes{GOST v1.2f}{12 Jul 2016}{entry field \texttt{patent} added} % \changes{v1.0}{29 Sep 2022} % {Force nonbreakable space ("tie") between "number sign" and % number in arbitrary "added" "numbers" in \texttt{dstu2015}.} % \DescribeFunction{add.number} % \begin{macrocode} FUNCTION {add.number} { duplicate$ empty$ { "" } % { bbl.nr swap$ tie.or.space.connect } % { bbl.nr swap$ "~" swap$ * * } if$ } % \end{macrocode} % \DescribeFunction{format.type.number} % \begin{macrocode} FUNCTION {format.type.number} { type empty$ { "" } { number empty$ { "" } { type number tie.or.space.connect } if$ } if$ } % \end{macrocode} % \DescribeFunction{format.requestdate} % \begin{macrocode} FUNCTION {format.requestdate} { requestdate empty$ { "" } { bbl.req requestdate tie.or.space.connect } if$ } % \end{macrocode} % \DescribeFunction{format.publicationdate} % \begin{macrocode} FUNCTION {format.publicationdate} { publicationdate empty$ { "" } { bbl.publ publicationdate tie.or.space.connect } if$ } % \end{macrocode} % % \DescribeFunction{format.prioritydate} % \begin{macrocode} FUNCTION {format.prioritydate} { prioritydate empty$ { "" } { bbl.priority prioritydate tie.or.space.connect } if$ } % \end{macrocode} % \DescribeFunction{format.journal.series} % \changes{v1.0}{05 Apr 2023} % {Added combining of \texttt{journal} and \texttt{series} for articles.} % \begin{macrocode} FUNCTION {format.journal.series} { journal series empty$ { skip$ } { add.period$ series tie.or.space.connect } if$ } % \end{macrocode} % % \subsection{Entry types} % % Text below in this section is borrowed from biblatex manual. Not every % field listed below is actually supported by GOST styles. So description % below should be considered as a goal or a feature request. % % The lists below indicate the fields supported by each entry type. % Note that the mapping of fields to an entry type is ultimately at the % discretion of the bibliography style. The lists below therefore serve % two purposes. They indicate the fields supported by the standard styles % which ship with this package and they also serve as a model for custom % styles. Note that the required fields are not strictly required % in all cases. The fields marked as optional % are optional in a technical sense. Bibliographical formatting rules % usually require more than just the required fields. The standard % styles will generally not perform any formal validity checks, but % custom styles may do so. Generic fields like abstract and annotation % or label and shorthand are not included in the lists below because they % are independent of the entry type. % % \subsubsection{Regular Types} % % \DescribeFunction{article} % An article in a journal, magazine, newspaper, or other periodical which forms a % self-contained unit with its own title. The title of the periodical is given in the % journaltitle field. If the issue has its own title in addition to the main title of % the periodical, it goes in the issuetitle field. Note that editor and related fields % refer to the journal while translator and related fields refer to the article. % % Required fields: author, title, journaltitle, year/date. % % Optional fields: translator, annotator, commentator, subtitle, titleaddon, % editor, editora, editorb, editorc, journalsubtitle, issuetitle, % issuesubtitle, language, origlanguage, series, volume, number, eid, issue, % month, pages, version, note, issn, addendum, pubstate, doi, eprint, % eprintclass, eprinttype, url, urldate. % % \changes{v1.1}{23 Sep 2023}{Added ISSN to articles.} % \changes{v1.2}{08 Jan 2025}{Fixed unexpected comma after authors of % articles in bibliographic records formatted % with "l" styles. % } % \begin{macrocode} FUNCTION {article} { output.bibitem output.author.head new.sentence % author format.key output title add.media "title" output.check new.slash output.author.rest new.dblslash format.journal.series emphasize add.doi "journal" output.check % new in v1.2 new.block format.date "year/date" output.check new.block format.volume output format.number output new.block format.pages.page output new.block format.issn output new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{book} % A \sout{single-volume} book with one or more authors where the authors % share credit for the work as a whole. In biblatex, this entry type also % covers the function of the |@inbook| type of traditional BibTeX. % % Required fields: author, title, year/date. % % Optional fields: editor, editora, editorb, editorc, translator, annotator, % commentator, introduction, foreword, afterword, subtitle, titleaddon, % maintitle, mainsubtitle, maintitleaddon, language, origlanguage, volume, % part, edition, volumes, series, number, note, publisher, location, isbn, % chapter, pages, pagetotal, addendum, pubstate, doi, eprint, eprintclass, % eprinttype, url, urldate. % \begin{macrocode} FUNCTION {book} { output.bibitem output.author.head new.sentence % author format.key output title add.doi add.media "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.slash output.author.rest editor.organization.rest new.sentence format.edition output new.block output.address.publisher format.date "year/date" output.check new.block format.bvolume output new.block format.pages.page output new.block format.number.series output new.block % format.isbn output % new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{booklet} % A book-like work without a formal publisher or sponsoring institution. Use the % field howpublished to supply publishing information in free format, if applicable. % The field type may be useful as well. % % Required fields: author/editor, title, year/date. % % Optional fields: subtitle, titleaddon, language, howpublished, type, note, % location, chapter, pages, pagetotal, addendum, pubstate, doi, eprint, % eprintclass, eprinttype, url, urldate. % % \begin{macrocode} FUNCTION {booklet} { output.bibitem output.author.head new.sentence % author format.key output title add.doi add.media "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.slash output.author.rest editor.organization.rest new.block howpublished output address.or.location output format.date "year/date" output.check new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{inbook} % A part of a book which forms a self-contained unit with its own title. % Note that the profile of this entry type is different from standard BibTeX. % % Required fields: author, title, booktitle, year/date. % % Optional fields: bookauthor, editor, editora, editorb, editorc, translator, % annotator, commentator, introduction, foreword, afterword, subtitle, % titleaddon, maintitle, mainsubtitle, maintitleaddon, booksubtitle, % booktitleaddon, language, origlanguage, volume, part, edition, volumes, % series, number, note, publisher, location, isbn, chapter, pages, addendum, % pubstate, doi, eprint, eprintclass, eprinttype, url, urldate. % \begin{macrocode} FUNCTION {inbook} { output.bibitem output.author.head new.sentence % author format.key output title add.doi add.media "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.slash output.author.rest new.dblslash % bookauthor.head booktitle "booktitle" output.check new.slash bookauthor.rest editor.organization.rest new.block format.edition output new.sentence output.address.publisher format.date "year/date" output.check new.block format.bvolume output new.block format.pages.page output new.block format.number.series output new.block % format.isbn output % new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{incollection} % A contribution to a collection which forms a self-contained unit with a distinct % author and title. The author refers to the title, the editor to the booktitle, % i. e., the title of the collection. % % Required fields: author, editor, title, booktitle, year/date. % % Optional fields: editora, editorb, editorc, translator, annotator, % commentator, introduction, foreword, afterword, subtitle, titleaddon, % maintitle, mainsubtitle, maintitleaddon, booksubtitle, booktitleaddon, % language, origlanguage, volume, part, edition, volumes, series, number, % note, publisher, location, isbn, chapter, pages, addendum, pubstate, doi, % eprint, eprintclass, eprinttype, url, urldate. % \begin{macrocode} FUNCTION {incollection} { output.bibitem output.author.head new.sentence % author format.key output new.sentence title add.doi add.media "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.slash output.author.rest new.dblslash booktitle "booktitle" output.check new.slash editor.organization.rest new.block output.address.publisher format.date "year/date" output.check new.block format.bvolume output new.block format.number.series output new.block format.pages.page output new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{proceedings} % A single-volume conference proceedings. This type is very similar to @collection. % It supports an optional organization field which holds the sponsoring institution. % The editor is omissible. % % Required fields: editor, title, year/date. % % Optional fields: subtitle, titleaddon, maintitle, mainsubtitle, % maintitleaddon, eventtitle, eventdate, venue, language, volume, part, % volumes, series, number, note, organization, publisher, location, month, % isbn, chapter, pages, pagetotal, addendum, pubstate, doi, eprint, % eprintclass, eprinttype, url, urldate. % \begin{macrocode} FUNCTION {proceedings} { output.bibitem % editor format.key output title add.doi add.media "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.slash editor.organization.rest new.block output.address.publisher % 1.2k moved from below new.block % added in v.1.2k format.date "year/date" output.check new.block format.bvolume output new.block format.pages.page output %%%output.address.publisher % 1.2k moved upper new.block format.number.series output new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{inproceedings} % An article in a conference proceedings. This type is similar to @incollection. It % supports an optional organization field. % % Required fields: author, editor, title, booktitle, year/date. % % Optional fields: subtitle, titleaddon, maintitle, mainsubtitle, % maintitleaddon, booksubtitle, booktitleaddon, eventtitle, eventdate, % venue, language, volume, part, volumes, series, number, note, organization, % publisher, location, month, isbn, chapter, pages, addendum, pubstate, doi, % eprint, eprintclass, eprinttype, url, urldate. % \changes{GOST v0.9}{07 Oct 2003}{bug fix in \texttt{@inproceedings} entry type} % \begin{macrocode} FUNCTION {inproceedings} { output.bibitem output.author.head new.sentence % author format.key output new.sentence title add.doi add.media "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.slash output.author.rest new.dblslash booktitle "booktitle" output.check new.slash editor.organization.rest new.block output.address.publisher % 1.2k moved from below new.block % added in v.1.2k % address empty$ % { publisher output % format.date "year/date" output.check % } % { address output.nonnull % new.colon % publisher output % format.date "year/date" output.check % } % if$ % output.address.publisher % moved upper in v.1.2k format.date "year/date" output.check new.block format.bvolume output new.block format.pages.page output new.block format.number.series output new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % \DescribeFunction{manual} % Technical or other documentation, not necessarily in printed form. The author or % editor is omissible. % % Required fields: author/editor, title, year/date. % % Optional fields: subtitle, titleaddon, language, edition, type, series, % number, version, note, organization, publisher, location, isbn, chapter, % pages, pagetotal, addendum, pubstate, doi, eprint, eprintclass, % eprinttype, url, urldate. % \changes{v1.1}{11 Oct 2023}{Added \texttt{new.sentence} after % \texttt{titleaddon}, because after it a next section of this bibliographic % entry starts.} % \begin{macrocode} FUNCTION {manual} { output.bibitem author empty$ { organization empty$ 'skip$ { organization output.nonnull address output } if$ } { format.author output.nonnull } if$ % author format.key output new.block title add.doi add.media "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.sentence author empty$ { organization empty$ { address new.block.checka address output } 'skip$ if$ } { organization address new.block.checkb organization output address output } if$ format.edition output format.date "year/date" output.check new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % \DescribeFunction{patent} % A patent or patent request. The number or record token is given in the number % field. Use the |type| field to specify the type and the |location| field to % indicate the scope of the patent, if different from the scope implied by the % type. Note that the location field is treated as a key list with this entry % type. % % Required fields: author, title, number, year/date. % % Optional fields: holder, subtitle, titleaddon, type, version, location, note, % date, month, year, addendum, pubstate, doi, eprint, eprint class, eprint type, % url, urldate. % \begin{macrocode} FUNCTION {patent} { output.bibitem title add.media output.nonnull new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.colon format.type.number output add.blank address.or.location output new.colon ipc output new.slash format.author "author" output.check add.blank authorcountry paranthesify output.nonnull % author format.key output new.semicolon holder output.nonnull new.semicolon credits output.nonnull new.block requestnumber add.number output new.semicolon format.requestdate output new.semicolon format.publicationdate output publication output new.semicolon format.prioritydate output prioritynumber output prioritycountry paranthesify output new.block note output new.sentence % format.doi output % new.block output.url format.annote output new.block pagetotal output fin.entry } % \end{macrocode} % \DescribeFunction{misc} % A fallback type for entries which do not fit into any other category. % Use the field howpublished to supply publishing information in free format, % if applicable. The field type may be useful as well. |author|, |editor|, and % |year| are omissible. % % Required fields: author/editor, title, year/date. % \begin{macrocode} FUNCTION {misc} { output.bibitem %format.author output % < v.1.2k output.author.head % v.1.2k %new.sentence % v.1.2k % author format.key output title howpublished new.sentence.checkb title add.media output howpublished new.block.checka howpublished output new.block format.date "year/date" output.check new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{unpublished} % A work with an author and a title which has not been formally published, such % as a manuscript or the script of a talk. Use the fields howpublished and note to % supply additional information in free format, if applicable. % % Required fields: author, title, year/date. % % Optional fields: subtitle, titleaddon, language, howpublished, note, % location, isbn, date, month, year, addendum, pubstate, url, urldate % \begin{macrocode} FUNCTION {unpublished} { output.bibitem output.author.head new.sentence % author format.key output title "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.slash output.author.rest editor.organization.rest new.block format.date "year/date" output.check new.block note "note" output.check new.sentence % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{online} % An online resource. Author, editor, and year are omissible. % This entry type is intended for sources such as web sites which are intrinsically % online resources. Note that all entry types support the url field. For example, % when adding an article from an online journal, it may be preferable to use the % |@article| type and its url field. % % Required fields: author/editor, title, year/date, url. % % Optional fields: subtitle, titleaddon, language, version, note, % organization, date, month, year, addendum, pubstate, urldate. % \changes{GOST v1.1}{15 Jan 2012}{Entry type \texttt{@online} added} % \begin{macrocode} FUNCTION {online} { output.bibitem format.author output % author format.key output title howpublished new.sentence.checkb title add.doi add.media "title" output.check new.colon % added in v.1.2k titleaddon output % added in v.1.2k % howpublished new.block.checka howpublished new.dblslash.checka % howpublished output % howpublished bracketise output editor.organization.rest new.sentence new.block output.address.publisher format.date output new.block % format.doi output % new.block % output.url output.eprint.url new.sentence note output format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{internet} % \DescribeFunction{www} % \DescribeFunction{webpage} % \DescribeFunction{ielectronic} % New in version 2012.02.15. % \begin{macrocode} FUNCTION {internet} {online} FUNCTION {www} {online} FUNCTION {webpage} {online} FUNCTION {electronic} {online} % \end{macrocode} % % \DescribeFunction{thesis} % New in version 2012.02.02. % % A thesis written for an educational institution to satisfy the requirements for a % degree. Use the type field to specify the type of thesis. % % Required fields: author, title, type, institution, year/date. % % Optional fields: subtitle, titleaddon, language, note, location, month, isbn, % chapter, pages, pagetotal, addendum, pubstate, doi, eprint, eprintclass, % eprinttype, url, urldate % % \changes{GOST v1.2}{02 Feb 2012}{\texttt{@thesis} entry} % \begin{macrocode} FUNCTION {thesis} { output.bibitem format.author "author" output.check % author format.key output new.sentence title add.doi add.media "title" output.check new.colon bbl.phdthesis format.thesis.type output.nonnull new.colon specialitycode.or.number output % code of the speciality, new in v.1.2i new.colon titleaddon output % date of defence and approvement; new in v.1.2i new.slash %%%format.author.rest output %% dupplicates athours from the head zone output.author.rest %% prints if num.names$ > 3 or > 1 new.semicolon %institution "institution" output.check institution.or.school "institution/school" output.check new.block output.address.publisher format.date "year/date" output.check new.block format.pages.page output new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % % \DescribeFunction{report} % New in version 2012.02.02. % % A technical report, research report, or white paper published by a university or % some other institution. Use the type field to specify the type of report. The sponsoring % institution goes in the institution field. % % Required fields: author, title, type, institution, year/date. % % Optional fields: subtitle, titleaddon, language, number, version, note, % location, month, isrn, chapter, pages, pagetotal, addendum, pubstate, doi, % eprint, eprintclass, eprinttype, url, urldate. % \changes{GOST v1.2}{02 Feb 2012}{\texttt{@report} entry} % \begin{macrocode} %FUNCTION {report} %{ % output.bibitem % output.author.head % new.sentence % title add.doi add.media "title" output.check % new.colon %% format.techrep.type.number output.nonnull % type "type" output.check % new.slash % output.author.rest % editor.organization.rest % new.block % address output % new.colon % institution "institution" output.check % format.date "year/date" output.check % new.block % note output % new.block % v.2 % format.pages.page output % v.2 % new.sentence %% output.url % output.eprint.url % format.annote output % fin.entry %} FUNCTION {report} { output.bibitem % output.author.head % new.sentence title add.doi add.media "title" output.check % title format.key output new.colon % added in v.1.2k titleaddon output % added in v.1.2k new.colon % format.techrep.type.number output.nonnull % type "type" output.check % format.report.type.number "type" output.check type "type" output.check new.colon number output new.slash %institution "institution" output.check institution.or.school "institution/school" output.check new.semicolon format.chief.rest output % from editor field new.semicolon format.executor.rest output % from author field new.block address.or.location output new.colon organization output format.date "year/date" output.check new.block % v.2 format.pages.page output % v.2 new.sentence % или new.block ? % format.doi output % new.block output.eprint.url new.block note output format.annote output fin.entry } % \end{macrocode} % % \subsubsection{Type Aliases} % % The entry types listed in this section are provided for backwards compatibility % with traditional BibTeX styles. These aliases are resolved by BibTeX as the data is % exported. Bibliography styles will see the entry type the alias points to, not the % alias name. All unknown entry types are generally exported as @misc. % % \DescribeFunction{phdthesis} % Similar to @thesis except that the type field is optional and defaults to the localized % term `PhD thesis'. You may still use the type field to override that. % \begin{macrocode} FUNCTION {phdthesis} { output.bibitem format.author "author" output.check % author format.key output new.sentence title add.doi add.media "title" output.check new.colon bbl.phdthesis format.thesis.type output.nonnull new.colon %%number output % code of the speciality specialitycode.or.number output % code of the speciality, new in v.1.2i new.colon titleaddon output % date of defence and approvement; new in v.1.2i new.slash %%%format.author.rest output %% dupplicates athours output.author.rest %% prints if num.names$ > 3 or > 1 new.semicolon %institution "institution" output.check institution.or.school "institution/school" output.check new.block output.address.publisher format.date "year/date" output.check new.block format.pages.page output new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % \DescribeFunction{mastersthesis} % Similar to |@thesis| except that the type field is optional and defaults to the localized % term `Master's thesis'. You may still use the type field to override that. % \changes{GOST v1.2i}{29 Dec 2016}{entry \texttt{@MastersThesis} added again (see v1.1)} % \begin{macrocode} FUNCTION {mastersthesis} { output.bibitem format.author "author" output.check % author format.key output new.sentence title add.doi add.media "title" output.check new.colon bbl.mathesis format.thesis.type output.nonnull new.colon %%number output % code of the speciality specialitycode.or.number output % code of the speciality, new in v.1.2i new.colon titleaddon output % date of defence and approvement; new in v.1.2i new.slash %%%format.author.rest output %% dupplicates athours output.author.rest %% prints if num.names$ > 3 or > 1 new.semicolon %institution "institution" output.check institution.or.school "institution/school" output.check new.block output.address.publisher format.date "year/date" output.check new.block format.pages.page output new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % \DescribeFunction{docthesis} % Similar to |@thesis| except that the type field is optional and defaults to the localized % term `Doctor's of sciences thesis'. You may still use the type field to override that. % \changes{GOST v1.2i}{02 Jan 2017}{\texttt{@dscithesis} entry renamed to \texttt{@docthesis}} % \begin{macrocode} FUNCTION {docthesis} { output.bibitem format.author "author" output.check % author format.key output new.sentence title add.doi add.media "title" output.check new.colon bbl.docthesis format.thesis.type output.nonnull new.colon %%number output % code of the speciality specialitycode.or.number output % code of the speciality, new in v.1.2i new.colon titleaddon output % date of defence and approvement; new in v.1.2i new.slash %%%format.author.rest output %% dupplicate athours output.author.rest %% prints if num.names$ > 3 or > 1 new.semicolon %institution "institution" output.check institution.or.school "institution/school" output.check new.block output.address.publisher format.date "year/date" output.check new.block format.pages.page output new.block note output new.sentence % format.doi output % new.block % output.url output.eprint.url format.annote output fin.entry } % \end{macrocode} % \DescribeFunction{conference} % \begin{macrocode} FUNCTION {conference} { inproceedings } % \end{macrocode} % % \DescribeFunction{techreport} % TechReport is similar to |@report| except that the |type| field is optional % and defaults to the localized term `technical report'. % You may still use the type field to override that. % \begin{macrocode} %FUNCTION {techreport} %{ % output.bibitem % output.author.head % new.sentence % title add.doi add.media "title" output.check % new.colon % format.techrep.type.number output.nonnull % new.slash % output.author.rest % editor.organization.rest % new.block % address output % new.colon % institution "institution" output.check % format.date "year/date" output.check % new.block % note output % new.block % v.2 % format.pages.page output % v.2 % new.sentence %% output.url % output.eprint.url % format.annote output % fin.entry %} FUNCTION {techreport} { output.bibitem % output.author.head % new.sentence title add.doi add.media "title" output.check % title format.key output new.colon % format.techrep.type.number output.nonnull % type "type" output.check % format.report.type.number "type" output.check % type output format.techreport.type output new.colon number output new.slash %institution "institution" output.check institution.or.school "institution/school" output.check new.semicolon format.chief.rest output % from editor field new.semicolon format.executor.rest output % from author field new.block address.or.location output new.colon organization output format.date "year/date" output.check new.block % v.2 format.pages.page output % v.2 new.sentence % или new.block ? % format.doi output % new.block output.eprint.url new.block note output format.annote output fin.entry } % \end{macrocode} % \DescribeFunction{default.type} % \begin{macrocode} FUNCTION {default.type} { misc } % \end{macrocode} % % \subsection{Month Abbreviations} % Borrowed from \file{merlin.mbs} of package \pkg{custom-bib}. This is done for % backward compatibility with standard .bst styles which are designed for English. % The string in the definition of any month macro must coincide with that used in % |format.month| function in the above. % \changes{GOST v1.2d}{18 Feb 2016}{\cs{bbljan} etc. macros removed} % \begin{macrocode} MACRO {jan} {"Jan."} MACRO {feb} {"Feb."} MACRO {mar} {"Mar."} MACRO {apr} {"Apr."} MACRO {may} {"May"} MACRO {jun} {"Jun."} MACRO {jul} {"Jul."} MACRO {aug} {"Aug."} MACRO {sep} {"Sep."} MACRO {oct} {"Oct."} MACRO {nov} {"Nov."} MACRO {dec} {"Dec."} % \end{macrocode} % % \subsection{Journal Abbreviations} % % \subsubsection{Physics and astronomy} % % Borrowed from \file{physjour.mbs} of package \pkg{custom-bib}. % \begin{macrocode} MACRO {aa}{"Astron.\ \& Astrophys."} MACRO {aasup}{"Astron.\ \& Astrophys.\ Suppl.\ Ser."} MACRO {aj} {"Astron.\ J."} MACRO {aph} {"Acta Phys."} MACRO {advp} {"Adv.\ Phys."} MACRO {ajp} {"Amer.\ J.\ Phys."} MACRO {ajm} {"Amer.\ J.\ Math."} MACRO {amsci} {"Amer.\ Sci."} MACRO {anofd} {"Ann.\ Fluid Dyn."} MACRO {am} {"Ann.\ Math."} MACRO {ap} {"Ann.\ Phys.\ (NY)"} MACRO {adp} {"Ann.\ Phys.\ (Leipzig)"} MACRO {ao} {"Appl.\ Opt."} MACRO {apl} {"Appl.\ Phys.\ Lett."} MACRO {app} {"Astroparticle Phys."} MACRO {apj} {"Astrophys.\ J."} MACRO {apjsup} {"Astrophys.\ J.\ Suppl."} MACRO {apss} {"Astrophys.\ Space Sci."} MACRO {araa} {"Ann.\ Rev.\ Astron.\ Astrophys."} MACRO {baas} {"Bull.\ Amer.\ Astron.\ Soc."} MACRO {baps} {"Bull.\ Amer.\ Phys.\ Soc."} MACRO {cmp} {"Comm.\ Math.\ Phys."} MACRO {cpam} {"Commun.\ Pure Appl.\ Math."} MACRO {cppcf} {"Comm.\ Plasma Phys.\ \& Controlled Fusion"} MACRO {cpc} {"Comp.\ Phys.\ Comm."} MACRO {cqg} {"Class.\ Quant.\ Grav."} MACRO {cra} {"C.\ R.\ Acad.\ Sci.\ A"} MACRO {fed} {"Fusion Eng.\ \& Design"} MACRO {ft} {"Fusion Tech."} MACRO {grg} {"Gen.\ Relativ.\ Gravit."} MACRO {ieeens} {"IEEE Trans.\ Nucl.\ Sci."} MACRO {ieeeps} {"IEEE Trans.\ Plasma Sci."} MACRO {ijimw} {"Interntl.\ J.\ Infrared \& Millimeter Waves"} MACRO {ip} {"Infrared Phys."} MACRO {irp} {"Infrared Phys."} MACRO {jap} {"J.\ Appl.\ Phys."} MACRO {jasa} {"J.\ Acoust.\ Soc.\ America"} MACRO {jcp} {"J.\ Comp.\ Phys."} MACRO {jchp} {"J.\ Chem.\ Phys."} MACRO {jetp} {"Sov.\ Phys.--JETP"} MACRO {jfe} {"J.\ Fusion Energy"} MACRO {jfm} {"J.\ Fluid Mech."} MACRO {jmp} {"J.\ Math.\ Phys."} MACRO {jne} {"J.\ Nucl.\ Energy"} MACRO {jnec} {"J.\ Nucl.\ Energy, C: Plasma Phys., Accelerators, Thermonucl.\ Res."} MACRO {jnm} {"J.\ Nucl.\ Mat."} MACRO {jpc} {"J.\ Phys.\ Chem."} MACRO {jpp} {"J.\ Plasma Phys."} MACRO {jpsj} {"J.\ Phys.\ Soc.\ Japan"} MACRO {jsi} {"J.\ Sci.\ Instrum."} MACRO {jvst} {"J.\ Vac.\ Sci.\ \& Tech."} MACRO {nat} {"Nature"} MACRO {nature} {"Nature"} MACRO {nedf} {"Nucl.\ Eng.\ \& Design/Fusion"} MACRO {nf} {"Nucl.\ Fusion"} MACRO {nim} {"Nucl.\ Inst.\ \& Meth."} MACRO {nimpr} {"Nucl.\ Inst.\ \& Meth.\ in Phys.\ Res."} MACRO {np} {"Nucl.\ Phys."} MACRO {npb} {"Nucl.\ Phys.\ B"} MACRO {nt/f} {"Nucl.\ Tech./Fusion"} MACRO {npbpc} {"Nucl.\ Phys.\ B (Proc.\ Suppl.)"} MACRO {inc} {"Nuovo Cimento"} MACRO {nc} {"Nuovo Cimento"} MACRO {pf} {"Phys.\ Fluids"} MACRO {pfa} {"Phys.\ Fluids A: Fluid Dyn."} MACRO {pfb} {"Phys.\ Fluids B: Plasma Phys."} MACRO {pl} {"Phys.\ Lett."} MACRO {pla} {"Phys.\ Lett.\ A"} MACRO {plb} {"Phys.\ Lett.\ B"} MACRO {prep} {"Phys.\ Rep."} MACRO {pnas} {"Proc.\ Nat.\ Acad.\ Sci.\ USA"} MACRO {pp} {"Phys.\ Plasmas"} MACRO {pop} {"Phys.\ Plasmas"} MACRO {ppcf} {"Plasma Phys.\ \& Controlled Fusion"} MACRO {phitrsl} {"Philos.\ Trans.\ Roy.\ Soc.\ London"} MACRO {prl} {"Phys.\ Rev.\ Lett."} MACRO {pr} {"Phys.\ Rev."} MACRO {physrev} {"Phys.\ Rev."} MACRO {pra} {"Phys.\ Rev.\ A"} MACRO {prb} {"Phys.\ Rev.\ B"} MACRO {prc} {"Phys.\ Rev.\ C"} MACRO {prd} {"Phys.\ Rev.\ D"} MACRO {pre} {"Phys.\ Rev.\ E"} MACRO {ps} {"Phys.\ Scripta"} MACRO {procrsl} {"Proc.\ Roy.\ Soc.\ London"} MACRO {rmp} {"Rev.\ Mod.\ Phys."} MACRO {rsi} {"Rev.\ Sci.\ Inst."} MACRO {science} {"Science"} MACRO {sciam} {"Sci.\ Am."} MACRO {sam} {"Stud.\ Appl.\ Math."} MACRO {st} {"Sky and Telesc."} % \end{macrocode} % % \subsubsection{Supplementary Journal Names} % % Borrowed from \file{suppjour.mbs} of package \pkg{custom-bib}. % \begin{macrocode} MACRO {cjp} {"Czech. J. Phys."} MACRO {el} {"Europhys. Lett."} MACRO {en} {"Europhys. News"} MACRO {fujitsustj} {"FUJITSU Sci. Tech. J."} MACRO {ieeeed} {"IEEE Trans. Electron Devices"} MACRO {ieeeim} {"IEEE Trans. Instrum. Meas."} MACRO {ieeejqe} {"IEEE J. Quantum Electron."} MACRO {ieeem} {"IEEE Trans. Magn."} MACRO {ieeeptl} {"IEEE Photonic Technol. Lett."} MACRO {ieeeuffc} {"IEEE Trans. Ultrason., Ferroelect., Freq. Cont."} MACRO {jem} {"J. Electron. Mater."} MACRO {jes} {"J. Electrochem. Soc."} MACRO {jetplett} {"JETP Lett."} MACRO {jjap} {"Japan. J. Appl. Phys."} MACRO {jpha} {"J. Phys. A: Math. Gen."} MACRO {jphb} {"J. Phys. B: At. Mol. Opt. Phys."} MACRO {jphbold} {"J. Phys. B: At. Mol. Phys."} MACRO {jphc} {"J. Phys.: Condens. Matter"} MACRO {jphcold} {"J. Phys. C: Solid State Phys."} MACRO {jphd} {"J. Phys. D: Appl. Phys."} MACRO {jvsta} {"J. Vac. Sci. Technol. A"} MACRO {jvstb} {"J. Vac. Sci. Technol. B"} MACRO {me} {"Microelectron. Eng."} MACRO {necrd} {"NEC Res.{\&} Develop."} MACRO {pa} {"Physica A"} MACRO {pb} {"Physica B"} MACRO {pc} {"Physica C"} MACRO {pd} {"Physica D"} MACRO {procieee} {"Proc. IEEE"} MACRO {procspie} {"Proc. SPIE"} MACRO {pssa} {"Phys. Stat. Sol. A"} MACRO {pssb} {"Phys. Stat. Sol. B"} MACRO {rpp} {"Rep. Progr. Phys."} MACRO {sm} {"Synthet. Metal"} MACRO {sost} {"Solid State Technol."} MACRO {ss} {"Surf. Sci."} MACRO {ssc} {"Solid State Commun."} MACRO {sst} {"Semicond. Sci. Technol."} MACRO {suplatt} {"Superlatt. Microstr."} MACRO {sust} {"Supercond. Sci. Technol."} MACRO {znat} {"Z. Naturforsch."} % \end{macrocode} % % \subsubsection{Optics} % % Borrowed from \file{photjour.mbs}. % \begin{macrocode} MACRO {appopt} {"Appl.\ Opt."} MACRO {bell} {"Bell Syst.\ Tech.\ J."} MACRO {ell} {"Electron.\ Lett."} MACRO {jasp} {"J.\ Appl.\ Spectr."} MACRO {jqe} {"IEEE J.\ Quantum Electron."} MACRO {jlwt} {"J.\ Lightwave Technol."} MACRO {jmo} {"J.\ Mod.\ Opt."} MACRO {josa} {"J.\ Opt.\ Soc.\ America"} MACRO {josaa} {"J.\ Opt.\ Soc.\ Amer.~A"} MACRO {josab} {"J.\ Opt.\ Soc.\ Amer.~B"} MACRO {jdp} {"J.\ Phys.\ (Paris)"} MACRO {oc} {"Opt.\ Commun."} MACRO {ol} {"Opt.\ Lett."} MACRO {os} {"Opt.\ Spectrosc."} MACRO {phtl} {"IEEE Photon. Technol. Lett."} MACRO {pspie} {"Proc.\ Soc.\ Photo-Opt.\ Instrum. Eng."} MACRO {vr} {"Vision Res."} MACRO {zph} {"Z.\ f.\ Physik"} MACRO {zphb} {"Z.\ f.\ Physik~B"} MACRO {zphd} {"Z.\ f.\ Physik~D"} % \end{macrocode} % % \subsubsection{Physics of condensed Matter} % % \begin{macrocode} MACRO {sse} {"Solid-State Electron."} MACRO {pss} {"Phys. Sol. State"} MACRO {nl} {"Nano Lett."} % \end{macrocode} % % \subsubsection{Soviet and Russian journals} % \note{To be extended.} % \begin{macrocode} MACRO {sjpp} {"Sov.\ J.\ Plasma Phys."} MACRO {spd} {"Sov.\ Phys.--Doklady"} MACRO {sptp} {"Sov.\ Phys.--Tech. Phys."} MACRO {spu} {"Sov.\ Phys.--Uspekhi"} %MACRO {ufn} {"\CYRU\CYRF\CYRN"} %MACRO {ufn} {"УФН"} MACRO {pu} {"Phys.--Uspekhi"} MACRO {sjot} {"Sov.\ J.\ Opt.\ Technol."} MACRO {sjqe} {"Sov.\ J.\ Quantum Electron."} MACRO {sleb} {"Sov.\ Phys.--Leb.\ Inst.\ Rep."} MACRO {stph} {"Sov.\ Phys.--Techn.\ Phys."} MACRO {stphl}{"Sov.\ Techn.\ Phys.\ Lett."} % \end{macrocode} % % \subsection{Main cycle} % % \begin{macrocode} READ % \end{macrocode} % % \subsection{Sorting} % % Next chunk of code governs sorting reference list by authors' names and % titles. % \begin{macrocode} %<*sort|natbib> % \end{macrocode} % \DescribeFunction{sortify} % \begin{macrocode} FUNCTION {sortify} { purify$ % "l" change.case$ } % % \end{macrocode} % \DescribeFunction{sort.format.names} % \begin{macrocode} %<*sort> %% ===================================== %% This version from old Gost package %%<*!natbib> FUNCTION {sort.format.names} { 's := #1 'nameptr := "" s num.names$ 'numnames := numnames 'namesleft := { namesleft #0 > } { nameptr #1 > { " " * } 'skip$ if$ s nameptr "{vv{ } }{ll{ }}{ f{ }}{ jj{ }}" format.name$ 't := nameptr numnames = t "others" = and { "et al" * } %{ bbl.etal * } { t sortify * } if$ nameptr #1 + 'nameptr := namesleft #1 - 'namesleft := } while$ } %% %% This version from plainnat.bst %% It ignores second and subsequent authors but include year. %%<*natbib> %FUNCTION {sort.format.names} %{ 's := % #1 'nameptr := % "" % s num.names$ 'numnames := % numnames 'namesleft := % { namesleft #0 > } % { % s nameptr "{vv{ } }{ll{ }}{ ff{ }}{ jj{ }}" format.name$ 't := % nameptr #1 > % { % " " * % namesleft #1 = t "others" = and % { "zzzzz" * } % { numnames #2 > nameptr #2 = and % { "zz" * year field.or.null * " " * } % 'skip$ % if$ % t sortify * % } % if$ % } % { t sortify * } % if$ % nameptr #1 + 'nameptr := % namesleft #1 - 'namesleft := % } % while$ %} %% %% ===================================== % \end{macrocode} % \DescribeFunction{sort.format.title} % \begin{macrocode} FUNCTION {sort.format.title} { 't := "A " #2 "An " #3 "The " #4 t chop.word % Removes "The " if any chop.word % Removes "An " if any chop.word % Removes "A " if any sortify #1 global.max$ substring$ } % \end{macrocode} % \DescribeFunction{author.sort} % \begin{macrocode} %% ===================================== %% This version from old gost package. %% %<*!natbib> FUNCTION {author.sort} { author empty$ { key empty$ { "to sort, need author or key in " cite$ * warning$ "" } { key sortify } if$ } { author num.names$ #4 < {author sort.format.names } {title sort.format.title} if$ } if$ } % %% This version from plainnat.bst %<*natbib> FUNCTION {author.sort} { author empty$ { key empty$ { "to sort, need author or key in " cite$ * warning$ "" } { key sortify } if$ } { author sort.format.names } if$ } % %% ===================================== % \end{macrocode} % \DescribeFunction{author.title.sort} % The function |author.title.sort| is used in the |presort| function only. % \begin{macrocode} FUNCTION {author.title.sort} { author empty$ { title empty$ { key empty$ { "to sort, need author, title, or key in " cite$ * warning$ "" } { key sortify } if$ } { title sort.format.title } if$ } { author num.names$ #4 < {author sort.format.names } {title sort.format.title} if$ } if$ } % \end{macrocode} % % \DescribeFunction{author.editor.sort} % \DescribeFunction{author.organization.sort} % \DescribeFunction{editor.organization.sort} % The function |author.editor.sort|, |author.organization.sort|, % |editor.organization.sort| are not currently used. See commented % text in function |presort|\#2. \note{WE NEED TO CORRECT THAT!} % \begin{macrocode} %<*natbib> %FUNCTION {author.editor.sort} %{ author empty$ % { editor empty$ % { key empty$ % { "to sort, need author, editor, or key in " cite$ * warning$ % "" % } % { key sortify } % if$ % } % { editor sort.format.names } % if$ % } % { author sort.format.names } % if$ %} % %FUNCTION {author.organization.sort} %{ author empty$ % { organization empty$ % { key empty$ % { "to sort, need author, organization, or key in " cite$ * warning$ % "" % } % { key sortify } % if$ % } % { "The " #4 organization chop.word sortify } % if$ % } % { author sort.format.names } % if$ %} FUNCTION {editor.organization.sort} { editor empty$ { organization empty$ { key empty$ { "to sort, need editor, organization, or key in " cite$ * warning$ "" } { key sortify } if$ } { "The " #4 organization chop.word sortify } if$ } { editor sort.format.names } if$ } % % \end{macrocode} % % \DescribeFunction{presort} % Function to compute |sort.key$|. % What is the space string \verb*|" "| for? % Version \#1 is for `sort` and `!natbib` options. % Version \#2 is for `sort` and `natbib` options. % Version \#3 is for `!sort` and `natbib` options. % \begin{macrocode} %<*!natbib> FUNCTION {presort}%#1 { author.title.sort " " * year field.or.null sortify * " " * title field.or.null sort.format.title * #1 entry.max$ substring$ 'sort.key$ := } % %<*natbib> FUNCTION {presort}%#2 { calc.label label sortify %author.title.sort " " * % ========= plainnat.bst ========= % type$ "book" = % type$ "inbook" = % or % 'author.editor.sort % { type$ "proceedings" = % 'editor.organization.sort % { type$ "manual" = % 'author.organization.sort % 'author.sort % if$ % } % if$ % } % if$ author.title.sort " " * year field.or.null sortify * " " * %cite$ title field.or.null sort.format.title * #1 entry.max$ substring$ 'sort.label := sort.label * % ================================ #1 entry.max$ substring$ 'sort.key$ := } % % %<*!sort> %<*natbib> INTEGERS { seq.num } FUNCTION {init.seq} { #0 'seq.num :=} EXECUTE {init.seq} FUNCTION {int.to.fix} { "000000000" swap$ int.to.str$ * #-1 #10 substring$ } FUNCTION {presort}%#3 { calc.label % computes label label sortify % initiates sort.label " " * seq.num #1 + 'seq.num := % advance seq.num seq.num int.to.fix % prepend seq.num with 0s 'sort.label := % set sort.label to seq.num sort.label * % append seq.num to label #1 entry.max$ substring$ % cut if too long 'sort.key$ := % set sort.key$ } % % %<*sort|natbib> ITERATE {presort} SORT % % \end{macrocode} % % \subsection{Bibliography list} % % We need to find longest label to put in into the argument of % the |thebibliography| environment. In case of |natbib| options % we also need to compute extra suffix for the |year| field if there two or % more entries for given label (=author/editor/organization) in that year. % % Declare global (external) strings used in calculation of the longest label. % \begin{macrocode} %STRINGS { longest.label } %STRINGS { longest.label last.label next.extra } %INTEGERS { number.label longest.label.width } %INTEGERS { number.label longest.label.width last.extra.num } % \end{macrocode} % % \DescribeFunction{initialize.longest.label} % Initialize those string. % \begin{macrocode} %<*!natbib> FUNCTION {initialize.longest.label} { "" 'longest.label := #1 'number.label := #0 'longest.label.width := } % %<*natbib> FUNCTION {initialize.longest.label} { "" 'longest.label := #0 int.to.chr$ 'last.label := "" 'next.extra := #0 'longest.label.width := #0 'last.extra.num := #0 'number.label := } % EXECUTE {initialize.longest.label} % \end{macrocode} % % \DescribeFunction{initialize.longest.label} % Iterate though the list of entries to compute |label|. % \begin{macrocode} %<*!natbib> FUNCTION {forward.pass} { number.label int.to.str$ 'label := number.label #1 + 'number.label := label width$ longest.label.width > { label 'longest.label := label width$ 'longest.label.width := } 'skip$ if$ } % %<*natbib> FUNCTION {forward.pass} { last.label label = { last.extra.num #1 + 'last.extra.num := last.extra.num int.to.chr$ 'extra.label := } { "a" chr.to.int$ 'last.extra.num := "" 'extra.label := label 'last.label := } if$ number.label #1 + 'number.label := } % ITERATE {forward.pass} % \end{macrocode} % % \DescribeFunction{reverse.pass} % |Natbib| styles require reverse iteration over all entries. % \begin{macrocode} %<*natbib> FUNCTION {reverse.pass} { next.extra "b" = { "a" 'extra.label := } 'skip$ if$ extra.label 'next.extra := extra.label duplicate$ empty$ 'skip$ { "{\natexlab{" swap$ * "}}" * } if$ 'extra.label := %%%label extra.label * 'label := } REVERSE {reverse.pass} FUNCTION {bib.sort.order} { sort.label 'sort.key$ := } ITERATE {bib.sort.order} SORT % % \end{macrocode} % \DescribeFunction{begin.bib} % Within |thebibliography| environment we define few formatting macros % for user to customize how the reference list is formatted. % % Code for |\BibReplaceFirstNameChars| is inspired by % \url{https://tex.stackexchange.com/a/693376}. I can not just redefine dush % locally, as I have done with |~|, because |-| is not of "active" character % class (and character class is fixed when character is being readed and % thus its character class can not be redefined by a macro nested inside % another macro). % % \changes{GOST v1.2a}{31 Aug 2012}{default for \cs{cyrdash} added} % \changes{GOST v0.8}{06 Jun 2003}{macro \cs{BibAnnote} added} % \changes{GOST v0.8}{06 Jun 2003}{macro \cs{BibUrl} added} % \changes{GOST v0.8}{10 Aug 2003}{macro \cs{BibEmph} added} % \changes{v1.0}{29 Sep 2022}{macro \cs{BibEnNo} added} % \changes{v1.0}{14 Apr 2023}{\cs{selectlanguageifdefined} now supports % \pkg{polyglossia} and enables TeX ligatures if it % is loaded (e.g. em and en dash shorthands).} % \changes{v1.0}{22 Apr 2023}{\cs{BibAnnote} is now is an identity macro, % because annotation (\texttt{annote} field) is % sometimes mandatory according to standards.} % \changes{v1.0}{03 Jun 2023}{macro \cs{BibFirstNameSpace} added} % \changes{v1.2}{09 Jan 2025}{macro \cs{DSTUResponsibilityName} added} % \changes{v1.2}{09 Jan 2025}{macro \cs{DSTUAllowNamesAnd} added} % \changes{v1.4}{24 Feb 2025}{macro \cs{BibISBNandISSNcolon}, % \cs{BibISBNcolon}, \cs{BibISSNcolon}, % \cs{DSTUAllowSeriesParentheses} added} % \begin{macrocode} FUNCTION {begin.bib} { "\begin{thebibliography}{" longest.label * "}" * write$ newline$ "\def\selectlanguageifdefined#1{" write$ newline$ "\ifdefined\ifbabellanguageloaded" write$ newline$ "\ifbabellanguageloaded{#1}{\selectlanguage{#1}}{}" write$ newline$ "\else\expandafter\ifx\csname date#1\endcsname\relax" write$ newline$ % "\else\language\csname l@#1\endcsname\fi\fi}" write$ newline$ "\else\selectlanguage{#1}\fi\fi" write$ newline$ "\ifdefined\addfontfeature\addfontfeature{Ligatures=TeX}\fi}" write$ newline$ "\providecommand*{\href}[2]{{\small #2}}" write$ newline$ "\providecommand*{\url}[1]{{\small #1}}" write$ newline$ "\providecommand*{\nobreakdash}{\relax}" write$ newline$ "\providecommand*{\BibUrl}[1]{\url{#1}}" write$ newline$ "\providecommand*{\BibDOIFullURL}{0}" write$ newline$ "\providecommand{\BibAnnote}[1]{#1}" write$ newline$ "\providecommand*{\BibEmph}[1]{#1}" write$ newline$ "\providecommand*{\BibEnNo}{no.}" write$ newline$ "\providecommand*{\BibFirstNameSpace}{\,}" write$ newline$ "\providecommand*{\BibSemicolonSpace}{~}" write$ newline$ "\providecommand*{\BibDiscouragedbreakSpace}{ \nolinebreak[3] }" write$ newline$ "\ProvideTextCommandDefault{\cyrdash}{\iflanguage{russian}{\hbox to.8em{--\hss--}}{\textemdash}}" write$ newline$ "\providecommand*{\BibDash}{\ifdim\lastskip>0pt\unskip\nobreak\hskip.2em plus 0.1em\fi" write$ newline$ "\cyrdash\hskip.2em plus 0.1em\ignorespaces}" write$ newline$ "\providecommand*{\DSTUAllowBibDash}{0}" write$ newline$ "\providecommand*{\DSTUBibDash}{\ifnum \DSTUAllowBibDash>0 \BibDash \fi}" write$ newline$ "\providecommand*{\DSTUResponsibilityName}[2]{#1}" write$ newline$ "\providecommand*{\DSTUAllowNamesAnd}{1}" write$ newline$ "\providecommand*\DSTUBibFirstNameDash{\ifdefined\nobreakdash\nobreakdash -\else -\fi}" write$ newline$ "\providecommand*{\DSTUreplaceminus}[1]{\DSTUdoreplaceminus #1-\relax}" write$ newline$ "\def\DSTUdoreplaceminus#1-#2\relax{" write$ "\ifx\relax#2\relax #1" write$ "\else #1\nobreakdash" write$ newline$ " -\DSTUdoreplaceminus#2\relax" write$ newline$ "\fi}" write$ newline$ "\providecommand*{\BibReplaceFirstNameChars}[1]{{\def~{\BibFirstNameSpace}\DSTUreplaceminus{#1}}}" write$ newline$ "\providecommand*{\BibISBNandISSNcolon}{}" write$ newline$ "\providecommand*{\BibISBNcolon}{\BibISBNandISSNcolon}" write$ newline$ "\providecommand*{\BibISSNcolon}{\BibISBNandISSNcolon}" write$ newline$ "\providecommand*{\DSTUAllowSeriesParentheses}{1}" write$ newline$ % "\providecommand{\natexlab}[1]{#1}" write$ newline$ preamble$ empty$ 'skip$ { preamble$ write$ newline$ } if$ } EXECUTE {begin.bib} EXECUTE {init.state.consts} ITERATE {call.type$} % \end{macrocode} % \DescribeFunction{end.bib} % \begin{macrocode} FUNCTION {end.bib} { newline$ % "\catcode`\/=11" write$ newline$ "\end{thebibliography}" write$ newline$ } EXECUTE {end.bib} % \end{macrocode} % % \begin{macrocode} % % \end{macrocode} % %\CheckSum{957} % %\Finale