]> gitweb.michael.orlitzky.com - mjotex.git/blob - mjo.bst
Add hyperref DOI support to mjo.bst (based on the urlbst tool).
[mjotex.git] / mjo.bst
1 %%
2 %% This is file `mjo.bst',
3 %% generated with the docstrip utility.
4 %%
5 %% The original source files were:
6 %%
7 %% merlin.mbs (with options: `ed-au,tit-it,jttl-rm,jwdvol,num-xser,isbn,issn,doi,edpar,ppx,ed,abr,ednx,mth-bare,xedn,etal-xc,url,url-blk,nfss,')
8 %% ----------------------------------------
9 %% *** ***
10 %%
11 %% Copyright 1994-2011 Patrick W Daly
12 % ===============================================================
13 % IMPORTANT NOTICE:
14 % This bibliographic style (bst) file has been generated from one or
15 % more master bibliographic style (mbs) files, listed above.
16 %
17 % This generated file can be redistributed and/or modified under the terms
18 % of the LaTeX Project Public License Distributed from CTAN
19 % archives in directory macros/latex/base/lppl.txt; either
20 % version 1 of the License, or any later version.
21 % ===============================================================
22 % Name and version information of the main mbs file:
23 % \ProvidesFile{merlin.mbs}[2011/11/18 4.33 (PWD, AO, DPC)]
24 % For use with BibTeX version 0.99a or later
25 %-------------------------------------------------------------------
26 % This bibliography style file is intended for texts in ENGLISH
27 % This is a numerical citation style, and as such is standard LaTeX.
28 % It requires no extra package to interface to the main text.
29 % The form of the \bibitem entries is
30 % \bibitem{key}...
31 % Usage of \cite is as follows:
32 % \cite{key} ==>> [#]
33 % \cite[chap. 2]{key} ==>> [#, chap. 2]
34 % where # is a number determined by the ordering in the reference list.
35 % The order in the reference list is alphabetical by authors.
36 %---------------------------------------------------------------------
37
38 ENTRY
39 { address
40 author
41 booktitle
42 chapter
43 doi
44 edition
45 editor
46 eid
47 howpublished
48 institution
49 isbn
50 issn
51 journal
52 key
53 month
54 note
55 number
56 organization
57 pages
58 publisher
59 school
60 series
61 title
62 type
63 url
64 volume
65 year
66 }
67 {}
68 { label }
69
70 STRINGS { doiprefix doiurl }
71 INTEGERS { hrefform }
72 FUNCTION {init.doi.variables}
73 {
74 "http://dx.doi.org/" 'doiurl := % prefix to make URL from DOI
75 "doi:" 'doiprefix := % text prefix printed before DOI ref
76 #2 'hrefform := % 0=no crossrefs; 1=hypertex xrefs; 2=hyperref refs
77 }
78 INTEGERS { output.state before.all mid.sentence after.sentence after.block }
79 FUNCTION {init.state.consts}
80 { #0 'before.all :=
81 #1 'mid.sentence :=
82 #2 'after.sentence :=
83 #3 'after.block :=
84 }
85 STRINGS { s t}
86 FUNCTION {output.nonnull}
87 { 's :=
88 output.state mid.sentence =
89 { ", " * write$ }
90 { output.state after.block =
91 { add.period$ write$
92 newline$
93 "\newblock " write$
94 }
95 { output.state before.all =
96 'write$
97 { add.period$ " " * write$ }
98 if$
99 }
100 if$
101 mid.sentence 'output.state :=
102 }
103 if$
104 s
105 }
106 FUNCTION {output}
107 { duplicate$ empty$
108 'pop$
109 'output.nonnull
110 if$
111 }
112 FUNCTION {output.check}
113 { 't :=
114 duplicate$ empty$
115 { pop$ "empty " t * " in " * cite$ * warning$ }
116 'output.nonnull
117 if$
118 }
119 FUNCTION {fin.entry}
120 { add.period$
121 write$
122 newline$
123 }
124
125 FUNCTION {new.block}
126 { output.state before.all =
127 'skip$
128 { after.block 'output.state := }
129 if$
130 }
131 FUNCTION {new.sentence}
132 { output.state after.block =
133 'skip$
134 { output.state before.all =
135 'skip$
136 { after.sentence 'output.state := }
137 if$
138 }
139 if$
140 }
141 FUNCTION {add.blank}
142 { " " * before.all 'output.state :=
143 }
144
145 FUNCTION {date.block}
146 {
147 new.block
148 }
149
150 FUNCTION {not}
151 { { #0 }
152 { #1 }
153 if$
154 }
155 FUNCTION {and}
156 { 'skip$
157 { pop$ #0 }
158 if$
159 }
160 FUNCTION {or}
161 { { pop$ #1 }
162 'skip$
163 if$
164 }
165 STRINGS {z}
166
167 FUNCTION {remove.dots}
168 { 'z :=
169 ""
170 { z empty$ not }
171 { z #1 #2 substring$
172 duplicate$ "\." =
173 { z #3 global.max$ substring$ 'z := * }
174 { pop$
175 z #1 #1 substring$
176 z #2 global.max$ substring$ 'z :=
177 duplicate$ "." = 'pop$
178 { * }
179 if$
180 }
181 if$
182 }
183 while$
184 }
185 FUNCTION {new.block.checka}
186 { empty$
187 'skip$
188 'new.block
189 if$
190 }
191 FUNCTION {new.block.checkb}
192 { empty$
193 swap$ empty$
194 and
195 'skip$
196 'new.block
197 if$
198 }
199 FUNCTION {new.sentence.checka}
200 { empty$
201 'skip$
202 'new.sentence
203 if$
204 }
205 FUNCTION {new.sentence.checkb}
206 { empty$
207 swap$ empty$
208 and
209 'skip$
210 'new.sentence
211 if$
212 }
213 FUNCTION {field.or.null}
214 { duplicate$ empty$
215 { pop$ "" }
216 'skip$
217 if$
218 }
219 FUNCTION {emphasize}
220 { duplicate$ empty$
221 { pop$ "" }
222 { "\emph{" swap$ * "}" * }
223 if$
224 }
225 FUNCTION {tie.or.space.prefix}
226 { duplicate$ text.length$ #3 <
227 { "~" }
228 { " " }
229 if$
230 swap$
231 }
232
233 FUNCTION {capitalize}
234 { "u" change.case$ "t" change.case$ }
235
236 FUNCTION {space.word}
237 { " " swap$ * " " * }
238 % Here are the language-specific definitions for explicit words.
239 % Each function has a name bbl.xxx where xxx is the English word.
240 % The language selected here is ENGLISH
241 FUNCTION {bbl.and}
242 { "and"}
243
244 FUNCTION {bbl.etal}
245 { "et~al." }
246
247 FUNCTION {bbl.editors}
248 { "eds." }
249
250 FUNCTION {bbl.editor}
251 { "ed." }
252
253 FUNCTION {bbl.edby}
254 { "edited by" }
255
256 FUNCTION {bbl.edition}
257 { "ed." }
258
259 FUNCTION {bbl.volume}
260 { "vol." }
261
262 FUNCTION {bbl.of}
263 { "of" }
264
265 FUNCTION {bbl.number}
266 { "no." }
267
268 FUNCTION {bbl.nr}
269 { "no." }
270
271 FUNCTION {bbl.in}
272 { "in" }
273
274 FUNCTION {bbl.pages}
275 { "" }
276
277 FUNCTION {bbl.page}
278 { "" }
279
280 FUNCTION {bbl.chapter}
281 { "chap." }
282
283 FUNCTION {bbl.techrep}
284 { "Tech. Rep." }
285
286 FUNCTION {bbl.mthesis}
287 { "Master's thesis" }
288
289 FUNCTION {bbl.phdthesis}
290 { "Ph.D. thesis" }
291
292 MACRO {jan} {"Jan."}
293
294 MACRO {feb} {"Feb."}
295
296 MACRO {mar} {"Mar."}
297
298 MACRO {apr} {"Apr."}
299
300 MACRO {may} {"May"}
301
302 MACRO {jun} {"Jun."}
303
304 MACRO {jul} {"Jul."}
305
306 MACRO {aug} {"Aug."}
307
308 MACRO {sep} {"Sep."}
309
310 MACRO {oct} {"Oct."}
311
312 MACRO {nov} {"Nov."}
313
314 MACRO {dec} {"Dec."}
315
316 MACRO {acmcs} {"ACM Computing Surveys"}
317
318 MACRO {acta} {"Acta Informatica"}
319
320 MACRO {cacm} {"Communications of the ACM"}
321
322 MACRO {ibmjrd} {"IBM Journal of Research and Development"}
323
324 MACRO {ibmsj} {"IBM Systems Journal"}
325
326 MACRO {ieeese} {"IEEE Transactions on Software Engineering"}
327
328 MACRO {ieeetc} {"IEEE Transactions on Computers"}
329
330 MACRO {ieeetcad}
331 {"IEEE Transactions on Computer-Aided Design of Integrated Circuits"}
332
333 MACRO {ipl} {"Information Processing Letters"}
334
335 MACRO {jacm} {"Journal of the ACM"}
336
337 MACRO {jcss} {"Journal of Computer and System Sciences"}
338
339 MACRO {scp} {"Science of Computer Programming"}
340
341 MACRO {sicomp} {"SIAM Journal on Computing"}
342
343 MACRO {tocs} {"ACM Transactions on Computer Systems"}
344
345 MACRO {tods} {"ACM Transactions on Database Systems"}
346
347 MACRO {tog} {"ACM Transactions on Graphics"}
348
349 MACRO {toms} {"ACM Transactions on Mathematical Software"}
350
351 MACRO {toois} {"ACM Transactions on Office Information Systems"}
352
353 MACRO {toplas} {"ACM Transactions on Programming Languages and Systems"}
354
355 MACRO {tcs} {"Theoretical Computer Science"}
356 FUNCTION {bibinfo.check}
357 { swap$
358 duplicate$ missing$
359 {
360 pop$ pop$
361 ""
362 }
363 { duplicate$ empty$
364 {
365 swap$ pop$
366 }
367 { swap$
368 pop$
369 }
370 if$
371 }
372 if$
373 }
374 FUNCTION {bibinfo.warn}
375 { swap$
376 duplicate$ missing$
377 {
378 swap$ "missing " swap$ * " in " * cite$ * warning$ pop$
379 ""
380 }
381 { duplicate$ empty$
382 {
383 swap$ "empty " swap$ * " in " * cite$ * warning$
384 }
385 { swap$
386 pop$
387 }
388 if$
389 }
390 if$
391 }
392 FUNCTION {format.url}
393 {
394 url
395 duplicate$ empty$
396 { pop$ "" }
397 { "\urlprefix\url{" swap$ * "}" * }
398 if$
399 }
400
401 INTEGERS { nameptr namesleft numnames }
402
403
404 STRINGS { bibinfo}
405
406 FUNCTION {format.names}
407 { 'bibinfo :=
408 duplicate$ empty$ 'skip$ {
409 's :=
410 "" 't :=
411 #1 'nameptr :=
412 s num.names$ 'numnames :=
413 numnames 'namesleft :=
414 { namesleft #0 > }
415 { s nameptr
416 "{ff~}{vv~}{ll}{, jj}"
417 format.name$
418 bibinfo bibinfo.check
419 't :=
420 nameptr #1 >
421 {
422 namesleft #1 >
423 { ", " * t * }
424 {
425 s nameptr "{ll}" format.name$ duplicate$ "others" =
426 { 't := }
427 { pop$ }
428 if$
429 numnames #2 >
430 t "others" = not and
431 { "," * }
432 'skip$
433 if$
434 t "others" =
435 {
436 " " * bbl.etal *
437 }
438 {
439 bbl.and
440 space.word * t *
441 }
442 if$
443 }
444 if$
445 }
446 't
447 if$
448 nameptr #1 + 'nameptr :=
449 namesleft #1 - 'namesleft :=
450 }
451 while$
452 } if$
453 }
454 FUNCTION {format.names.ed}
455 {
456 format.names
457 }
458 FUNCTION {format.authors}
459 { author "author" format.names
460 }
461 FUNCTION {get.bbl.editor}
462 { editor num.names$ #1 > 'bbl.editors 'bbl.editor if$ }
463
464 FUNCTION {format.editors}
465 { editor "editor" format.names duplicate$ empty$ 'skip$
466 {
467 " " *
468 get.bbl.editor
469 "(" swap$ * ")" *
470 *
471 }
472 if$
473 }
474 FUNCTION {format.isbn}
475 { isbn "isbn" bibinfo.check
476 duplicate$ empty$ 'skip$
477 {
478 new.block
479 "ISBN " swap$ *
480 }
481 if$
482 }
483
484 FUNCTION {format.issn}
485 { issn "issn" bibinfo.check
486 duplicate$ empty$ 'skip$
487 {
488 new.block
489 "ISSN " swap$ *
490 }
491 if$
492 }
493
494 FUNCTION {make.href.null}
495 {
496 pop$
497 }
498
499 FUNCTION {make.href.hypertex}
500 {
501 "\special {html:<a href=" quote$ *
502 swap$ * quote$ * "> }" * swap$ *
503 "\special {html:</a>}" *
504 }
505
506 FUNCTION {make.href.hyperref}
507 {
508 "\href {" swap$ * "} {\path{" * swap$ * "}}" *
509 }
510
511 FUNCTION {make.href}
512 { hrefform #2 =
513 'make.href.hyperref % hrefform = 2
514 { hrefform #1 =
515 'make.href.hypertex % hrefform = 1
516 'make.href.null % hrefform = 0 (or anything else)
517 if$
518 }
519 if$
520 }
521
522 FUNCTION {format.doi}
523 { doi empty$
524 { "" }
525 { doiprefix doi * doiurl doi * make.href }
526 if$
527 }
528 FUNCTION {format.note}
529 {
530 note empty$
531 { "" }
532 { note #1 #1 substring$
533 duplicate$ "{" =
534 'skip$
535 { output.state mid.sentence =
536 { "l" }
537 { "u" }
538 if$
539 change.case$
540 }
541 if$
542 note #2 global.max$ substring$ * "note" bibinfo.check
543 }
544 if$
545 }
546
547 FUNCTION {format.title}
548 { title
549 duplicate$ empty$ 'skip$
550 { "t" change.case$ }
551 if$
552 "title" bibinfo.check
553 duplicate$ empty$ 'skip$
554 {
555 emphasize
556 }
557 if$
558 }
559 FUNCTION {output.bibitem}
560 { newline$
561 "\bibitem{" write$
562 cite$ write$
563 "}" write$
564 newline$
565 ""
566 before.all 'output.state :=
567 }
568
569 FUNCTION {n.dashify}
570 {
571 't :=
572 ""
573 { t empty$ not }
574 { t #1 #1 substring$ "-" =
575 { t #1 #2 substring$ "--" = not
576 { "--" *
577 t #2 global.max$ substring$ 't :=
578 }
579 { { t #1 #1 substring$ "-" = }
580 { "-" *
581 t #2 global.max$ substring$ 't :=
582 }
583 while$
584 }
585 if$
586 }
587 { t #1 #1 substring$ *
588 t #2 global.max$ substring$ 't :=
589 }
590 if$
591 }
592 while$
593 }
594
595 FUNCTION {word.in}
596 { bbl.in capitalize
597 " " * }
598
599 FUNCTION {format.date}
600 {
601 month "month" bibinfo.check
602 duplicate$ empty$
603 year "year" bibinfo.check duplicate$ empty$
604 { swap$ 'skip$
605 { "there's a month but no year in " cite$ * warning$ }
606 if$
607 *
608 }
609 { swap$ 'skip$
610 {
611 swap$
612 " " * swap$
613 }
614 if$
615 *
616 remove.dots
617 }
618 if$
619 }
620 FUNCTION {format.btitle}
621 { title "title" bibinfo.check
622 duplicate$ empty$ 'skip$
623 {
624 emphasize
625 }
626 if$
627 }
628 FUNCTION {either.or.check}
629 { empty$
630 'pop$
631 { "can't use both " swap$ * " fields in " * cite$ * warning$ }
632 if$
633 }
634 FUNCTION {format.bvolume}
635 { volume empty$
636 { "" }
637 { bbl.volume volume tie.or.space.prefix
638 "volume" bibinfo.check * *
639 series "series" bibinfo.check
640 duplicate$ empty$ 'pop$
641 { swap$ bbl.of space.word * swap$
642 emphasize * }
643 if$
644 "volume and number" number either.or.check
645 }
646 if$
647 }
648 FUNCTION {format.number.series}
649 { volume empty$
650 { number empty$
651 { series field.or.null }
652 { series empty$
653 { number "number" bibinfo.check }
654 { output.state mid.sentence =
655 { bbl.number }
656 { bbl.number capitalize }
657 if$
658 number tie.or.space.prefix "number" bibinfo.check * *
659 bbl.in space.word *
660 series "series" bibinfo.check *
661 }
662 if$
663 }
664 if$
665 }
666 { "" }
667 if$
668 }
669
670 FUNCTION {format.edition}
671 { edition duplicate$ empty$ 'skip$
672 {
673 output.state mid.sentence =
674 { "l" }
675 { "t" }
676 if$ change.case$
677 "edition" bibinfo.check
678 " " * bbl.edition *
679 }
680 if$
681 }
682 INTEGERS { multiresult }
683 FUNCTION {multi.page.check}
684 { 't :=
685 #0 'multiresult :=
686 { multiresult not
687 t empty$ not
688 and
689 }
690 { t #1 #1 substring$
691 duplicate$ "-" =
692 swap$ duplicate$ "," =
693 swap$ "+" =
694 or or
695 { #1 'multiresult := }
696 { t #2 global.max$ substring$ 't := }
697 if$
698 }
699 while$
700 multiresult
701 }
702 FUNCTION {format.pages}
703 { pages duplicate$ empty$ 'skip$
704 { duplicate$ multi.page.check
705 {
706 n.dashify
707 }
708 {
709 }
710 if$
711 "pages" bibinfo.check
712 }
713 if$
714 }
715 FUNCTION {format.journal.pages}
716 { pages duplicate$ empty$ 'pop$
717 { swap$ duplicate$ empty$
718 { pop$ pop$ format.pages }
719 {
720 ":" *
721 swap$
722 n.dashify
723 "pages" bibinfo.check
724 *
725 }
726 if$
727 }
728 if$
729 }
730 FUNCTION {format.journal.eid}
731 { eid "eid" bibinfo.check
732 duplicate$ empty$ 'pop$
733 { swap$ duplicate$ empty$ 'skip$
734 {
735 ":" *
736 }
737 if$
738 swap$ *
739 }
740 if$
741 }
742 FUNCTION {format.vol.num.pages}
743 { volume field.or.null
744 duplicate$ empty$ 'skip$
745 {
746 bbl.volume swap$ tie.or.space.prefix
747 "volume" bibinfo.check
748 * *
749 }
750 if$
751 number "number" bibinfo.check duplicate$ empty$ 'skip$
752 {
753 swap$ duplicate$ empty$
754 { "there's a number but no volume in " cite$ * warning$ }
755 'skip$
756 if$
757 swap$
758 "(" swap$ * ")" *
759 }
760 if$ *
761 eid empty$
762 { format.journal.pages }
763 { format.journal.eid }
764 if$
765 }
766
767 FUNCTION {format.chapter.pages}
768 { chapter empty$
769 'format.pages
770 { type empty$
771 { bbl.chapter }
772 { type "l" change.case$
773 "type" bibinfo.check
774 }
775 if$
776 chapter tie.or.space.prefix
777 "chapter" bibinfo.check
778 * *
779 pages empty$
780 'skip$
781 { ", " * format.pages * }
782 if$
783 }
784 if$
785 }
786
787 FUNCTION {format.booktitle}
788 {
789 booktitle "booktitle" bibinfo.check
790 emphasize
791 }
792 FUNCTION {format.in.ed.booktitle}
793 { format.booktitle duplicate$ empty$ 'skip$
794 {
795 editor "editor" format.names.ed duplicate$ empty$ 'pop$
796 {
797 " " *
798 get.bbl.editor
799 "(" swap$ * "), " *
800 * swap$
801 * }
802 if$
803 word.in swap$ *
804 }
805 if$
806 }
807 FUNCTION {empty.misc.check}
808 { author empty$ title empty$ howpublished empty$
809 month empty$ year empty$ note empty$
810 and and and and and
811 key empty$ not and
812 { "all relevant fields are empty in " cite$ * warning$ }
813 'skip$
814 if$
815 }
816 FUNCTION {format.thesis.type}
817 { type duplicate$ empty$
818 'pop$
819 { swap$ pop$
820 "t" change.case$ "type" bibinfo.check
821 }
822 if$
823 }
824 FUNCTION {format.tr.number}
825 { number "number" bibinfo.check
826 type duplicate$ empty$
827 { pop$ bbl.techrep }
828 'skip$
829 if$
830 "type" bibinfo.check
831 swap$ duplicate$ empty$
832 { pop$ "t" change.case$ }
833 { tie.or.space.prefix * * }
834 if$
835 }
836 FUNCTION {format.article.crossref}
837 {
838 key duplicate$ empty$
839 { pop$
840 journal duplicate$ empty$
841 { "need key or journal for " cite$ * " to crossref " * crossref * warning$ }
842 { "journal" bibinfo.check emphasize word.in swap$ * }
843 if$
844 }
845 { word.in swap$ * " " *}
846 if$
847 " \cite{" * crossref * "}" *
848 }
849 FUNCTION {format.crossref.editor}
850 { editor #1 "{vv~}{ll}" format.name$
851 "editor" bibinfo.check
852 editor num.names$ duplicate$
853 #2 >
854 { pop$
855 "editor" bibinfo.check
856 " " * bbl.etal
857 *
858 }
859 { #2 <
860 'skip$
861 { editor #2 "{ff }{vv }{ll}{ jj}" format.name$ "others" =
862 {
863 "editor" bibinfo.check
864 " " * bbl.etal
865 *
866 }
867 {
868 bbl.and space.word
869 * editor #2 "{vv~}{ll}" format.name$
870 "editor" bibinfo.check
871 *
872 }
873 if$
874 }
875 if$
876 }
877 if$
878 }
879 FUNCTION {format.book.crossref}
880 { volume duplicate$ empty$
881 { "empty volume in " cite$ * "'s crossref of " * crossref * warning$
882 pop$ word.in
883 }
884 { bbl.volume
885 capitalize
886 swap$ tie.or.space.prefix "volume" bibinfo.check * * bbl.of space.word *
887 }
888 if$
889 editor empty$
890 editor field.or.null author field.or.null =
891 or
892 { key empty$
893 { series empty$
894 { "need editor, key, or series for " cite$ * " to crossref " *
895 crossref * warning$
896 "" *
897 }
898 { series emphasize * }
899 if$
900 }
901 { key * }
902 if$
903 }
904 { format.crossref.editor * }
905 if$
906 " \cite{" * crossref * "}" *
907 }
908 FUNCTION {format.incoll.inproc.crossref}
909 {
910 editor empty$
911 editor field.or.null author field.or.null =
912 or
913 { key empty$
914 { format.booktitle duplicate$ empty$
915 { "need editor, key, or booktitle for " cite$ * " to crossref " *
916 crossref * warning$
917 }
918 { word.in swap$ * }
919 if$
920 }
921 { word.in key * " " *}
922 if$
923 }
924 { word.in format.crossref.editor * " " *}
925 if$
926 " \cite{" * crossref * "}" *
927 }
928 FUNCTION {format.org.or.pub}
929 { 't :=
930 ""
931 address empty$ t empty$ and
932 'skip$
933 {
934 t empty$
935 { address "address" bibinfo.check *
936 }
937 { t *
938 address empty$
939 'skip$
940 { ", " * address "address" bibinfo.check * }
941 if$
942 }
943 if$
944 }
945 if$
946 }
947 FUNCTION {format.publisher.address}
948 { publisher "publisher" bibinfo.warn format.org.or.pub
949 }
950
951 FUNCTION {format.organization.address}
952 { organization "organization" bibinfo.check format.org.or.pub
953 }
954
955 FUNCTION {article}
956 { output.bibitem
957 format.authors "author" output.check
958 new.block
959 format.title "title" output.check
960 new.block
961 crossref missing$
962 {
963 journal
964 "journal" bibinfo.check
965 "journal" output.check
966 format.vol.num.pages output
967 format.date "year" output.check
968 }
969 { format.article.crossref output.nonnull
970 format.pages output
971 }
972 if$
973 format.issn output
974 format.doi output
975 new.block
976 format.url output
977 new.block
978 format.note output
979 fin.entry
980 }
981 FUNCTION {book}
982 { output.bibitem
983 author empty$
984 { format.editors "author and editor" output.check
985 }
986 { format.authors output.nonnull
987 crossref missing$
988 { "author and editor" editor either.or.check }
989 'skip$
990 if$
991 }
992 if$
993 new.block
994 format.btitle "title" output.check
995 crossref missing$
996 { format.bvolume output
997 new.block
998 format.number.series output
999 new.sentence
1000 format.publisher.address output
1001 }
1002 {
1003 new.block
1004 format.book.crossref output.nonnull
1005 }
1006 if$
1007 format.edition output
1008 format.date "year" output.check
1009 format.isbn output
1010 format.doi output
1011 new.block
1012 format.url output
1013 new.block
1014 format.note output
1015 fin.entry
1016 }
1017 FUNCTION {booklet}
1018 { output.bibitem
1019 format.authors output
1020 new.block
1021 format.title "title" output.check
1022 new.block
1023 howpublished "howpublished" bibinfo.check output
1024 address "address" bibinfo.check output
1025 format.date output
1026 format.isbn output
1027 format.doi output
1028 new.block
1029 format.url output
1030 new.block
1031 format.note output
1032 fin.entry
1033 }
1034
1035 FUNCTION {inbook}
1036 { output.bibitem
1037 author empty$
1038 { format.editors "author and editor" output.check
1039 }
1040 { format.authors output.nonnull
1041 crossref missing$
1042 { "author and editor" editor either.or.check }
1043 'skip$
1044 if$
1045 }
1046 if$
1047 new.block
1048 format.btitle "title" output.check
1049 crossref missing$
1050 {
1051 format.bvolume output
1052 format.chapter.pages "chapter and pages" output.check
1053 new.block
1054 format.number.series output
1055 new.sentence
1056 format.publisher.address output
1057 }
1058 {
1059 format.chapter.pages "chapter and pages" output.check
1060 new.block
1061 format.book.crossref output.nonnull
1062 }
1063 if$
1064 format.edition output
1065 format.date "year" output.check
1066 crossref missing$
1067 { format.isbn output }
1068 'skip$
1069 if$
1070 format.doi output
1071 new.block
1072 format.url output
1073 new.block
1074 format.note output
1075 fin.entry
1076 }
1077
1078 FUNCTION {incollection}
1079 { output.bibitem
1080 format.authors "author" output.check
1081 new.block
1082 format.title "title" output.check
1083 new.block
1084 crossref missing$
1085 { format.in.ed.booktitle "booktitle" output.check
1086 format.bvolume output
1087 format.number.series output
1088 format.chapter.pages output
1089 new.sentence
1090 format.publisher.address output
1091 format.edition output
1092 format.date "year" output.check
1093 format.isbn output
1094 }
1095 { format.incoll.inproc.crossref output.nonnull
1096 format.chapter.pages output
1097 }
1098 if$
1099 format.doi output
1100 new.block
1101 format.url output
1102 new.block
1103 format.note output
1104 fin.entry
1105 }
1106 FUNCTION {inproceedings}
1107 { output.bibitem
1108 format.authors "author" output.check
1109 new.block
1110 format.title "title" output.check
1111 new.block
1112 crossref missing$
1113 { format.in.ed.booktitle "booktitle" output.check
1114 format.bvolume output
1115 format.number.series output
1116 format.pages output
1117 new.sentence
1118 publisher empty$
1119 { format.organization.address output }
1120 { organization "organization" bibinfo.check output
1121 format.publisher.address output
1122 }
1123 if$
1124 format.date "year" output.check
1125 format.isbn output
1126 format.issn output
1127 }
1128 { format.incoll.inproc.crossref output.nonnull
1129 format.pages output
1130 }
1131 if$
1132 format.doi output
1133 new.block
1134 format.url output
1135 new.block
1136 format.note output
1137 fin.entry
1138 }
1139 FUNCTION {conference} { inproceedings }
1140 FUNCTION {manual}
1141 { output.bibitem
1142 author empty$
1143 { organization "organization" bibinfo.check
1144 duplicate$ empty$ 'pop$
1145 { output
1146 address "address" bibinfo.check output
1147 }
1148 if$
1149 }
1150 { format.authors output.nonnull }
1151 if$
1152 new.block
1153 format.btitle "title" output.check
1154 author empty$
1155 { organization empty$
1156 {
1157 address new.block.checka
1158 address "address" bibinfo.check output
1159 }
1160 'skip$
1161 if$
1162 }
1163 {
1164 organization address new.block.checkb
1165 organization "organization" bibinfo.check output
1166 address "address" bibinfo.check output
1167 }
1168 if$
1169 format.edition output
1170 format.date output
1171 format.doi output
1172 new.block
1173 format.url output
1174 new.block
1175 format.note output
1176 fin.entry
1177 }
1178
1179 FUNCTION {mastersthesis}
1180 { output.bibitem
1181 format.authors "author" output.check
1182 new.block
1183 format.btitle
1184 "title" output.check
1185 new.block
1186 bbl.mthesis format.thesis.type output.nonnull
1187 school "school" bibinfo.warn output
1188 address "address" bibinfo.check output
1189 format.date "year" output.check
1190 format.doi output
1191 new.block
1192 format.url output
1193 new.block
1194 format.note output
1195 fin.entry
1196 }
1197
1198 FUNCTION {misc}
1199 { output.bibitem
1200 format.authors output
1201 title howpublished new.block.checkb
1202 format.title output
1203 howpublished new.block.checka
1204 howpublished "howpublished" bibinfo.check output
1205 format.date output
1206 format.doi output
1207 new.block
1208 format.url output
1209 new.block
1210 format.note output
1211 fin.entry
1212 empty.misc.check
1213 }
1214 FUNCTION {phdthesis}
1215 { output.bibitem
1216 format.authors "author" output.check
1217 new.block
1218 format.btitle
1219 "title" output.check
1220 new.block
1221 bbl.phdthesis format.thesis.type output.nonnull
1222 school "school" bibinfo.warn output
1223 address "address" bibinfo.check output
1224 format.date "year" output.check
1225 format.doi output
1226 new.block
1227 format.url output
1228 new.block
1229 format.note output
1230 fin.entry
1231 }
1232
1233 FUNCTION {proceedings}
1234 { output.bibitem
1235 editor empty$
1236 { organization "organization" bibinfo.check output
1237 }
1238 { format.editors output.nonnull }
1239 if$
1240 new.block
1241 format.btitle "title" output.check
1242 format.bvolume output
1243 format.number.series output
1244 editor empty$
1245 { publisher empty$
1246 'skip$
1247 {
1248 new.sentence
1249 format.publisher.address output
1250 }
1251 if$
1252 }
1253 { publisher empty$
1254 {
1255 new.sentence
1256 format.organization.address output }
1257 {
1258 new.sentence
1259 organization "organization" bibinfo.check output
1260 format.publisher.address output
1261 }
1262 if$
1263 }
1264 if$
1265 format.date "year" output.check
1266 format.isbn output
1267 format.issn output
1268 format.doi output
1269 new.block
1270 format.url output
1271 new.block
1272 format.note output
1273 fin.entry
1274 }
1275
1276 FUNCTION {techreport}
1277 { output.bibitem
1278 format.authors "author" output.check
1279 new.block
1280 format.title
1281 "title" output.check
1282 new.block
1283 format.tr.number output.nonnull
1284 institution "institution" bibinfo.warn output
1285 address "address" bibinfo.check output
1286 format.date "year" output.check
1287 format.doi output
1288 new.block
1289 format.url output
1290 new.block
1291 format.note output
1292 fin.entry
1293 }
1294
1295 FUNCTION {unpublished}
1296 { output.bibitem
1297 format.authors "author" output.check
1298 new.block
1299 format.title "title" output.check
1300 format.date output
1301 format.doi output
1302 new.block
1303 format.url output
1304 new.block
1305 format.note "note" output.check
1306 fin.entry
1307 }
1308
1309 FUNCTION {default.type} { misc }
1310 READ
1311 FUNCTION {sortify}
1312 { purify$
1313 "l" change.case$
1314 }
1315 INTEGERS { len }
1316 FUNCTION {chop.word}
1317 { 's :=
1318 'len :=
1319 s #1 len substring$ =
1320 { s len #1 + global.max$ substring$ }
1321 's
1322 if$
1323 }
1324 FUNCTION {sort.format.names}
1325 { 's :=
1326 #1 'nameptr :=
1327 ""
1328 s num.names$ 'numnames :=
1329 numnames 'namesleft :=
1330 { namesleft #0 > }
1331 { s nameptr
1332 "{vv{ } }{ll{ }}{ ff{ }}{ jj{ }}"
1333 format.name$ 't :=
1334 nameptr #1 >
1335 {
1336 " " *
1337 namesleft #1 = t "others" = and
1338 { "zzzzz" 't := }
1339 'skip$
1340 if$
1341 t sortify *
1342 }
1343 { t sortify * }
1344 if$
1345 nameptr #1 + 'nameptr :=
1346 namesleft #1 - 'namesleft :=
1347 }
1348 while$
1349 }
1350
1351 FUNCTION {sort.format.title}
1352 { 't :=
1353 "A " #2
1354 "An " #3
1355 "The " #4 t chop.word
1356 chop.word
1357 chop.word
1358 sortify
1359 #1 global.max$ substring$
1360 }
1361 FUNCTION {author.sort}
1362 { author empty$
1363 { key empty$
1364 { "to sort, need author or key in " cite$ * warning$
1365 ""
1366 }
1367 { key sortify }
1368 if$
1369 }
1370 { author sort.format.names }
1371 if$
1372 }
1373 FUNCTION {author.editor.sort}
1374 { author empty$
1375 { editor empty$
1376 { key empty$
1377 { "to sort, need author, editor, or key in " cite$ * warning$
1378 ""
1379 }
1380 { key sortify }
1381 if$
1382 }
1383 { editor sort.format.names }
1384 if$
1385 }
1386 { author sort.format.names }
1387 if$
1388 }
1389 FUNCTION {author.organization.sort}
1390 { author empty$
1391 { organization empty$
1392 { key empty$
1393 { "to sort, need author, organization, or key in " cite$ * warning$
1394 ""
1395 }
1396 { key sortify }
1397 if$
1398 }
1399 { "The " #4 organization chop.word sortify }
1400 if$
1401 }
1402 { author sort.format.names }
1403 if$
1404 }
1405 FUNCTION {editor.organization.sort}
1406 { editor empty$
1407 { organization empty$
1408 { key empty$
1409 { "to sort, need editor, organization, or key in " cite$ * warning$
1410 ""
1411 }
1412 { key sortify }
1413 if$
1414 }
1415 { "The " #4 organization chop.word sortify }
1416 if$
1417 }
1418 { editor sort.format.names }
1419 if$
1420 }
1421 FUNCTION {presort}
1422 { type$ "book" =
1423 type$ "inbook" =
1424 or
1425 'author.editor.sort
1426 { type$ "proceedings" =
1427 'editor.organization.sort
1428 { type$ "manual" =
1429 'author.organization.sort
1430 'author.sort
1431 if$
1432 }
1433 if$
1434 }
1435 if$
1436 " "
1437 *
1438 year field.or.null sortify
1439 *
1440 " "
1441 *
1442 title field.or.null
1443 sort.format.title
1444 *
1445 #1 entry.max$ substring$
1446 'sort.key$ :=
1447 }
1448 ITERATE {presort}
1449 SORT
1450 STRINGS { longest.label }
1451 INTEGERS { number.label longest.label.width }
1452 FUNCTION {initialize.longest.label}
1453 { "" 'longest.label :=
1454 #1 'number.label :=
1455 #0 'longest.label.width :=
1456 }
1457 FUNCTION {longest.label.pass}
1458 { number.label int.to.str$ 'label :=
1459 number.label #1 + 'number.label :=
1460 label width$ longest.label.width >
1461 { label 'longest.label :=
1462 label width$ 'longest.label.width :=
1463 }
1464 'skip$
1465 if$
1466 }
1467 EXECUTE {initialize.longest.label}
1468 ITERATE {longest.label.pass}
1469 FUNCTION {begin.bib}
1470 { preamble$ empty$
1471 'skip$
1472 { preamble$ write$ newline$ }
1473 if$
1474 "\begin{thebibliography}{" longest.label * "}" *
1475 write$ newline$
1476 "\providecommand{\url}[1]{\texttt{#1}}"
1477 write$ newline$
1478 "\providecommand{\urlprefix}{URL }"
1479 write$ newline$
1480 "\expandafter\ifx\csname urlstyle\endcsname\relax"
1481 write$ newline$
1482 " \providecommand{\doi}[1]{doi:\discretionary{}{}{}#1}\else"
1483 write$ newline$
1484 " \providecommand{\doi}{doi:\discretionary{}{}{}\begingroup \urlstyle{rm}\Url}\fi"
1485 write$ newline$
1486 }
1487 EXECUTE {begin.bib}
1488 EXECUTE {init.doi.variables}
1489 EXECUTE {init.state.consts}
1490 ITERATE {call.type$}
1491 FUNCTION {end.bib}
1492 { newline$
1493 "\end{thebibliography}" write$ newline$
1494 }
1495 EXECUTE {end.bib}
1496 %% End of customized bst file
1497 %%
1498 %% End of file `mjo.bst'.