├── README.md
├── cas-common.sty
├── cas-dc-template.tex
├── cas-dc-templates.pdf
├── cas-dc.cls
├── cas-model2-names.bst
├── cas-refs.bib
├── image.jpeg
└── thumbnails
├── cas-email.jpeg
├── cas-facebook.jpeg
├── cas-gplus.jpeg
├── cas-linkedin.jpeg
├── cas-twitter.jpeg
└── cas-url.jpeg
/README.md:
--------------------------------------------------------------------------------
1 |
2 | ## els-cas-templates.zip
3 | Elsevier template 'els-cas-templates'(爱思唯尔期刊-latex双栏版本)
4 |
5 | ### 1)说明:
6 | - 此压缩包仅包含爱思唯尔期刊Latex复杂版式的双栏版本。
7 | - 此压缩包基于Elsevier官网Latex模板(els-cas-templates.zip),删除了一些不需要的文件,并对 cas-dc-template.tex 文件进行了一些修改。
8 |
9 |
10 | ### 2)包含文件:
11 | - cas-dc.cls:类文件
12 | - cas-dc-template.tex:双栏 tex 模板,对应 cas-dc.cls 类文件
13 | - cas-dc-templates.pdf:编译好的pdf文件
14 | - cas-refs.bib:参考文献bib格式
15 | - cas-model2-names.bst:参考文献的排版格式
16 | - cas-common.sty:用于格式化的附加宏包
17 |
18 | ### 3)使用:
19 | - 下载后,将 els-cas-templates.zip 压缩包导入Overleaf,即可正常编译。
20 |
21 | ### 4)效果:
22 |
23 |
24 |
--------------------------------------------------------------------------------
/cas-common.sty:
--------------------------------------------------------------------------------
1 | %%
2 | %% This is file `cas-common.sty',
3 | %%
4 | %% This file is part of the 'CAS Bundle'.
5 | %% ......................................
6 | %%
7 | %% It may be distributed under the conditions of the LaTeX Project Public
8 | %% License, either version 1.3c of this license or (at your option) any
9 | %% later version. The latest version of this license is in
10 | %% http://www.latex-project.org/lppl.txt
11 | %% and version 1.3c or later is part of all distributions of LaTeX
12 | %% version 1999/12/01 or later.
13 | %%
14 | %% The list of all files belonging to the 'CAS Bundle' is
15 | %% given in the file `manifest.txt'.
16 | %%
17 |
18 | % $Id: cas-common.sty 66 2021-05-11 14:17:42Z rishi $
19 |
20 | \def\RCSfile{cas-common}%
21 | \def\RCSversion{2.3}%
22 | \def\RCSdate{2021/05/11}%
23 | \NeedsTeXFormat{LaTeX2e}[1995/12/01]
24 |
25 | \pretolerance=-1
26 | \tolerance=1000
27 | \hyphenpenalty=1000
28 | \exhyphenpenalty=100
29 | \brokenpenalty=10000
30 | \vfuzz=\z@
31 | \hfuzz=.2pt
32 | \doublehyphendemerits=100
33 | \emergencystretch=2pt
34 | \frenchspacing
35 | \clubpenalty=10000
36 | \widowpenalty=10000
37 |
38 | \ExplSyntaxOn
39 | \makeatletter
40 | %
41 | % Front matter macros
42 | %
43 | % The front matter macros are derived/adopted from stm-prelims.sty
44 | % written by CV Radhakrishnan and copyrighted by him.
45 | % Usage of those macros and methods are gratefully acknowledged.
46 | %
47 |
48 | \tl_set:Nn \l_stm_title_color_tl { black }
49 |
50 | \keys_define:nn { stm / title }
51 | {
52 | mode .choice: ,
53 | mode / title .meta:n =
54 | {
55 | type = title ,
56 | size = \LARGE ,
57 | shape = \upshape ,
58 | weight = \mdseries ,
59 | color = black ,
60 | before = 0pt ,
61 | after = 0pt ,
62 | align = \raggedright ,
63 | } ,
64 | mode / alt .meta:n =
65 | {
66 | type = alt ,
67 | size = \large ,
68 | shape = \upshape ,
69 | weight = \mdseries ,
70 | color = black ,
71 | before = 6pt ,
72 | after = 0pt ,
73 | align = \raggedright ,
74 | } ,
75 | mode / sub .meta:n =
76 | {
77 | type = sub ,
78 | size = \large ,
79 | shape = \upshape ,
80 | weight = \mdseries ,
81 | color = black!80 ,
82 | before = 6pt ,
83 | after = 0pt ,
84 | align = \raggedright ,
85 | } ,
86 | mode / trans .meta:n =
87 | {
88 | type = trans ,
89 | size = \normalsize ,
90 | shape = \upshape ,
91 | weight = \mdseries ,
92 | color = black!60 ,
93 | before = 6pt ,
94 | after = 0pt ,
95 | align = \raggedright ,
96 | } ,
97 | mode / transsub .meta:n =
98 | {
99 | type = transsub ,
100 | size = \small ,
101 | shape = \upshape ,
102 | weight = \mdseries ,
103 | color = black!50 ,
104 | before = 6pt ,
105 | after = 0pt ,
106 | align = \raggedright ,
107 | } ,
108 | mode / ascii .meta:n =
109 | {
110 | type = ascii ,
111 | size = \small\ttfamily ,
112 | shape = \upshape ,
113 | weight = \mdseries ,
114 | color = black ,
115 | before = 12pt ,
116 | after = 0pt ,
117 | align = \raggedright ,
118 | } ,
119 | type .tl_set:N = \l_stm_title_type_tl ,
120 | size .tl_set:N = \l_stm_title_size_tl ,
121 | shape .tl_set:N = \l_stm_title_shape_tl ,
122 | weight .tl_set:N = \l_stm_title_weight_tl ,
123 | before .dim_set:N = \l_stm_title_before_dim ,
124 | after .dim_set:N = \l_stm_title_after_dim ,
125 | align .tl_set:N = \l_stm_title_align_tl ,
126 | color .tl_set:N = \l_stm_title_color_tl ,
127 | }
128 |
129 | \NewDocumentCommand \processTmarks { }
130 | {
131 | \cs_if_free:cTF { mark@title }
132 | { \ignorespaces }
133 | { \tl_set:Nx \l_tmpa_tl { \cs:w mark@title\cs_end: }
134 | \clist_map_inline:cn { mark@title }
135 | {
136 | \str_case:nn { ##1 }
137 | {
138 | { 1 } { $^\star$ }
139 | { 2 } { $^{,\star\star}$ }
140 | { 3 } { $^{,\star\star\star}$ }
141 | }
142 | }
143 | }
144 | }
145 |
146 | \RenewDocumentCommand \title { O{} m }
147 | {
148 | \pdfstringdef \@pdftitle { #2 }
149 | \csgdef { casprelimstitle } { #2 }
150 | \keys_set:nn { stm / title } { #1 }
151 | \seq_gput_right:Nn \g_stm_title_seq
152 | {
153 | \keys_set:nn { stm / title } { #1 }
154 | % \msg_term:n { MODE:~\l_stm_title_mode_tl ~ ~ [#2]}
155 | \par \vskip \l_stm_title_before_dim
156 | \l_stm_title_align_tl
157 | \l_stm_title_size_tl
158 | \l_stm_title_shape_tl
159 | \l_stm_title_weight_tl
160 | \color { \l_stm_title_color_tl }
161 | \noindent \unskip \ignorespaces #2
162 | \tl_set:Nn \l_tmpa_tl { title }
163 | \tl_if_eq:NNTF \l_stm_title_type_tl \l_tmpa_tl
164 | { \processTmarks } { }
165 | \par \vskip \l_stm_title_after_dim
166 | \normalcolor \normalsize \normalfont
167 | }
168 | }
169 |
170 | % \gappto\usestmtitle{#1}%
171 |
172 | \renewcommand \@title { \seq_use:Nn \g_stm_title_seq { } }
173 |
174 | \NewDocumentCommand \wrAun { m } % unexpanded write to aux
175 | { \iow_now:Nn \@auxout { #1 } }
176 | \NewDocumentCommand \wrAux { m } % expanded write to aux
177 | { \iow_now:Nx \@auxout { #1 } }
178 |
179 | \NewDocumentCommand \wrShipAux { m } % expanded write at shipout
180 | { \iow_shipout:Nx \@auxout { #1 } }
181 | \NewDocumentCommand \wrShipAun { m } % unexpanded write at shipout
182 | { \iow_shipout:Nn \@auxout { #1 } }
183 |
184 | \NewDocumentCommand \stmLabel { m }
185 | {
186 | \@bsphack \wrAux
187 | { \token_to_str:N \NewLabel { #1 }
188 | { \@currentlabel }
189 | } \@esphack
190 | }
191 | \NewDocumentCommand \NewLabel { m m }
192 | {
193 | \cs_if_free:cTF { X@#1: }
194 | { \cs_new:cx { X@#1: } { #2 } }
195 | { \cs_set:cx { X@#1: } { #2 } }
196 | }
197 | \NewDocumentCommand \stmRef { m }
198 | {
199 | \cs_if_free:cTF { X@#1: }
200 | { 0 } {\use:c {X@#1:} }
201 | }
202 |
203 | \seq_clear_new:N \l_fnmk_seq
204 | \NewDocumentCommand \processFnRef { m }
205 | {
206 | \seq_clear:N \l_fnmk_seq
207 | \clist_map_inline:nn { #1 }
208 | { \seq_put_right:Nx \l_fnmk_seq
209 | {\cs_if_free:cTF { X@##1: } {0} { \use:c {X@##1:} }}
210 | }
211 | }
212 |
213 | \NewDocumentCommand \fnmark { O{} }
214 | { \writemarks { fnau\theau@ } { #1 } }
215 |
216 |
217 | \NewDocumentCommand \fnref { m }
218 | {
219 | \processFnRef { #1 }
220 | \wrAux { \token_to_str:N \csxdef {mark@fnau\theau@}
221 | { \seq_use:Nn \l_fnmk_seq { , } } }
222 | }
223 |
224 | \NewDocumentCommand \corref { m }
225 | {
226 | \str_set:Nx \l_tmpa_str { \stmRef { #1 } }
227 | \wrAux { \token_to_str:N \csxdef { mark@corau\theau@ }
228 | {
229 | \cs_if_free:cTF { X@#1: } {0} { \use:c {X@#1:} }
230 | }
231 | }
232 | }
233 |
234 | \NewDocumentCommand \cormark { O{} }
235 | {
236 | \@cormarktrue
237 | \writemarks {corau\theau@} { #1 }
238 | }
239 |
240 | \seq_new:N \l_stm_au_seq
241 | \seq_new:N \l_stm_au_sn_seq
242 | \seq_new:N \l_stm_au_fn_seq
243 | \seq_new:N \l_stm_au_ead_seq
244 | \seq_new:N \l_stm_au_orcid_seq
245 | \seq_new:N \l_stm_au_contrib_role_seq
246 |
247 | \NewDocumentCommand \parsename { m }
248 | { \seq_set_split:Nnn \l_stm_au_seq { ~ } {#1}
249 | \seq_pop_right:NN \l_stm_au_seq \l_stm_au_sn_seq
250 | \seq_map_inline:Nn \l_stm_au_seq
251 | { \seq_put_right:Nx \l_stm_au_ead_seq
252 | { \tl_head:n { #1 }. } }
253 | }
254 |
255 | \NewDocumentCommand \invparsename { m }
256 | { \seq_set_split:Nnn \l_stm_au_seq { ~ } {#1}
257 | \seq_pop_left:NN \l_stm_au_seq \l_stm_au_sn_seq
258 | \seq_map_inline:Nn \l_stm_au_seq
259 | { \seq_put_right:Nx \l_stm_au_ead_seq
260 | { \tl_head:n { #1 }. } }
261 | }
262 |
263 |
264 | \NewDocumentCommand \surname {} { \l_stm_au_sn_seq }
265 | \NewDocumentCommand \firstname {}
266 | { \seq_use:Nn \l_stm_au_seq { ~ } }
267 | \NewDocumentCommand \eadauthor {}
268 | { \seq_map_inline:Nn \l_stm_au_seq
269 | { \regex_match:nnTF { \. } { ##1 }
270 | { ##1 }
271 | { \tl_head:n {##1}. }
272 | }
273 | {~} \l_stm_au_sn_seq
274 | }
275 | \cs_set_eq:NN \shortauthor \eadauthor
276 |
277 | \seq_clear_new:N \l_affmk_seq
278 | \NewDocumentCommand \processAffRef { m }
279 | {
280 | \seq_clear:N \l_affmk_seq
281 | \clist_map_inline:nn { #1 }
282 | {
283 | \seq_put_right:Nx \l_affmk_seq
284 | {\stmRef{##1}}
285 | }
286 | }
287 |
288 | \NewDocumentCommand \processAffNum { m }
289 | {
290 | \seq_clear:N \l_affmk_seq
291 | \clist_map_inline:nn { #1 }
292 | {
293 | \seq_put_right:Nn \l_affmk_seq
294 | { \int_to_alph:n {##1} }
295 | }
296 | }
297 |
298 | \NewDocumentCommand \listAff { }
299 | {
300 | \tl_if_blank:nTF { \l_affmk_seq }
301 | { \tl_gset:Nn \g_stm_comma_tl { 0 } }
302 | {
303 | \seq_use:Nn \l_affmk_seq { , }
304 | \tex_def:D \sep{\unskip,}
305 | }
306 | }
307 |
308 | \NewDocumentCommand \ead { O{} m }
309 | {
310 | \tl_if_empty:nTF { #1 } { \@ead {#2} } { \@uad[#1]{#2} }
311 | }
312 |
313 | \NewDocumentCommand \eadsep { } { }
314 |
315 | \int_new:N \g_ead_int
316 | \seq_new:N \g_stm_ead_seq
317 | \int_new:N \g_uad_int
318 | \seq_new:N \g_stm_uad_seq
319 | \seq_new:N \g_stm_orcid_seq
320 | \seq_new:N \g_stm_contrib_role_seq
321 |
322 | \newcommand\theead { \int_use:N \g_ead_int }
323 |
324 | \NewDocumentCommand \@uad { O{} m }
325 | {
326 | \group_begin:
327 | \wrAux { \token_to_str:N \urlauthor
328 | { \exp_not:n {#2}}{\the\@eadauthor}}%
329 | \group_end:
330 | }
331 |
332 | \NewDocumentCommand \urlauthor { m m }
333 | {
334 | \int_gincr:N \g_uad_int
335 | \seq_gput_right:Nn \g_stm_uad_seq
336 | {
337 | { %\ttfamily \tl_to_str:n
338 | \url{ #1 } }
339 | \parsename { #2 }
340 | \space(\eadauthor)
341 | }
342 | }
343 | \NewDocumentCommand \@stmuads { }
344 | { \seq_use:Nn \g_stm_uad_seq { ;~ } }
345 |
346 | \NewDocumentCommand \@ead { m }
347 | {
348 | \group_begin:
349 | \wrAux { \token_to_str:N \emailauthor
350 | { \exp_not:n { #1 }}{ \the\@eadauthor }}
351 | \group_end:
352 | }
353 |
354 | \newtoks \@eadauthor
355 | \newbool{@cormark}
356 |
357 | \NewDocumentCommand \emailauthor { m m }
358 | {
359 | \int_gincr:N \g_ead_int
360 | \seq_gput_right:Nn \g_stm_ead_seq
361 | {
362 | { \ttfamily \tl_to_str:n { #1 } }
363 | \parsename { #2 }
364 | \space(\eadauthor)%
365 | }
366 | }
367 |
368 | \NewDocumentCommand \@elseads { }
369 | { \seq_use:Nn \g_stm_ead_seq { ;~ } }
370 |
371 |
372 | \NewDocumentCommand \printemails { }
373 | {
374 | \group_begin:
375 | \int_compare:nNnTF { \int_use:N \g_ead_int } > { 0 }
376 | {
377 | \tex_let:D \thefootnote \relax \footnotetext
378 | {
379 | \raggedright
380 | \bool_if:NTF \g_stm_nologo_bool
381 | {
382 | \int_compare:nTF { \g_ead_int = 1 }
383 | { \textit{Email~address:\c_space_token} }
384 | { \textit{Email~addresses:\c_space_token} }
385 | }
386 | { \includegraphics[height=8pt]{thumbnails/cas-email.jpeg}\c_space_token }
387 | \seq_use:Nn \g_stm_ead_seq { ;~ }
388 | }
389 | }
390 | { }
391 | \group_end:
392 | }
393 |
394 | \NewDocumentCommand \printurls { }
395 | {
396 | \group_begin:
397 | \int_compare:nTF { \g_uad_int > 0 }
398 | {
399 | \tex_let:D \thefootnote \relax \footnotetext
400 | {
401 | \raggedright
402 | \bool_if:NTF \g_stm_nologo_bool
403 | { \textit{URL:\c_space_token} }
404 | { \includegraphics[height=8pt]{thumbnails/cas-url.jpeg}\c_space_token }
405 | \seq_use:Nn \g_stm_uad_seq { ;~ }
406 | }
407 | }
408 | { }
409 | \group_end:
410 | }
411 |
412 | %
413 | % orcid
414 | %
415 | \NewDocumentCommand \orcidauthor { m m }
416 | {
417 | \seq_gput_right:Nn \g_stm_orcid_seq
418 | {
419 | { \ttfamily \tl_to_str:n { #1 } }
420 | \parsename{#2}
421 | \space(\eadauthor)
422 | }
423 | }
424 |
425 | \NewDocumentCommand \printorcid { }
426 | {
427 | \group_begin:
428 | \tex_let:D \thefootnote \relax \footnotetext
429 | {
430 | \raggedright
431 | \textsc{orcid}(s):\c_space_token
432 | \seq_use:Nn \g_stm_orcid_seq { ;~ }
433 | }
434 | \group_end:
435 | }
436 |
437 | %
438 | % Contrib Role
439 | %
440 |
441 | \seq_gclear_new:N \g_stm_credits_seq
442 |
443 | \NewDocumentCommand \ContribRole { m }
444 | {
445 | \wrAux { \token_to_str:N \creditauthor
446 | { #1 } { \the\@eadauthor } }
447 | }
448 |
449 | \NewDocumentCommand \creditauthor { m m }
450 | {
451 | \seq_gput_right:Nx \g_stm_credits_seq
452 | { { \exp_not:N\bfseries #2 :}\space #1 }
453 | }
454 |
455 | \cs_set_eq:NN \credit \ContribRole
456 |
457 | \NewDocumentCommand \printcredits { }
458 | {
459 | \seq_if_empty:NF \g_stm_credits_seq
460 | {
461 | \section*{CRediT ~authorship ~contribution ~statement}
462 | \ifnum\theblind>0\relax
463 | \vspace*{10mm}
464 | \else
465 | \seq_use:Nn \g_stm_credits_seq { .~ }.
466 | \fi
467 | }
468 | }
469 |
470 | \NewDocumentCommand \writemarks { m m }
471 | { \wrAux { \token_to_str:N \csgdef{mark@#1}{#2} } }
472 |
473 | \seq_new:N \g_stm_title_seq
474 |
475 | \NewDocumentCommand \tnotemark { O{} }
476 | { \writemarks { title } { #1 } }
477 |
478 | \NewDocumentCommand \@tnoteref { m }
479 | { \int_set:Nn \l_tmpa_int { 0 }
480 | \clist_map_inline:nn { #1 }
481 | {
482 | % \iow_term:n { ##1 .. [\cs:w X@##1:\cs_end:] }
483 | \cs_if_free:cTF { X@##1: }
484 | { \csdef{X@##1:}{0} }
485 | {
486 | \tl_set:Nx \l_tmpa_tl { \cs:w X@##1:\cs_end: }
487 | \int_case:nn { \l_tmpa_tl }
488 | {
489 | { 1 } { $^\star$ }
490 | { 2 } { $^{,\star\star}$ }
491 | { 3 } { $^{,\star\star\star}$ }
492 | }
493 | }
494 | }
495 | }
496 |
497 | \seq_new:N \g_stm_tnote_seq
498 | \int_new:N \g_stm_tnote_int
499 |
500 | \NewDocumentCommand \tnotetext { O{} m }
501 | {
502 | \tl_if_head_eq_catcode:nNTF { #1 } a
503 | {
504 | % \iow_term:n { [TNOTE:~alpha] }%
505 | \seq_gput_right:Nn \g_stm_tnote_seq
506 | { \int_incr:N \g_stm_tnote_int
507 | \str_set:Nx \@currentlabel { \int_use:N \g_stm_tnote_int }
508 | \stmLabel { #1 }
509 | \renewcommand\thefootnote
510 | { \int_case:nn { \g_stm_tnote_int }
511 | {
512 | { 1 } { $^\star$ }
513 | { 2 } { $^{\star\star}$ }
514 | { 3 } { $^{\star\star\star}$ }
515 | }
516 | }
517 | \footnotetext { #2 }
518 | }
519 | }
520 | {
521 | % \iow_term:n { [TNOTE:~Number] }
522 | \seq_gput_right:Nn \g_stm_tnote_seq
523 | {
524 | \int_set:Nn \l_tmpa_int { #1 }
525 | \renewcommand\thefootnote
526 | { \int_case:nn { \l_tmpa_int }
527 | {
528 | { 1 } { $^\star$ }
529 | { 2 } { $^{\star\star}$ }
530 | { 3 } { $^{\star\star\star}$ }
531 | }
532 | }
533 | \footnotetext { #2 }
534 | }
535 | }
536 | }
537 |
538 | \newcommand \printtnotes { \seq_use:Nn \g_stm_tnote_seq { \par } }
539 |
540 | \seq_new:N \g_stm_nonumnote_seq
541 |
542 | \NewDocumentCommand \nonumnote { m }
543 | {
544 | \group_begin:
545 | \seq_gput_right:Nn \g_stm_nonumnote_seq
546 | {
547 | \tex_def:D \thefootnote { }
548 | \footnotetext{#1}
549 | }
550 | \group_end:
551 | }
552 |
553 | \newcommand \printnonumnotes { \seq_use:Nn \g_stm_nonumnote_seq { \par } }
554 |
555 | \seq_new:N \g_stm_fnote_seq
556 | \int_new:N \g_stm_fnote_int
557 |
558 | \NewDocumentCommand \fntext { O{} m }
559 | {
560 | \tl_if_head_eq_catcode:nNTF { #1 } a
561 | {
562 | % \iow_term:n { [FN:~alpha] }%
563 | \seq_gput_right:Nn \g_stm_fnote_seq
564 | { \int_incr:N \g_stm_fnote_int
565 | \str_set:Nx \@currentlabel { \int_use:N \g_stm_fnote_int }
566 | \stmLabel { #1 }
567 | \tex_def:D \thefootnote { \int_use:N \g_stm_fnote_int }
568 | \footnotetext { #2 }
569 | }
570 | }
571 | {
572 | % \iow_term:n { [FN:~Number] }
573 | \seq_gput_right:Nn \g_stm_fnote_seq
574 | {
575 | \int_set:Nn \l_tmpa_int { #1 }
576 | \tex_def:D \thefootnote { \int_use:N \l_tmpa_int }
577 | \footnotetext { #2 }
578 | }
579 | }
580 | }
581 |
582 | \newcommand \printfnotes { \seq_use:Nn \g_stm_fnote_seq { \par } }
583 |
584 | \seq_new:N \g_stm_cor_seq
585 | \int_new:N \g_stm_cor_int
586 |
587 | \NewDocumentCommand \cortext { O{} m }
588 | {
589 | \tl_if_head_eq_catcode:nNTF { #1 } a
590 | {
591 | % \iow_term:n { [COR:~alpha] }%
592 | \seq_gput_right:Nn \g_stm_cor_seq
593 | { \int_incr:N \g_stm_cor_int
594 | \str_set:Nx \@currentlabel { \int_use:N \g_stm_cor_int }
595 | \stmLabel { #1 }
596 | \tex_def:D \thefootnote
597 | { \int_case:nn { \g_stm_cor_int }
598 | {
599 | { 1 } { $\ast$ }
600 | { 2 } { $\ast\!\ast$ }
601 | { 3 } { $\ast\!\ast\!\ast$ }
602 | }
603 | }
604 | \footnotetext { #2 }
605 | }
606 | }
607 | {
608 | % \iow_term:n { [COR:~Number] }
609 | \seq_gput_right:Nn \g_stm_cor_seq
610 | {
611 | \int_set:Nn \l_tmpa_int { #1 }
612 | \tex_def:D \thefootnote
613 | { \int_case:nn { \l_tmpa_int }
614 | {
615 | { 1 } { $\ast$ }
616 | { 2 } { $\ast\!\ast$ }
617 | { 3 } { $\ast\!\ast\!\ast$ }
618 | }
619 | }
620 | \footnotetext { #2 }
621 | }
622 | }
623 | }
624 |
625 | \newcommand \printcornotes { \seq_use:Nn \g_stm_cor_seq { \par } }
626 |
627 | \NewDocumentCommand \process@marks { }
628 | {
629 | \cs_if_free:cTF { mark@corau\theauthor }
630 | { \ignorespaces }
631 | { \str_set:Nx \l_tmpa_str { \use:c{ mark@corau\theauthor } }
632 | \int_case:nn { \l_tmpa_str }
633 | {
634 | { 1 } { \sep$\ast$ }
635 | { 2 } { \sep$\ast\ast$ }
636 | { 3 } { \sep$\ast\!\ast\!\ast$ }
637 | }
638 | \tex_def:D \sep{\unskip,}
639 | }
640 | \cs_if_free:cTF { mark@fnau\theauthor }
641 | { \ignorespaces }
642 | { \sep\use:c { mark@fnau\theauthor }
643 | \tex_def:D \sep{\unskip,}
644 | }
645 | }
646 |
647 |
648 | %
649 | % Author macros
650 | %
651 | \seq_new:c { g_stm_au0_seq }
652 | \seq_new:c { g_stm_clau0_seq }
653 | \int_new:N \g_stm_au_int
654 | \int_new:N \g_stm_aau_int
655 |
656 | \NewDocumentCommand \ResetMarks { }
657 | {
658 | \keys_set:nn { stm / author }
659 | {
660 | auid = {} ,
661 | bioid = {} ,
662 | alt = {} ,
663 | style = { normal } ,
664 | prefix = {} ,
665 | suffix = {} ,
666 | degree = {} ,
667 | role = {} ,
668 | orcid = {} ,
669 | collab = { false } ,
670 | type = { author } ,
671 | anon = { false } ,
672 | deceased = { false } ,
673 | twitter = {} ,
674 | facebook = {} ,
675 | linkedin = {} ,
676 | plus = {} ,
677 | gplus = {} ,
678 | }
679 | \tex_gdef:D \sep{}
680 | \tex_gdef:D \stm@corref{}
681 | \tex_gdef:D \@fnmark {}
682 | }
683 |
684 |
685 | \int_new:N \l_autype_int
686 | \keys_define:nn { stm / author }
687 | {
688 | auid .tl_set:N = \l_stm_au_id_tl ,
689 | bioid .tl_set:N = \l_stm_au_bioid_tl ,
690 | alt .tl_set:N = \l_stm_au_alt_tl ,
691 | style .tl_set:N = \l_stm_au_style_tl ,
692 | prefix .tl_set:N = \l_stm_au_prefix_tl ,
693 | suffix .tl_set:N = \l_stm_au_suffix_tl ,
694 | degree .tl_set:N = \l_stm_au_degree_tl ,
695 | role .tl_set:N = \l_stm_au_role_tl ,
696 | orcid .tl_set:N = \l_stm_au_orcid_tl ,
697 | collab .bool_set:N = \l_stm_au_collab_bool ,
698 | type .multichoice:,
699 | type/author .code:n = { \int_set:Nn \l_autype_int { 0 } },
700 | type/editor .code:n = { \int_set:Nn \l_autype_int { 1 } },
701 | type/collab .code:n = { \int_set:Nn \l_autype_int { 2 } },
702 | type/anon .code:n = { \int_set:Nn \l_autype_int { 3 } },
703 | % type/collab .bool_set:N = \l_stm_au_collab_bool ,
704 | % type/anon .bool_set:N = \l_stm_au_anon_bool ,
705 | anon .bool_set:N = \l_stm_au_anon_bool ,
706 | deceased .bool_set:N = \l_stm_au_deceased_bool ,
707 | twitter .tl_set:N = \l_stm_au_twitter_tl ,
708 | facebook .tl_set:N = \l_stm_au_facebook_tl ,
709 | linkedin .tl_set:N = \l_stm_au_linkedin_tl ,
710 | plus .tl_set:N = \l_stm_au_gplus_tl ,
711 | gplus .tl_set:N = \l_stm_au_gplus_tl ,
712 | }
713 |
714 | \keys_set:nn { stm / author }
715 | {
716 | auid = {} ,
717 | bioid = {} ,
718 | alt = {} ,
719 | style = { normal } ,
720 | prefix = {} ,
721 | suffix = {} ,
722 | degree = {} ,
723 | role = {} ,
724 | orcid = {} ,
725 | collab = { false } ,
726 | type = { author } ,
727 | anon = { false } ,
728 | deceased = { false } ,
729 | twitter = {} ,
730 | facebook = {} ,
731 | linkedin = {} ,
732 | plus = {} ,
733 | gplus = {} ,
734 | }
735 |
736 | \keys_define:nn { stm / ausetup }
737 | {
738 | type .choice: ,
739 | type / authors .meta:n =
740 | {
741 | size = \large ,
742 | shape = \upshape ,
743 | weight = \mdseries ,
744 | before = \bigskipamount ,
745 | after = 0pt ,
746 | align = \raggedright ,
747 | color = black ,
748 | lskip = 0pt ,
749 | rskip = 0pt ,
750 | } ,
751 | type / collaboration .meta:n =
752 | {
753 | size = \Large ,
754 | shape = \upshape ,
755 | weight = \mdseries ,
756 | before = \bigskipamount ,
757 | after = 0pt ,
758 | align = \raggedright ,
759 | color = black ,
760 | lskip = 0pt ,
761 | rskip = 0pt ,
762 | } ,
763 | size .tl_set:N = \l_stm_augroup_size_tl ,
764 | shape .tl_set:N = \l_stm_augroup_shape_tl ,
765 | weight .tl_set:N = \l_stm_augroup_weight_tl ,
766 | before .dim_set:N = \l_stm_augroup_before_dim ,
767 | after .dim_set:N = \l_stm_augroup_after_dim ,
768 | align .tl_set:N = \l_stm_augroup_align_tl ,
769 | color .tl_set:N = \l_stm_augroup_color_tl ,
770 | lskip .dim_set:N = \l_stm_augroup_lskip_tl ,
771 | rskip .dim_set:N = \l_stm_augroup_rskip_tl ,
772 | }
773 |
774 | \DeclareDocumentCommand \stmAuthorSetup { m }
775 | { \keys_set:nn { stm / ausetup } { #1 } }
776 | \DeclareDocumentCommand \stmausetup { m }
777 | { \tl_set:Nn \l_stm_au_setup_tl
778 | { \keys_set:nn { stm / ausetup } { #1 } }
779 | }
780 | \DeclareDocumentCommand \stmclbsetup { m }
781 | { \tl_set:Nn \l_stm_clb_setup_tl
782 | { \keys_set:nn { stm / ausetup } { #1 } }
783 | }
784 |
785 | \stmausetup { }
786 | \stmclbsetup { }
787 |
788 | \seq_new:N \g_stm_maltese_seq
789 | \seq_new:N \g_stm_facebook_seq
790 | \seq_new:N \g_stm_twitter_seq
791 | \seq_new:N \g_stm_gplus_seq
792 | \seq_new:N \g_stm_linkedin_seq
793 | \bool_new:N \g_stm_nologo_bool
794 | \bool_gset_false:N \g_stm_nologo_bool
795 |
796 | \NewDocumentCommand \twitterauthor { m m }
797 | {
798 | \seq_gput_right:Nn \g_stm_twitter_seq
799 | {
800 | \parsename { #2 }
801 | \url{https://twitter.com/\tl_to_str:n{#1}}\space(\eadauthor)
802 | }
803 | }
804 | \NewDocumentCommand \facebookauthor { m m }
805 | {
806 | \seq_gput_right:Nn \g_stm_facebook_seq
807 | {
808 | \parsename { #2 }
809 | \url{https://www.facebook.com/\tl_to_str:n{#1}}\space(\eadauthor) %
810 | }
811 | }
812 | \NewDocumentCommand \gplusauthor { m m }
813 | {
814 | \seq_gput_right:Nn \g_stm_gplus_seq
815 | {
816 | \parsename { #2 }
817 | \url{https://plus.google.com/\tl_to_str:n{#1}}\space(\eadauthor)%
818 | }
819 | }
820 | \NewDocumentCommand \linkedinauthor { m m }
821 | {
822 | \seq_gput_right:Nn \g_stm_linkedin_seq
823 | {
824 | \parsename { #2 }
825 | \url{https://www.linkedin.com/profile/view?id=\tl_to_str:n{#1}}%
826 | \space(\eadauthor)
827 | }
828 | }
829 |
830 | \NewDocumentCommand \printmaltese { }
831 | {
832 | \seq_use:Nn { \g_stm_maltese_seq } { }
833 | }
834 | \NewDocumentCommand \printfacebook { }
835 | {
836 | \seq_if_empty:NTF \g_stm_facebook_seq { }
837 | {
838 | \tex_def:D \thefootnote{}
839 | \footnotetext
840 | {
841 | \bool_if:NTF \g_stm_nologo_bool
842 | { Facebook:\c_space_token }
843 | { \includegraphics[height=8pt]{thumbnails/cas-facebook.jpeg}\c_space_token }
844 | \seq_use:Nn \g_stm_facebook_seq {,\c_space_token }
845 | }
846 | }
847 | }
848 | \NewDocumentCommand \printtwitter { }
849 | {
850 | \seq_if_empty:NTF \g_stm_twitter_seq { }
851 | {
852 | \tex_def:D \thefootnote{}
853 | \footnotetext
854 | {
855 | \bool_if:NTF \g_stm_nologo_bool
856 | { Twitter:\c_space_token }
857 | { \includegraphics[height=8pt]{thumbnails/cas-twitter.jpeg}\c_space_token }
858 | \seq_use:Nn \g_stm_twitter_seq {,\c_space_token }
859 | }
860 | }
861 | }
862 | \NewDocumentCommand \printgplus { }
863 | {
864 | \seq_if_empty:NTF \g_stm_gplus_seq { }
865 | {
866 | \tex_def:D \thefootnote{}
867 | \footnotetext
868 | {
869 | \bool_if:NTF \g_stm_nologo_bool
870 | { Google+:\c_space_token }
871 | { \includegraphics[height=8pt]{thumbnails/cas-gplus.jpeg}\c_space_token }
872 | \seq_use:Nn \g_stm_gplus_seq {,\c_space_token }
873 | }
874 | }
875 | }
876 | \NewDocumentCommand \printlinkedin { }
877 | {
878 | \seq_if_empty:NTF \g_stm_linkedin_seq { }
879 | {
880 | \tex_def:D \thefootnote{}
881 | \footnotetext
882 | {
883 | \bool_if:NTF \g_stm_nologo_bool
884 | { LinkedIn:\c_space_token }
885 | { \includegraphics[height=8pt]{thumbnails/cas-linkedin.jpeg}\c_space_token }
886 | \seq_use:Nn \g_stm_linkedin_seq {,\c_space_token }
887 | }
888 | }
889 | }
890 |
891 | \seq_new:N \g_stm_prelimsau_seq
892 |
893 | \csxdef{infoauthors}{}
894 | \cs_new:Nn \no_break_space: { \nobreak{~} \penalty 10000 }
895 | \RenewDocumentCommand \author { O{} m O{} }
896 | {
897 | \ResetMarks
898 | \tl_if_blank:nTF { #3 } { }
899 | { \keys_set:nn { stm / author } { #3 } }
900 | %
901 | \int_gincr:N \g_stm_au_int
902 | \tex_gdef:D \theau@ { \int_use:N \g_stm_au_int }
903 | %
904 | \seq_gput_right:Nn \g_stm_prelimsau_seq { #2 }
905 | \bool_if:NTF \l_stm_au_collab_bool
906 | { \seq_gput_right:cn { g_stm_clau\int_use:N \g_stm_augr_int _seq } }
907 | { \seq_gput_right:cn { g_stm_au\int_use:N \g_stm_augr_int _seq } }
908 | {
909 | \int_gincr:N \g_stm_aau_int
910 | \tex_gdef:D \theauthor {\int_use:N \g_stm_aau_int }
911 | \keys_set:nn { stm /author } { #3 }
912 | \tl_if_head_eq_catcode:nNTF { #1 } a
913 | { \processAffRef { #1 } }
914 | { \processAffNum { #1 } }
915 | \tl_if_empty:NF \l_stm_au_prefix
916 | { \l_stm_au_prefix_tl \c_space_token }
917 | \str_if_eq:VnTF \l_stm_au_style_tl { chinese }
918 | { %\iow_term:n {STYLE~T=\l_stm_au_style_tl........}
919 | \invparsename { #2 }
920 | \textcolor{\l_stm_augroup_color_tl}{\surname}
921 | \no_break_space:
922 | \textcolor{\l_stm_augroup_color_tl !50}{\firstname}
923 | }
924 | { %\iow_term:n {STYLE~F=\l_stm_au_style_tl........}
925 | \parsename { #2 }
926 | \textcolor{\l_stm_augroup_color_tl !50}{\firstname}
927 | \no_break_space:
928 | \textcolor{\l_stm_augroup_color_tl}{\surname}
929 | }
930 | \tl_if_empty:NF \l_stm_au_suffix_tl
931 | { \c_space_token \l_stm_au_suffix_tl }
932 | \unskip
933 | \textsuperscript
934 | {
935 | \tl_if_blank:nTF { #1 }
936 | { \tex_def:D \sep{} }
937 | { {\itshape\listAff} \tex_def:D \sep{\unskip,} }
938 | \process@marks
939 | \bool_if:NT \l_stm_au_deceased_bool
940 | { \sep \maltese
941 | \tex_def:D \sep { \unksip, }
942 | }
943 | }
944 | \tl_if_empty:NF \l_stm_au_degree_tl
945 | { ,\c_space_token \l_stm_au_degree_tl }
946 | \tl_if_empty:NF \l_stm_au_role_tl
947 | { \c_space_token (\l_stm_au_role_tl) }
948 | %
949 | \ResetMarks
950 | }
951 | %
952 | \bool_if:NT \l_stm_au_deceased_bool
953 | {
954 | \seq_gput_right:Nn \g_stm_maltese_seq
955 | {
956 | \tex_def:D \thefootnote { \maltese }
957 | \footnotetext{Deceased~author.}
958 | }
959 | }
960 | % various social media
961 | \tl_if_empty:NTF \l_stm_au_facebook_tl { }
962 | {
963 | \wrAux { \token_to_str:N \facebookauthor
964 | { \l_stm_au_facebook_tl } { \exp_not:n {#2} } }
965 | }
966 | \tl_if_empty:NF \l_stm_au_twitter_tl
967 | {
968 | \wrAux { \token_to_str:N \twitterauthor
969 | { \l_stm_au_twitter_tl } { \exp_not:n {#2} } }
970 | }
971 | \tl_if_empty:NF \l_stm_au_gplus_tl
972 | {
973 | \wrAux { \token_to_str:N \gplusauthor
974 | { \l_stm_au_gplus_tl } { \exp_not:n {#2} } }
975 | }
976 | \tl_if_empty:NF \l_stm_au_linkedin_tl
977 | {
978 | \wrAux { \token_to_str:N \linkedinauthor
979 | { \l_stm_au_linkedin_tl } { \exp_not:n {#2} } }
980 | }
981 | \tl_if_empty:NF \l_stm_au_orcid_tl
982 | {
983 | \wrAux { \token_to_str:N \orcidauthor
984 | { \l_stm_au_orcid_tl } { \exp_not:n {#2} } }
985 | }
986 | %
987 | \@eadauthor={#2}
988 | \pdfstringdef\__info_au: { #2 }
989 | \int_compare:nNnTF { \theau@ } < { 4 }
990 | { \xappto \infoauthors { \__info_au: , ~ } }
991 | {
992 | \int_compare:nNnTF { \theau@ } = { 4 }
993 | { \xappto \infoauthors { et~al. } }
994 | { }
995 | }
996 | }
997 |
998 | \NewDocumentCommand \stmauthors { }
999 | {
1000 | \group_begin:
1001 | \stmAuthorSetup { type = authors }
1002 | \l_stm_au_setup_tl
1003 | \par \vskip\l_stm_augroup_before_dim
1004 | \l_stm_augroup_align_tl
1005 | \l_stm_augroup_size_tl
1006 | \l_stm_augroup_shape_tl
1007 | \l_stm_augroup_weight_tl
1008 | \color{ \l_stm_augroup_color_tl }
1009 | \bool_if:NTF \g_stm_augr_bool
1010 | { \seq_use:Nn \g_stm_augr_seq { \par } }
1011 | {
1012 | \seq_use:cnnn { g_stm_au\int_use:N\g_stm_augr_int _seq }
1013 | { ,~ } { ,~ } { ~and~ }
1014 | }
1015 | \par\vskip\l_stm_augroup_after_dim
1016 | \group_end:
1017 | }
1018 |
1019 | \seq_new:c { g_stm_collab0_seq }
1020 | \bool_new:N \g_stm_in_clau_bool
1021 |
1022 | \NewDocumentCommand \stmcollab { }
1023 | {
1024 | \bool_if:NTF \g_stm_augr_bool
1025 | { }
1026 | {
1027 | \group_begin:
1028 | \stmAuthorSetup { type = collaboration }
1029 | \l_stm_clb_setup_tl
1030 | \par \vskip \l_stm_augroup_before_dim
1031 | \l_stm_augroup_align_tl
1032 | \l_stm_augroup_size_tl
1033 | \l_stm_augroup_shape_tl
1034 | \l_stm_augroup_weight_tl
1035 | \color{ \l_stm_augroup_color_tl }
1036 | \seq_use:cn {g_stm_collab\int_use:N \g_stm_aaugr_int _seq} { }
1037 | \seq_use:cnnn {g_stm_clau\int_use:N \g_stm_aaugr_int _seq}
1038 | { ~and~ } { ,~ } { ~and~ }
1039 | \par \vskip \l_stm_augroup_after_dim
1040 | \group_end:
1041 | }
1042 | }
1043 |
1044 | \newenvironment{collaboration}[1][]
1045 | {
1046 | \seq_gput_right:cn {g_stm_collab\int_use:N \g_stm_augr_int _seq}
1047 | { \textit{Collaboration:~} #1 \par \smallskip }
1048 | }
1049 | { }
1050 |
1051 | \NewDocumentCommand \dept { m } { #1 }
1052 | \NewDocumentCommand \divn { m } { #1 }
1053 | \NewDocumentCommand \aline { m } { #1 }
1054 | \NewDocumentCommand \city { m } { #1 }
1055 | \NewDocumentCommand \cnty { m } { #1 }
1056 | \NewDocumentCommand \phone { m } { #1 }
1057 | \NewDocumentCommand \fax { m } { #1 }
1058 | \NewDocumentCommand \aurl { m } { #1 }
1059 |
1060 | \def\ca_affitem_postskip{\mbox{~}\unskip\ignorespaces}
1061 | %%Author Address
1062 | \DeclareDocumentCommand \ca_organization { O{,} m }
1063 | {
1064 | % #2 #1\mbox{~}\unskip\ignorespaces
1065 | \csgappto { ca_affiliation_values } { #2 #1\ca_affitem_postskip }
1066 | }
1067 | \DeclareDocumentCommand \ca_postal_code { O{,} m }
1068 | {
1069 | % #2 #1\mbox{~}\unskip\ignorespaces
1070 | \csgappto { ca_affiliation_values } { #2 #1\ca_affitem_postskip }
1071 | }
1072 | \DeclareDocumentCommand \ca_aff_city { O{,} m }
1073 | {
1074 | % #2 #1\mbox{~}\unskip\ignorespaces
1075 | \csgappto { ca_affiliation_values } { #2 #1\ca_affitem_postskip }
1076 | }
1077 | \DeclareDocumentCommand \ca_address_line { O{,}m }
1078 | {
1079 | % #2 #1\mbox{~}\unskip\ignorespaces
1080 | \csgappto { ca_affiliation_values } { #2 #1\ca_affitem_postskip }
1081 | }
1082 | \DeclareDocumentCommand \ca_state { O{,} m }
1083 | {
1084 | % #2 #1\mbox{~}\unskip\ignorespaces
1085 | \csgappto { ca_affiliation_values } { #2 #1\ca_affitem_postskip }
1086 | }
1087 | \DeclareDocumentCommand \ca_country { O{ } m }
1088 | {
1089 | % #2 #1
1090 | \csgappto { ca_affiliation_values } { #2 #1 }
1091 | }
1092 |
1093 | \DeclareDocumentCommand \ca_stm_organization { O{,} m }
1094 | {
1095 | #2 #1\ca_affitem_postskip
1096 | }
1097 | \DeclareDocumentCommand \ca_stm_postal_code { O{,} m }
1098 | {
1099 | #2 #1\ca_affitem_postskip
1100 | }
1101 | \DeclareDocumentCommand \ca_stm_aff_city { O{,} m }
1102 | {
1103 | #2 #1\ca_affitem_postskip
1104 | }
1105 | \DeclareDocumentCommand \ca_stm_aff_address_line { O{,}m }
1106 | {
1107 | #2 #1\ca_affitem_postskip
1108 | }
1109 | \DeclareDocumentCommand \ca_stm_state { O{,} m }
1110 | {
1111 | #2 #1\ca_affitem_postskip
1112 | }
1113 | \DeclareDocumentCommand \ca_stm_country { O{ } m }
1114 | {
1115 | #2 #1
1116 | }
1117 |
1118 | \keys_define:nn { stm / affiliation }
1119 | {
1120 | op .tl_set_x:N = \l_organization_punc_tl,
1121 | oraganizationsep .tl_set_x:N = \l_organization_punc_tl,
1122 | ap .tl_set_x:N = \l_address_line_punc_tl,
1123 | addresslinesep .tl_set_x:N = \l_address_line_punc_tl,
1124 | cp .tl_set_x:N = \l_city_punc_tl,
1125 | citysep .tl_set_x:N = \l_city_punc_tl,
1126 | pp .tl_set_x:N = \l_postal_code_punc_tl,
1127 | postcodesep .tl_set_x:N = \l_postal_code_punc_tl,
1128 | sp .tl_set_x:N = \l_state_punc_tl,
1129 | statesep .tl_set_x:N = \l_state_punc_tl,
1130 | o .code:n = { \ca_organization[\l_organization_punc_tl]{#1} },
1131 | organization .code:n = { \ca_organization[\l_organization_punc_tl]{#1} },
1132 | a .code:n = { \ca_address_line[\l_address_line_punc_tl]{#1} },
1133 | addressline .code:n = { \ca_address_line[\l_address_line_punc_tl]{#1} },
1134 | c .code:n = { \ca_aff_city[\l_city_punc_tl]{#1} },
1135 | city .code:n = { \ca_aff_city[\l_city_punc_tl]{#1} },
1136 | p .code:n = { \ca_postal_code[\l_postal_code_punc_tl]{#1} },
1137 | postcode .code:n = { \ca_postal_code[\l_postal_code_punc_tl]{#1} },
1138 | s .code:n = { \ca_state[\l_state_punc_tl]{#1} },
1139 | state .code:n = { \ca_state[\l_state_punc_tl]{#1} },
1140 | orp .tl_set_x:N = \l_organization_punc_tl,
1141 | adp .tl_set_x:N = \l_address_line_punc_tl,
1142 | cip .tl_set_x:N = \l_city_punc_tl,
1143 | pcp .tl_set_x:N = \l_postal_code_punc_tl,
1144 | stp .tl_set_x:N = \l_state_punc_tl,
1145 | cyp .tl_set_x:N = \l_country_punc_tl,
1146 | or .code:n = { \ca_organization[\l_organization_punc_tl]{#1} },
1147 | ad .code:n = { \ca_address_line[\l_address_line_punc_tl]{#1} },
1148 | ci .code:n = { \ca_aff_city[\l_city_punc_tl]{#1} },
1149 | pc .code:n = { \ca_postal_code[\l_postal_code_punc_tl]{#1} },
1150 | st .code:n = { \ca_state[\l_state_punc_tl]{#1} },
1151 | cy .code:n = { \ca_country[\l_country_punc_tl]{#1} },
1152 | country .code:n = { \ca_country[\l_country_punc_tl]{#1} },
1153 | unknown .code:n = {
1154 | \ifstrempty { #1 } {
1155 | \csxappto { ca_affiliation_values }
1156 | { {\l_keys_key_tl}~ }
1157 | } {
1158 | \csxappto { ca_affiliation_values }
1159 | { {#1}~ }
1160 | }
1161 | }
1162 | }
1163 |
1164 | \cs_set:Npn \__reset_affiliation:
1165 | {
1166 | \tl_gset:Nn \l_organization_punc_tl { , }
1167 | \tl_gset:Nn \l_address_line_punc_tl { , }
1168 | \tl_gset:Nn \l_city_punc_tl { , }
1169 | \tl_gset:Nn \l_postal_code_punc_tl { , }
1170 | \tl_gset:Nn \l_state_punc_tl { , }
1171 | \tl_gset:Nn \l_country_punc_tl { }
1172 | }
1173 |
1174 | \seq_new:c { g_stm_aff0_seq }
1175 | \int_new:N \g_stm_aff_int
1176 | \tl_new:N \l_addrtype_tl
1177 |
1178 | \keys_define:nn { stm / address }
1179 | {
1180 | foot .bool_gset:N = \g_stm_addr_foot_bool ,
1181 | name .tl_set:N = \l_stm_addr_name_tl ,
1182 | type .multichoice: ,
1183 | type/alt .code:n = { \tl_set:Nn \l_stm_addr_type_tl
1184 | { Alternate~address } } ,
1185 | type/addl .code:n = { \tl_set:Nn \l_stm_addr_type_tl
1186 | { Additional~address } } ,
1187 | type/regular .code:n = { \tl_set:Nn \l_stm_addr_type_tl
1188 | { } } ,
1189 | type/custom .code:n = { \tl_set:Nn \l_stm_addr_type_tl
1190 | { \l_stm_addr_name_tl } } ,
1191 | }
1192 | \DeclareDocumentCommand \stmAddrSetup { m }
1193 | { \keys_set:nn { stm / address } { #1 } }
1194 |
1195 | \keys_set:nn { stm / address }
1196 | {
1197 | foot = { false } ,
1198 | type = { regular } ,
1199 | name = { Alternate~address } ,
1200 | }
1201 |
1202 | \cs_new:Nn \__reset_addr:
1203 | {
1204 | \bool_gset_false:N \g_stm_addr_foot_bool
1205 | \tl_set:Nn \l_stm_addr_type_tl { }
1206 | \tl_set:Nn \l_stm_addr_name_tl { Alternate~address }
1207 | }
1208 |
1209 | \seq_new:N \g_stm_aff_foot_seq
1210 |
1211 | \NewDocumentCommand \printaddrinfoot { }
1212 | {
1213 | { \seq_use:Nn \g_stm_aff_foot_seq { \par } }
1214 | }
1215 |
1216 | \NewDocumentCommand \address { O{} m O{} }
1217 | {
1218 | \__reset_addr:
1219 | \keys_set:nn { stm / address } { #3 }
1220 | \bool_if:NTF \g_stm_addr_foot_bool
1221 | { \__foot_address:nnn [#1]{#2}[#3] }
1222 | {
1223 | \seq_gput_right:cn { g_stm_aff\int_use:N \g_stm_augr_int _seq }
1224 | { \tl_if_blank:nTF { #1 }
1225 | {
1226 | \tex_xdef:D \thefootnote{}
1227 | { #2 }
1228 | }
1229 | {
1230 | \tl_if_head_eq_catcode:nNTF { #1 } a
1231 | {
1232 | \int_gincr:N \g_stm_aff_int
1233 | \tex_xdef:D \@currentlabel
1234 | { \int_to_alph:n { \int_use:N \g_stm_aff_int } }
1235 | \stmLabel {#1}
1236 | \textsuperscript{\itshape\@currentlabel} #2
1237 | }
1238 | {
1239 | \int_gset:Nn \g_stm_aff_int { #1 }
1240 | \tex_xdef:D \@currentlabel
1241 | { \int_to_alph:n { \int_use:N \g_stm_aff_int } }
1242 | \textsuperscript{\itshape\@currentlabel} #2
1243 | }
1244 | }
1245 | }
1246 | }
1247 | }
1248 |
1249 | \int_new:N \g_stm_aff_ext_int
1250 | \int_new:N \g_stm_aff_int_int
1251 |
1252 | \NewDocumentCommand \affiliation { O{} m O{} }
1253 | {
1254 | \__reset_affiliation:
1255 | \csgdef { ca_affiliation_values } { }
1256 | \IfNoValueTF { #2 }
1257 | { }
1258 | {
1259 | \keys_set:nn { stm / affiliation } { #2 }
1260 | }
1261 | \int_gincr:N \g_stm_aff_ext_int
1262 | \csxdef{ca_affiliation_\int_use:N \g_stm_aff_ext_int}{\csuse { ca_affiliation_values }}
1263 | \__reset_addr:
1264 | \keys_set:nn { stm / address } { #3 }
1265 | \bool_if:NTF \g_stm_addr_foot_bool
1266 | { \__foot_affiliation:nnn [#1]{#2}[#3] }
1267 | {
1268 | \seq_gput_right:cn { g_stm_aff\int_use:N \g_stm_augr_int _seq }
1269 | { \int_gincr:N \g_stm_aff_int_int
1270 | \tl_if_blank:nTF { #1 }
1271 | {
1272 | \tex_xdef:D \thefootnote{}
1273 | { \csuse { ca_affiliation_\int_use:N \g_stm_aff_int_int } }
1274 | }
1275 | {
1276 | \tl_if_head_eq_catcode:nNTF { #1 } a
1277 | {
1278 | \int_gincr:N \g_stm_aff_int
1279 | \tex_xdef:D \@currentlabel
1280 | { \int_to_alph:n { \int_use:N \g_stm_aff_int } }
1281 | \stmLabel {#1}
1282 | \textsuperscript{\itshape\@currentlabel} { \csuse { ca_affiliation_\int_use:N \g_stm_aff_int_int } }
1283 | }
1284 | {
1285 | \int_gset:Nn \g_stm_aff_int { #1 }
1286 | \tex_xdef:D \@currentlabel
1287 | { \int_to_alph:n { \int_use:N \g_stm_aff_int } }
1288 | \textsuperscript{\itshape\@currentlabel} { \csuse { ca_affiliation_\int_use:N \g_stm_aff_int_int } }
1289 | }
1290 | }
1291 | }
1292 | }
1293 | }
1294 |
1295 | \cs_new:Npn \__foot_address:nnn [#1]#2[#3]
1296 | {
1297 | \keys_set:nn { stm / address } { #3 }
1298 | \seq_gput_right:cn { g_stm_aff_foot_seq }
1299 | {
1300 | \tl_if_empty:nTF { #1 }
1301 | {
1302 | \tl_if_empty:NTF \l_stm_addr_type_tl
1303 | { \footnotetext{#2} }
1304 | {
1305 | \footnotetext{\textit{\l_stm_addr_type_tl}:
1306 | \c_space_token #2 }
1307 | }
1308 | }
1309 | {
1310 | \tl_if_head_eq_catcode:nNTF { #1 } a
1311 | %
1312 | {
1313 | \tex_def:D \thefootnote{\itshape\@currentlabel}
1314 | \tl_if_empty:NTF \l_stm_addr_type_tl
1315 | { \footnotetext{#2} }
1316 | { \footnotetext{\textit{\l_stm_addr_type_tl}: \c_space_token #2} }
1317 | }
1318 | {
1319 | \tex_def:D \thefootnote { \itshape\int_to_alph:n { #1 } }
1320 | \tl_if_empty:NTF \l_stm_addr_type_tl
1321 | { \footnotetext{#2} }
1322 | { \footnotetext{\textit{\l_stm_addr_type_tl}:
1323 | \c_space_token #2 } }
1324 | }
1325 | }
1326 | }
1327 | }
1328 |
1329 | \int_new:N \g_stm_fn_aff_ext_int
1330 | \int_new:N \g_stm_fn_aff_int_int
1331 | \cs_new:Npn \__foot_affiliation:nnn [#1]#2[#3]
1332 | {
1333 | \__reset_affiliation:
1334 | \csgdef { ca_affiliation_values } { }
1335 | \IfNoValueTF { #2 }
1336 | { }
1337 | {
1338 | \keys_set:nn { stm / affiliation } { #2 }
1339 | }
1340 | \int_gincr:N \g_stm_aff_ext_int
1341 | \csxdef{ca_affiliation_\int_use:N \g_stm_fn_aff_ext_int}{\csuse { ca_affiliation_values }}
1342 | \keys_set:nn { stm / address } { #3 }
1343 | \seq_gput_right:cn { g_stm_aff_foot_seq }
1344 | {
1345 | \int_gincr:N \g_stm_aff_int_int
1346 | \tl_if_empty:nTF { #1 }
1347 | {
1348 | \tl_if_empty:NTF \l_stm_addr_type_tl
1349 | { \footnotetext{\csuse { ca_affiliation_\int_use:N \g_stm_fn_aff_int_int }} }
1350 | {
1351 | \footnotetext{\textit{\l_stm_addr_type_tl}:
1352 | \c_space_token \csuse { ca_affiliation_\int_use:N \g_stm_fn_aff_int_int } }
1353 | }
1354 | }
1355 | {
1356 | \tl_if_head_eq_catcode:nNTF { #1 } a
1357 | %
1358 | {
1359 | \tex_def:D \thefootnote{\itshape\@currentlabel}
1360 | \tl_if_empty:NTF \l_stm_addr_type_tl
1361 | { \footnotetext{\csuse { ca_affiliation_\int_use:N \g_stm_fn_aff_int_int }} }
1362 | { \footnotetext{\textit{\l_stm_addr_type_tl}: \c_space_token
1363 | \csuse { ca_affiliation_\int_use:N \g_stm_fn_aff_int_int }} }
1364 | }
1365 | {
1366 | \tex_def:D \thefootnote { \itshape\int_to_alph:n { #1 } }
1367 | \tl_if_empty:NTF \l_stm_addr_type_tl
1368 | { \footnotetext{\csuse { ca_affiliation_\int_use:N \g_stm_fn_aff_int_int }} }
1369 | { \footnotetext{\textit{\l_stm_addr_type_tl}:
1370 | \c_space_token \csuse { ca_affiliation_\int_use:N \g_stm_fn_aff_int_int } } }
1371 | }
1372 | }
1373 | }
1374 | }
1375 |
1376 |
1377 | \keys_define:nn { stm / affsetup }
1378 | {
1379 | type .choice: ,
1380 | type / normal .code:n =
1381 | { \tl_set:Nn \l_stm_aff_type_tl { 0 } } ,
1382 | type / nonum .code:n =
1383 | { \tl_set:Nn \l_stm_aff_type_tl { 1 } } ,
1384 |
1385 | size .tl_set:N = \l_stm_aff_size_tl ,
1386 | shape .tl_set:N = \l_stm_aff_shape_tl ,
1387 | weight .tl_set:N = \l_stm_aff_weight_tl ,
1388 | before .dim_set:N = \l_stm_aff_before_dim ,
1389 | after .dim_set:N = \l_stm_aff_after_dim ,
1390 | align .tl_set:N = \l_stm_aff_align_tl ,
1391 | color .tl_set:N = \l_stm_aff_color_tl ,
1392 | lskip .dim_set:N = \l_stm_aff_lskip_dim ,
1393 | rskip .dim_set:N = \l_stm_aff_rskip_dim ,
1394 | }
1395 |
1396 | \DeclareDocumentCommand \stmAffSetup { m }
1397 | { \keys_set:nn { stm / affsetup } { #1 } }
1398 | \DeclareDocumentCommand \stmaffsetup { m }
1399 | { \tl_set:Nn \l_stm_aff_setup_tl
1400 | { \keys_set:nn { stm / affsetup } { #1 } }
1401 | }
1402 | \stmaffsetup {
1403 | size = \footnotesize,
1404 | shape = \itshape,
1405 | color = black,
1406 | before = 0pt,
1407 | weight = \mdseries,
1408 | align = \raggedright,
1409 | }
1410 |
1411 | \NewDocumentCommand \stmaddress { }
1412 | {
1413 | \bool_if:NTF \g_stm_augr_bool
1414 | { }
1415 | {
1416 | \group_begin:
1417 | \stmAffSetup { type = normal }
1418 | \l_stm_aff_setup_tl
1419 | \par \vskip\l_stm_aff_before_dim
1420 | \l_stm_aff_align_tl
1421 | \l_stm_aff_size_tl
1422 | \l_stm_aff_shape_tl
1423 | \l_stm_aff_weight_tl
1424 | \color{ \l_stm_aff_color_tl }
1425 | \seq_use:cn { g_stm_aff\int_use:N \g_stm_aaugr_int _seq }
1426 | { \par\vskip2pt }
1427 | \par\vskip\l_stm_aff_after_dim
1428 | \group_end:
1429 | }
1430 | }
1431 |
1432 | \int_new:N \g_stm_augr_int
1433 | \seq_new:N \g_stm_augr_seq
1434 | \int_new:N \g_stm_aaugr_int
1435 | \bool_new:N \g_stm_augr_bool
1436 |
1437 | \NewDocumentEnvironment { augroup } { }
1438 | {
1439 | \bool_gset_true:N \g_stm_augr_bool
1440 | \int_gincr:N \g_stm_augr_int
1441 | \seq_new:c {g_stm_au\int_use:N \g_stm_augr_int _seq}
1442 | \seq_new:c {g_stm_aff\int_use:N \g_stm_augr_int _seq}
1443 | \seq_new:c {g_stm_collab\int_use:N \g_stm_augr_int _seq}
1444 | \seq_new:c {g_stm_clau\int_use:N \g_stm_augr_int _seq}
1445 | % \iow_term:n { AUGR:~\int_use:N \g_stm_augr_int ... }
1446 | }
1447 | {
1448 | \seq_gput_right:Nn \g_stm_augr_seq
1449 | {
1450 | \int_gincr:N \g_stm_aaugr_int
1451 | \group_begin:
1452 | \stmAuthorSetup { type = collaboration }
1453 | \l_stm_clb_setup_tl
1454 | \par \vskip \l_stm_augroup_before_dim
1455 | \l_stm_augroup_align_tl
1456 | \l_stm_augroup_size_tl
1457 | \l_stm_augroup_shape_tl
1458 | \l_stm_augroup_weight_tl
1459 | \color{ \l_stm_augroup_color_tl }
1460 | \seq_use:cnnn { g_stm_au\int_use:N \g_stm_aaugr_int _seq }
1461 | { ~and~ } { ,~ } { ~and~ }
1462 | \par \vskip \l_stm_augroup_after_dim
1463 | \group_end:
1464 | %
1465 | \group_begin:
1466 | \stmAffSetup { type = normal }
1467 | \l_stm_aff_setup_tl
1468 | \par \vskip\l_stm_aff_before_dim
1469 | \l_stm_aff_align_tl
1470 | \l_stm_aff_size_tl
1471 | \l_stm_aff_shape_tl
1472 | \l_stm_aff_weight_tl
1473 | \color{ \l_stm_aff_color_tl }
1474 | \seq_use:cn { g_stm_aff\int_use:N \g_stm_aaugr_int _seq }
1475 | { \par \smallskip }
1476 | \par\vskip\l_stm_aff_after_dim
1477 | % \iow_term:n { AAUGR:~\int_use:N \g_stm_aaugr_int ... }
1478 | \group_end:
1479 | %
1480 | \group_begin:
1481 | \stmAuthorSetup { type = collaboration }
1482 | \l_stm_clb_setup_tl
1483 | \par \vskip \l_stm_augroup_before_dim
1484 | \l_stm_augroup_align_tl
1485 | \l_stm_augroup_size_tl
1486 | \l_stm_augroup_shape_tl
1487 | \l_stm_augroup_weight_tl
1488 | \color{ \l_stm_augroup_color_tl }
1489 | \seq_use:cn {g_stm_collab\int_use:N \g_stm_aaugr_int _seq} { }
1490 | \seq_use:cnnn {g_stm_clau\int_use:N \g_stm_aaugr_int _seq}
1491 | { ~and~ } { ,~ } { ~and~ }
1492 | \par\vskip \l_stm_augroup_after_dim
1493 | \group_end:
1494 | }
1495 | }
1496 |
1497 | %
1498 | % Abstract
1499 | %
1500 | \RequirePackage{moreverb}
1501 |
1502 | \tex_gdef:D \abstractname { A\,B\,S\,T\,R\,A\,C\,T }
1503 | \tl_new:N \l_stm_abs_title_tl
1504 | \box_new:N \g_stm_abs_box
1505 |
1506 | \NewDocumentEnvironment { Abstract } { o }
1507 | {
1508 | % \global\setbox \g_stm_abs_box = \vtop \bgroup
1509 | % \hsize = .65 \textwidth \parindent \z@
1510 | \group_begin:
1511 | \IfNoValueTF { #1 } { }
1512 | { \tex_gdef:D \abstractname { #1 } }
1513 | \parindent \z@
1514 | \box_if_empty:NTF \g_stm_key_box
1515 | { \leftskip = .35 \textwidth }
1516 | {
1517 | \dim_gset:Nn \l_tmpa_dim { \box_ht:N \g_stm_key_box }
1518 | \dim_gadd:Nn \l_tmpa_dim { \box_dp:N \g_stm_key_box }
1519 | \leftskip .35\textwidth
1520 | \hspace*{-.35 \textwidth }
1521 | \noindent\hbox_to_wd:nn { \z@ } { \box \g_stm_key_box }
1522 | \skip_vertical:n { - \l_tmpa_dim }
1523 | }
1524 | \noindent \abstractname \par
1525 | \skip_vertical:n { -4pt}
1526 | \noindent \rule{.65\textwidth}{.2pt}\par \footnotesize
1527 | \ignorespaces \everypar { \parindent=1.5em }
1528 | }
1529 | { \par \group_end: }
1530 |
1531 | \NewDocumentEnvironment { PrelimsAbstract } { O{} }
1532 | {\parindent=0pt
1533 | { \fontsize{14pt}{16pt}\selectfont #1 }\par
1534 | \vskip12pt
1535 | { \fontsize{12pt}{14pt}\bfseries\selectfont\casprelimstitle } \par
1536 | \vskip6pt
1537 | \ifnum\theblind>0\relax
1538 | \vspace*{\the\baselineskip}
1539 | \else
1540 | \seq_use:Nn \g_stm_prelimsau_seq { , }
1541 | \fi
1542 | \vskip12pt
1543 | \par
1544 | }
1545 | {}
1546 |
1547 | \RenewDocumentEnvironment { abstract } { o }
1548 | {
1549 | \IfNoValueTF { #1 } { }
1550 | { \tex_gdef:D \abstracttitle { #1 } }
1551 | \verbatimwrite{\jobname.abs}
1552 | }
1553 | { \endverbatimwrite }
1554 |
1555 | \newbox\casgrabsbox
1556 | \newbox\casauhlbox
1557 | \newbool { usecasgrabsbox }
1558 | \newbool { usecashlsbox }
1559 |
1560 | \DeclareDocumentEnvironment { graphicalabstract } { O{Graphical~Abstract} }
1561 | {
1562 | \global \booltrue { usecasgrabsbox }
1563 | \global\setbox\casgrabsbox=\vbox\bgroup
1564 | \begin{PrelimsAbstract}[#1]
1565 | \noindent \ignorespaces
1566 | }
1567 | {
1568 | \end{PrelimsAbstract}
1569 | \egroup
1570 | }
1571 |
1572 | \DeclareDocumentEnvironment { highlights } { O{Highlights} }
1573 | {
1574 | \global \booltrue { usecashlsbox }
1575 | \global\setbox\casauhlbox=\vbox\bgroup
1576 | \begin{PrelimsAbstract}[#1]
1577 | \noindent \ignorespaces
1578 | \begin{itemize}
1579 | }
1580 | {
1581 | \end{itemize}
1582 | \end{PrelimsAbstract}
1583 | \egroup
1584 | }
1585 |
1586 |
1587 | \NewDocumentCommand \dashrule { O{.4pt} m m }
1588 | {
1589 | \color{black!50}
1590 | \skip_vertical:n { #2 }
1591 | \noindent \rule { \linewidth } { #1}
1592 | \normalcolor \skip_vertical:n { #3 }
1593 | }
1594 |
1595 | \NewDocumentCommand \keywordtitle { } { Keywords }
1596 | \NewDocumentCommand \keywordtitlesep { } {:\c_space_token }
1597 | \box_new:N \g_stm_key_box
1598 |
1599 | \NewDocumentCommand \MSC { O{} m }
1600 | {
1601 | \par\noindent \textit { #1\c_space_token MSC:\c_space_token } #2
1602 | }
1603 | \NewDocumentCommand \JEL { m }
1604 | {
1605 | \par\noindent \textit { JEL:\c_space_token } #1
1606 | }
1607 | \NewDocumentCommand \PACS { m }
1608 | {
1609 | \par\noindent \textit { PACS:\c_space_token } #1
1610 | }
1611 |
1612 | \NewDocumentEnvironment { keywords } { O{ Keywords } }
1613 | {
1614 | \tex_global:D \tex_setbox:D \g_stm_key_box = \vtop \bgroup
1615 | \hsize=.25 \textwidth
1616 | \cs_new:Nn \sep: { \par }
1617 | \cs_set_eq:NN \sep \sep:
1618 | \parindent \z@
1619 | A\,R\,T\,I\,C\,L\,E\ \ I\,N\,F\,O \par \skip_vertical:n { -3pt }
1620 | \rule{.25 \textwidth}{.2pt}\par\footnotesize
1621 | \noindent \textit { #1 }: \par
1622 | }
1623 | { \egroup }
1624 |
1625 |
1626 | %
1627 | % Print all footnotes in the title page
1628 | %
1629 |
1630 | \bool_new:N \g_stm_longmktitle_bool
1631 | \int_new:N \g_stm_jtype_int
1632 | \int_new:N \g_stm_blind_int
1633 |
1634 | \NewDocumentCommand \printFirstPageNotes { }
1635 | {
1636 | \bool_if:NTF \g_stm_longmktitle_bool
1637 | { \tex_let:D \columnwidth = \textwidth }
1638 | { }
1639 | \int_compare:nTF { \g_stm_jtype_int > 5 }
1640 | { \stmaddress }
1641 | { }
1642 | \printtnotes
1643 | \printnonumnotes
1644 | \bool_if:NTF \g_stm_blind_bool
1645 | { }
1646 | {
1647 | \printcornotes
1648 | \printmaltese
1649 | \printaddrinfoot
1650 | \printemails
1651 | \printurls
1652 | \printorcid
1653 | \printfacebook
1654 | \printtwitter
1655 | \printgplus
1656 | \printlinkedin
1657 | \printfnotes
1658 | }
1659 | \bool_if:NTF \g_stm_longmktitle_bool
1660 | {
1661 | \if@twocolumn
1662 | \tex_let:D \columnwidth = \Columnwidth \fi
1663 | }
1664 | { }
1665 | \normalcolor
1666 | }
1667 |
1668 | %
1669 | % Date History
1670 | %
1671 | \tl_new:N \g_stm_recd_tl
1672 | \tl_new:N \g_stm_accd_tl
1673 | \tl_new:N \g_stm_revd_tl
1674 | \tl_new:N \g_stm_pub_online_tl
1675 | \tl_new:N \g_stm_pub_print_tl
1676 |
1677 | \cs_new:Npn \date_parse:n #1 { \date_parse_aux:w #1 \q_stop }
1678 | \cs_new:Npn \date_parse_aux:w #1 / #2 / #3 \q_stop
1679 | { }
1680 |
1681 | \NewDocumentCommand \received { m }
1682 | { \tl_gput_right:Nn \g_stm_recd_tl { #1 } }
1683 | \NewDocumentCommand \accepted { m }
1684 | { \tl_gput_right:Nn \g_stm_accd_tl { #1 } }
1685 | \NewDocumentCommand \revised { m }
1686 | { \tl_gput_right:Nn \g_stm_revd_tl { #1 } }
1687 | \NewDocumentCommand \published { O{} m }
1688 | {
1689 | \tl_if_eq:nnTF { #1 } { online }
1690 | { \tl_if_gput_right:Nn \g_stm_pub_online_tl { #2 } }
1691 | { \tl_if_gput_right:Nn \g_stm_pub_print_tl { #2 } }
1692 | }
1693 |
1694 | %
1695 | % Verse/Recto
1696 | %
1697 | \tl_new:N \l_stm_verso_tl
1698 | \tl_new:N \l_stm_recto_tl
1699 |
1700 | \NewDocumentCommand \verso { m }
1701 | { \tl_set:Nn \l_stm_verso_tl { #1 } }
1702 | \NewDocumentCommand \recto { m }
1703 | { \tl_set:Nn \l_stm_recto_tl { #1 } }
1704 |
1705 | %
1706 | % Maketitle
1707 | %
1708 |
1709 | \newcounter{au}
1710 | \newcounter{cnote}
1711 | \newcounter{tnote}
1712 | \newcounter{fnote}
1713 | \newcounter{aff}
1714 |
1715 | \cs_new:Nn \__reset_title_counters:
1716 | {
1717 | \setcounter{cnote}{0}
1718 | \setcounter{fnote}{0}
1719 | \setcounter{tnote}{0}
1720 | \setcounter{footnote}{0}
1721 | }
1722 |
1723 | \keys_define:nn { stm / mktitle }
1724 | {
1725 | blind .bool_gset:N = \g_stm_blind_bool ,
1726 | footer .multichoice:,
1727 | footer/default .tl_gset:N = \g_stm_footer_default_tl ,
1728 | footer/custom .tl_gset:N = \g_stm_footer_custom_tl ,
1729 | longtitle .bool_gset:N = \g_stm_longtitle_bool ,
1730 | longabstract .bool_gset:N = \g_stm_longtitle_bool ,
1731 | breakafter .clist_gset:N = \g_stm_breakafter_clist ,
1732 | nologo .bool_gset:N = \g_stm_nologo_bool ,
1733 | }
1734 |
1735 | \bool_new:N \g_stm_breakafter_title_bool
1736 | \bool_new:N \g_stm_breakafter_auaff_bool
1737 | \bool_new:N \g_stm_breakafter_abstract_bool
1738 |
1739 | \NewDocumentCommand \processbreakafter { }
1740 | {
1741 | \clist_if_empty:NTF \g_stm_breakafter_clist { }
1742 | {
1743 | \clist_map_inline:Nn \g_stm_breakafter_clist
1744 | { \bool_gset_true:c { g_stm_breakafter_##1_bool } }
1745 | }
1746 | }
1747 |
1748 | \NewDocumentCommand \pprintMaketitle { O{} }
1749 | {
1750 | \tl_if_blank:nTF { #1 } { }
1751 | { \keys_set:nn { stm / mktitle } { #1 } }
1752 | \processbreakafter
1753 | \clearpage
1754 | \__reset_title_counters:
1755 | \tex_def:D \baselinestretch { 1 }
1756 | \printFirstPageNotes
1757 | \thispagestyle{pprintTitle}%
1758 | \group_begin:
1759 | \@title
1760 | \group_end:
1761 | \bool_if:NTF \g_stm_breakafter_title_bool
1762 | { \newpage } { }
1763 | %
1764 | \bool_if:NTF \g_stm_blind_bool
1765 | { \vspace* { 10 mm } }
1766 | {
1767 | \group_begin:
1768 | \normalsize \stmauthors \par
1769 | \stmcollab \par
1770 | \footnotesize \itshape \stmaddress \par \vskip36pt
1771 | \group_end:
1772 | \bool_if:NTF \g_stm_breakafter_auaff_bool
1773 | { \newpage } { }
1774 | }
1775 | %
1776 | \printabsbox
1777 | \printkeybox
1778 | \bool_if:NTF \g_stm_breakafter_abstract_bool
1779 | { \newpage } { }
1780 | %
1781 | \setcounter{footnote}{\c@fnote}
1782 | \tex_gdef:D \thefootnote { \arabic{footnote} }
1783 | \tex_def:D \baselinestretch { \@blstr }
1784 | \normalfont \normalsize
1785 | }
1786 |
1787 | \NewDocumentCommand \MaketitleBox { O{} }
1788 | {
1789 | \tl_if_blank:nTF { #1 } { }
1790 | { \keys_set:nn { stm / mktitle } { #1 } }
1791 | \processbreakafter
1792 | \tex_def:D \baselinestretch{1}
1793 | \group_begin:
1794 | \@title
1795 | \group_end:
1796 | %
1797 | \bool_if:NTF \g_stm_blind_bool
1798 | { \vspace* { 10 mm } }
1799 | {
1800 | \group_begin:
1801 | \normalsize \stmauthors \par
1802 | \stmcollab \par
1803 | \footnotesize \itshape \stmaddress \par
1804 | \group_end:
1805 | \bool_if:NTF \g_stm_breakafter_auaff_bool
1806 | { \newpage } { }
1807 | }
1808 | % \printFirstPageNotes
1809 | %
1810 | \dashrule{0pt}{3pt}
1811 | \begin{Abstract}
1812 | \noindent \ignorespaces
1813 | \file_if_exist:nT { \jobname.abs } { \file_input:n { \jobname.abs } }
1814 | \end{Abstract}
1815 | \dashrule{6pt}{3pt}
1816 | \bool_if:NTF \g_stm_breakafter_abstract_bool
1817 | { \newpage } { }
1818 | }
1819 |
1820 | \box_new:N \g_stm_notes_box
1821 | \box_new:N \g_stm_front_box
1822 | \cs_set:Npn \__fn_text:n #1
1823 | { \group_begin:\vbox_top:n { \footnotesize #1 } \group_end:\par}
1824 |
1825 | \NewDocumentCommand \LongMaketitleBox { O{} }
1826 | {
1827 | \tl_if_blank:nTF { #1 } { }
1828 | { \keys_set:nn { stm / mktitle } { #1 } }
1829 | \vbox_gset:Nn \g_stm_front_box
1830 | {
1831 | \tex_def:D \baselinestretch{1}
1832 | \group_begin:
1833 | \@title
1834 | \group_end:
1835 | %
1836 | \bool_if:NTF \g_stm_blind_bool
1837 | { \vspace* { 10 mm } }
1838 | { \group_begin:
1839 | \normalsize \stmauthors \par
1840 | \stmcollab \par
1841 | \footnotesize \itshape \stmaddress \par
1842 | \group_end:
1843 | }
1844 | %
1845 | \dashrule{0pt}{3pt}
1846 | \begin{Abstract}
1847 | \noindent \ignorespaces
1848 | \file_if_exist:nT { \jobname.abs } { \file_input:n { \jobname.abs } }
1849 | \end{Abstract}
1850 | \dashrule{3pt}{3pt}
1851 | }
1852 | \vbox_gset:Nn \g_stm_notes_box
1853 | { \cs_set_eq:NN \footnotetext \__fn_text:n \printFirstPageNotes }
1854 | \dim_gset:Nn \g_tmpb_dim { \box_ht:N \g_stm_notes_box }
1855 | % \iow_term:x { ...~[ht: \dim_use:N \g_tmpb_dim ] }
1856 | \dim_gadd:Nn \g_tmpb_dim { \box_dp:N \g_stm_notes_box }
1857 | % \iow_term:x { ...~[ht+dp: \dim_use:N \g_tmpb_dim ] }
1858 | \ifbool{sc}{\dim_gadd:Nn \g_tmpb_dim { 12pt } } { }
1859 |
1860 | }
1861 |
1862 | \NewDocumentCommand \ProcessLongTitleBox { }
1863 | {
1864 | % \vbox_gset:Nn \g_stm_notes_box
1865 | % { \cs_set_eq:NN \footnotetext \__fn_text:n \printFirstPageNotes }
1866 | % \dim_gset:Nn \g_tmpb_dim { \box_ht:N \g_stm_notes_box }
1867 | % % \iow_term:x { ...~[ht: \dim_use:N \g_tmpb_dim ] }
1868 | % \dim_gadd:Nn \g_tmpb_dim { \box_dp:N \g_stm_notes_box }
1869 | % % \iow_term:x { ...~[ht+dp: \dim_use:N \g_tmpb_dim ] }
1870 | %
1871 | \dim_gset:Nn \g_tmpa_dim { \textheight }
1872 | % \vbox_unpack:N \g_stm_notes_box
1873 | % \iow_term:x { ...~[tmpa:~ \dim_use:N \g_tmpa_dim ] }
1874 | % \dim_gsub:Nn \g_tmpa_dim { \box_ht:N \g_stm_notes_box }
1875 | % \iow_term:x { ...~[tmpa-noteht:~ \dim_use:N \g_tmpa_dim ] }
1876 | % \dim_gsub:Nn \g_tmpa_dim { \box_dp:N \g_stm_notes_box }
1877 | % \iow_term:x { ...~[tmpa-notedp:~ \dim_use:N \g_tmpa_dim ] }
1878 | \dim_gsub:Nn \g_tmpa_dim { \g_tmpb_dim }
1879 | \vbox_set_split_to_ht:NNn \g_tmpb_box \g_stm_front_box { \g_tmpa_dim }
1880 | \noindent \vbox_unpack_clear:N \g_tmpb_box
1881 | \printFirstPageNotes
1882 | \dim_gzero:N \g_tmpa_dim
1883 | \dim_gset:Nn \g_tmpa_dim { \box_ht:N \g_stm_front_box }
1884 | % \iow_term:x { ...~[tmpa-ht:~ \dim_use:N \g_tmpa_dim ] }
1885 | \dim_gadd:Nn \g_tmpa_dim { \box_dp:N \g_stm_front_box }
1886 | % \iow_term:x { ...~[tmpa-ht+dp:~ \dim_use:N \g_tmpa_dim ~+~\the\textheight] }
1887 | \dim_compare:nNnTF { \dim_use:N \g_tmpa_dim } > { \the\textheight }
1888 | {
1889 | \vbox_set_split_to_ht:NNn \g_tmpb_box \g_stm_front_box { \textheight }
1890 | \vbox_unpack_clear:N \g_tmpb_box
1891 | \ifbool{dc}
1892 | { \twocolumn[{\vbox_unpack_clear:N \g_stm_front_box}] }
1893 | { \vbox_unpack_clear:N \g_stm_front_box }
1894 | }
1895 | {
1896 | \ifbool{dc}
1897 | { \twocolumn[{\vbox_unpack_clear:N \g_stm_front_box}] }
1898 | { \vbox_unpack_clear:N \g_stm_front_box }
1899 | }
1900 | \normalcolor \normalfont
1901 | }
1902 | \ExplSyntaxOff
1903 |
1904 | %
1905 | % Headings
1906 | %
1907 | \def\@seccntDot{.}
1908 | \def\@seccntformat#1{\csname the#1\endcsname\@seccntDot\hskip 0.5em}
1909 |
1910 | \newdimen\paraindent \paraindent=\parindent
1911 | \newdimen\subparaindent \subparaindent=\parindent
1912 | \def\ssssparaindent{}
1913 | \def\sectionfont{\rmfamily\fontsize{12pt}{14pt}%
1914 | \bfseries}
1915 | \def\ssectionfont{\rmfamily\fontsize{11pt}{13pt}%
1916 | \bfseries\selectfont}
1917 | \def\sssectionfont{\rmfamily\fontsize{10.5pt}{12pt}%
1918 | \fontseries{b}\fontshape{it}\selectfont}
1919 | \def\ssssectionfont{\rmfamily\fontsize{11pt}{10pt}\itshape\selectfont}
1920 | \def\sssssectionfont{\rmfamily\fontsize{11pt}{10pt}\selectfont}%
1921 |
1922 | \AtBeginDocument{\global\@afterindentfalse}
1923 |
1924 | \renewcommand\section{\@startsection{section}{1}{\z@}%
1925 | {15pt \@plus 3\p@ \@minus 3\p@}%
1926 | {4\p@}%
1927 | {%\let\@hangfrom\relax
1928 | \sectionfont\raggedright\hst[13pt]}}
1929 |
1930 | \renewcommand\subsection{\@startsection{subsection}{2}{\z@}%
1931 | {10pt \@plus 3\p@ \@minus 2\p@}%
1932 | {.1\p@}%
1933 | {%\let\@hangfrom\relax
1934 | \ssectionfont\raggedright }}
1935 |
1936 | \renewcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%
1937 | {10pt \@plus 1\p@ \@minus .3\p@}%
1938 | {.1\p@}%
1939 | {%\let\@hangfrom\relax
1940 | \sssectionfont\raggedright}}
1941 |
1942 | \renewcommand\paragraph{\@startsection{paragraph}{4}{\parindent}%
1943 | {10pt \@plus0.01pt \@minus0.01pt}%
1944 | {-6pt}%
1945 | {\ssssparaindent%
1946 | \ssssectionfont\itshape\raggedright}}
1947 |
1948 | \renewcommand\subparagraph{\@startsection{subparagraph}{5}{\parindent}%
1949 | {0pt \@plus0.1pt \@minus0.1pt}%
1950 | {-6pt}%
1951 | {\hspace*{\subparaindent}
1952 | \sssssectionfont\raggedright}}
1953 |
1954 | \def\thesubsection{\thesection.\arabic{subsection}}
1955 | \def\thesubsubsection{\thesubsection.\arabic{subsubsection}}
1956 |
1957 | %
1958 | % Sundry lengths
1959 | %
1960 | \def\xstrut#1#2{\vrule height#1 depth #2 width\z@}
1961 | \def\hstrut#1{\vrule height#1 depth \z@ width 0pt}
1962 | \def\dstrut#1{\vrule height0pt depth#1 width 0pt}
1963 | \def\hst[#1]{\vrule height#1 depth \z@ width \z@}
1964 | \def\dst[#1]{\vrule height0pt depth#1 width 0pt}
1965 | \def\xst[#1][#2]{\vrule height#1 depth #2 width\z@}
1966 |
1967 | \def\lastpage{100}
1968 |
1969 | \AtEndDocument{%
1970 | % \clearpage
1971 | \immediate\write\@auxout{\string\csxdef{lastpage}{\thepage}}
1972 | }
1973 |
1974 | \ExplSyntaxOn
1975 |
1976 | %
1977 | % pagestyle
1978 | %
1979 |
1980 | \cs_new:Npn \__first_footerline:
1981 | {
1982 | \group_begin:
1983 | \small
1984 | \sffamily
1985 | \ifnum\theblind>0\relax
1986 | \else
1987 | \__short_authors: :~
1988 | \fi
1989 | { \rmfamily \itshape Preprint~ submitted ~to ~Elsevier }
1990 | \group_end:
1991 | }
1992 |
1993 | \cs_new:Npn \__first_head:
1994 | {
1995 | \parbox[t]{\textwidth}
1996 | {
1997 | \color{black!20}
1998 | \rule{\textwidth}{0pt}
1999 | }
2000 | }
2001 |
2002 |
2003 | \cs_new:Npn \__first_foot:
2004 | {
2005 | \parbox[t]{\textwidth}
2006 | {
2007 | \rule{\textwidth}{.2pt}\\
2008 | \__first_footerline: \hfill Page~ \thepage {} ~of~ \lastpage }
2009 | }
2010 |
2011 |
2012 | \cs_new:Npn \__cas_head:
2013 | {
2014 | \parbox{\textwidth}
2015 | {
2016 | \sffamily\small\centering
2017 | \__short_title:
2018 | }
2019 | }
2020 |
2021 |
2022 | \cs_new:Npn \__cas_foot:
2023 | {
2024 | \parbox[t]{\textwidth}
2025 | {
2026 | \rule{\textwidth}{.2pt}\\
2027 | \sffamily\small
2028 | \__first_footerline:
2029 | \hfill Page~\thepage {}~of~ \lastpage
2030 | }
2031 | }
2032 |
2033 | \newcommand \ps@first
2034 | {
2035 | \cs_set_eq:NN \@oddhead \__first_head:
2036 | \cs_set_eq:NN \@evenhead \__first_head:
2037 | \cs_set_eq:NN \@evenfoot \__first_foot:
2038 | \cs_set_eq:NN \@oddfoot \__first_foot:
2039 | }
2040 |
2041 |
2042 | \newcommand \ps@cas
2043 | {
2044 | \cs_set_eq:NN \@oddhead \__cas_head:
2045 | \cs_set_eq:NN \@evenhead \__cas_head:
2046 | \cs_set_eq:NN \@evenfoot \__cas_foot:
2047 | \cs_set_eq:NN \@oddfoot \__cas_foot:
2048 | }
2049 |
2050 | \ps@cas
2051 |
2052 |
2053 | %
2054 | % Floats
2055 | %
2056 |
2057 | \def\topfraction{.9}
2058 | \def\bottomfraction{.9}
2059 | \setcounter{topnumber}{4}
2060 | \setcounter{bottomnumber}{3}
2061 | \setcounter{totalnumber}{5}
2062 | \renewcommand\textfraction{.1}
2063 | \renewcommand\floatpagefraction{.9}
2064 | \setcounter{dbltopnumber}{2}
2065 | \renewcommand\dbltopfraction{.9}
2066 | \renewcommand\dblfloatpagefraction{.95}
2067 | \newdimen \FullWidth
2068 | \ABD{\FullWidth=\textwidth}
2069 |
2070 | \newcolumntype{L}{@{\extracolsep{\fill}}l}
2071 | \newcolumntype{R}{@{\extracolsep{\fill}}r}
2072 | \newcolumntype{C}{@{\extracolsep{\fill}}c}
2073 |
2074 | \cs_gset_eq:NN \thead \toprule
2075 | \cs_gset_eq:NN \endthead \midrule
2076 | \cs_gset_eq:NN \tabref \ref
2077 |
2078 | \dim_new:N \l_tbl_width_dim
2079 | \dim_set:Nn \l_tbl_width_dim { \linewidth }
2080 |
2081 | \cs_new:Npn \__make_tbl_caption:nn #1#2
2082 | {
2083 | \l_tbl_align_tl
2084 | \skip_vertical:N \l_tbl_abovecap_skip
2085 | % \bool_if:NTF \g_tbl_full_bool
2086 | % {
2087 | % \color{scolor!70}\rule{\FullWidth}{2pt}\normalcolor\\
2088 | % }
2089 | % { \color{scolor!70}\rule{\tblwidth}{2pt}\normalcolor\\ }
2090 | % \fboxsep=4pt
2091 | % \colorbox{white}
2092 | {\parbox{ \dimexpr(\l_tbl_width_dim)}
2093 | {\rightskip=0pt\sffamily\small\textbf{\color{scolor}#1}\par#2\par\vskip4pt }}
2094 | \skip_vertical:N \l_tbl_belowcap_skip
2095 | }
2096 |
2097 | \keys_define:nn { cas / tbl }
2098 | {
2099 | width .dim_set:N = \l_tbl_width_dim ,
2100 | pos .tl_set:N = \l_tbl_pos_tl ,
2101 | cols .tl_set:N = \l_tbl_cols_tl ,
2102 | align .tl_set:N = \l_tbl_align_tl,
2103 | abovecap .skip_set:N = \l_tbl_abovecap_skip ,
2104 | belowcap .skip_set:N = \l_tbl_belowcap_skip ,
2105 | abovetbl .skip_set:N = \l_tbl_abovetbl_skip ,
2106 | belowtbl .skip_set:N = \l_tbl_belowtbl_skip ,
2107 | full .bool_gset:N = \g_tbl_full_bool ,
2108 | unknown .code:n = {
2109 | \ifstrempty { #1 }
2110 | {
2111 | \tl_set:Nn \l_fig_pos_tl { \l_keys_key_tl }
2112 | }
2113 | {
2114 | \l_keys_key_tl=#1
2115 | }
2116 | }
2117 | }
2118 |
2119 | \cs_set:Npn \__reset_tbl:
2120 | {
2121 | \tl_set:Nx \l_tbl_pos_tl { t }
2122 | \tl_set:Nx \l_tbl_cols_tl { 1 }
2123 | \tl_set:Nn \l_tbl_align_tl { \centering }
2124 | \skip_set:Nn \l_tbl_abovecap_skip { 6pt }
2125 | \skip_set:Nn \l_tbl_belowcap_skip { 0pt }
2126 | \skip_set:Nn \l_tbl_abovetbl_skip { 6pt }
2127 | \skip_set:Nn \l_tbl_belowtbl_skip { 6pt }
2128 |
2129 | }
2130 |
2131 | \RenewDocumentEnvironment { table } { O{} }
2132 | {
2133 | \__reset_tbl:
2134 | \bool_gset_false:N \g_tbl_full_bool
2135 | \dim_set:Nn \l_tbl_width_dim { \linewidth }
2136 | \keys_set:nn { cas / tbl } { #1 }
2137 | \csxdef{fps@table}{\l_tbl_pos_tl}
2138 | \csgdef{tblwidth}{\dim_use:N \l_tbl_width_dim}
2139 | \cs_set_eq:NN \@makecaption \__make_tbl_caption:nn
2140 | \@float{table}
2141 | \l_tbl_align_tl
2142 | \sffamily\small
2143 | }
2144 | {
2145 | \end@float
2146 | }
2147 |
2148 |
2149 | \RenewDocumentEnvironment { table* } { O{width=\FullWidth} }
2150 | {
2151 | \__reset_tbl:
2152 | \bool_gset_true:N \g_tbl_full_bool
2153 | \dim_set:Nn \l_tbl_width_dim { \FullWidth }
2154 | \keys_set:nn { cas / tbl } { #1 }
2155 | \csxdef{fps@table}{\l_tbl_pos_tl}
2156 | \csgdef{tblwidth}{\dim_use:N \l_tbl_width_dim}
2157 | \cs_set_eq:NN \@makecaption \__make_tbl_caption:nn
2158 | \@dblfloat{table}
2159 | \l_tbl_align_tl
2160 | \sffamily\small
2161 | % \leftskip=-\FullWidth
2162 | }
2163 | {
2164 | \end@dblfloat
2165 | }
2166 |
2167 |
2168 | \dim_new:N \l_fig_width_dim
2169 | \dim_set:Nn \l_fig_width_dim { \linewidth }
2170 |
2171 | \newbox\cascaptionbox
2172 |
2173 | \cs_new:Npn \__make_fig_caption:nn #1#2
2174 | {
2175 | \l_fig_align_tl
2176 | \skip_vertical:N \l_fig_abovecap_skip
2177 | % \bool_if:NTF \g_fig_full_bool
2178 | % { \skip_horizontal:n { -\FullWidth } } { }
2179 | \setbox\cascaptionbox=\hbox{%
2180 | \sffamily\small\textbf{\color{scolor}#1:}~#2}
2181 | \ifdim\the\wd\cascaptionbox<\dim_use:N \l_fig_width_dim\relax
2182 | \parbox{ \l_fig_width_dim }
2183 | {\unskip\ignorespaces\hfil\sffamily\small
2184 | \textbf{\color{scolor}#1:}~#2\hfil\par }
2185 | \else
2186 | \parbox{ \l_fig_width_dim }
2187 | {\rightskip=0pt\unskip\ignorespaces\sffamily
2188 | \small\textbf{\color{scolor}#1:}~#2\par }
2189 | \fi
2190 | \skip_vertical:N \l_fig_belowcap_skip
2191 | }
2192 |
2193 | \keys_define:nn { cas / fig }
2194 | {
2195 | width .dim_set:N = \l_fig_width_dim ,
2196 | pos .tl_set:N = \l_fig_pos_tl ,
2197 | cols .tl_set:N = \l_fig_cols_tl ,
2198 | align .tl_set:N = \l_fig_align_tl,
2199 | abovecap .skip_set:N = \l_fig_abovecap_skip ,
2200 | belowcap .skip_set:N = \l_fig_belowcap_skip ,
2201 | abovefig .skip_set:N = \l_fig_abovefig_skip ,
2202 | belowfig .skip_set:N = \l_fig_belowfig_skip ,
2203 | full .bool_gset:N = \g_fig_full_bool ,
2204 | unknown .code:n = {
2205 | \ifstrempty { #1 }
2206 | {
2207 | \tl_set:Nn \l_fig_pos_tl { \l_keys_key_tl }
2208 | }
2209 | {
2210 | \l_keys_key_tl=#1,
2211 | }
2212 | }
2213 | }
2214 |
2215 | \cs_set:Npn \__reset_fig:
2216 | {
2217 | \tl_set:Nx \l_fig_pos_tl { t }
2218 | \tl_set:Nx \l_fig_cols_tl { 1 }
2219 | \tl_set:Nn \l_fig_align_tl { \raggedleft }
2220 | \skip_set:Nn \l_fig_abovecap_skip { 6pt }
2221 | \skip_set:Nn \l_fig_belowcap_skip { 6pt }
2222 | \skip_set:Nn \l_fig_abovefig_skip { 6pt }
2223 | \skip_set:Nn \l_fig_belowfig_skip { 6pt }
2224 |
2225 | }
2226 |
2227 | \RenewDocumentEnvironment { figure } { O{} }
2228 | {
2229 | \__reset_fig:
2230 | \bool_gset_false:N \g_fig_full_bool
2231 | \dim_set:Nn \l_fig_width_dim { \linewidth }
2232 | \keys_set:nn { cas / fig } { #1 }
2233 | \csxdef{fps@figure}{\l_fig_pos_tl}
2234 | \csgdef{figwidth}{\dim_use:N \l_fig_width_dim}
2235 | \cs_set_eq:NN \@makecaption \__make_fig_caption:nn
2236 | \@float{figure}
2237 | \l_fig_align_tl
2238 | \sffamily\small
2239 | }
2240 | {
2241 | \end@float
2242 | }
2243 |
2244 |
2245 | \RenewDocumentEnvironment { figure* } { O{width=\textwidth} }
2246 | {
2247 | \__reset_fig:
2248 | \bool_gset_true:N \g_fig_full_bool
2249 | \dim_set:Nn \l_fig_width_dim { \FullWidth }
2250 | \keys_set:nn { cas / fig } { #1 }
2251 | \csxdef{fps@figure}{\l_fig_pos_tl}
2252 | \csgdef{figwidth}{\dim_use:N \l_fig_width_dim}
2253 | \cs_set_eq:NN \@makecaption \__make_fig_caption:nn
2254 | \@dblfloat{figure}
2255 | \l_fig_align_tl
2256 | \sffamily\small
2257 | % \leftskip=-\FullWidth
2258 | }
2259 | { \end@dblfloat }
2260 |
2261 | %
2262 | % wrapped figure
2263 | %
2264 | \RequirePackage{wrapfig}
2265 |
2266 | \dim_new:N \l_wrap_figwidth_dim
2267 | \dim_new:N \l_wrap_fighspace_dim
2268 | \dim_new:N \l_wrap_figvspace_dim
2269 | \dim_new:N \l_wrap_fighcorr_dim
2270 | \dim_new:N \l_wrap_figvcorr_dim
2271 | \dim_new:N \l_above_bio_dim
2272 | \int_new:N \l_wrap_figlcorr_int
2273 | \int_new:N \l_wrap_figlines_int
2274 | \tl_new:N \l_wrap_figfile_tl
2275 |
2276 | \NewDocumentCommand \wfigwidth { m }
2277 | { \dim_set:Nn \l_wrap_figwidth_dim { #1 } }
2278 | \NewDocumentCommand \wfighspace { m }
2279 | { \dim_set:Nn \l_wrap_fighspace_dim { #1 } }
2280 | \NewDocumentCommand \wfigvspace { m }
2281 | { \dim_set:Nn \l_wrap_figvspace_dim { #1 } }
2282 | \NewDocumentCommand \wfighcorr { m }
2283 | { \dim_set:Nn \l_wrap_fighcorr_dim { #1 } }
2284 | \NewDocumentCommand \wfigvcorr { m }
2285 | { \dim_set:Nn \l_wrap_figvcorr_dim { #1 } }
2286 | \NewDocumentCommand \addfiglines { m }
2287 | { \int_set:Nn \l_wrap_figlcorr_int { #1 } }
2288 | \NewDocumentCommand \abovebioskip { m }
2289 | { \dim_set:Nn \l_above_bio_dim { #1 } }
2290 |
2291 | \cs_new:Nn \__fig_defaults:
2292 | {
2293 | \wfigwidth { 25.5mm }
2294 | \wfighspace { 0mm }
2295 | \wfigvspace { 0mm }
2296 | \wfighcorr { 0pt }
2297 | \wfigvcorr { -12pt }
2298 | \wfigvcorr { 0pt }
2299 | \abovebioskip { 12pt }
2300 | \tl_set:Nn \l_wrap_figpos_tl { l }
2301 | \int_set:Nn \l_wrap_figlines_int { 3 }
2302 | \int_set:Nn \l_wrap_figlcorr_int { 1 }
2303 | \tl_clear:N \l_wrap_figcap_tl
2304 | }
2305 |
2306 | \__fig_defaults:
2307 |
2308 | \keys_define:nn { wrap / fig }
2309 | {
2310 | width .dim_set:N = \l_wrap_figwidth_dim ,
2311 | hspace .dim_set:N = \l_wrap_fighspace_dim ,
2312 | vspace .dim_set:N = \l_wrap_figvspace_dim ,
2313 | hcorr .dim_set:N = \l_wrap_fighcorr_dim ,
2314 | vcorr .dim_set:N = \l_wrap_figvcorr_dim ,
2315 | lcorr .int_set:N = \l_wrap_figlcorr_int ,
2316 | pos .tl_set:N = \l_wrap_figpos_tl ,
2317 | lines .int_set:N = \l_wrap_figlines_int ,
2318 | cap .tl_set:N = \l_wrap_figcap_tl ,
2319 | }
2320 |
2321 | \cs_new:Npn \__find_fig_height:n #1
2322 | {
2323 | \box_clear:N \g_tmpa_box
2324 | \hbox_gset:Nn \g_tmpa_box
2325 | { \includegraphics [ width = \l_wrap_figwidth_dim ] { #1 } }
2326 | \dim_zero:N \l_tmpa_dim
2327 | \dim_set:Nn \l_tmpa_dim { \box_ht:N \g_tmpa_box }
2328 | \dim_add:Nn \l_tmpa_dim { \box_dp:N \g_tmpa_box }
2329 | \fp_set:Nn \l_tmpa_fp { \dim_to_fp:n { \l_tmpa_dim } }
2330 | \fp_set:Nn \l_tmpb_fp { \dim_to_fp:n { \baselineskip } }
2331 | %
2332 | \fp_set:Nn \l_wrap_figlines_fp
2333 | { \fp_eval:n { ( \l_tmpa_fp / \l_tmpb_fp ) + .5 } }
2334 | \int_set:Nn \l_wrap_figlines_int
2335 | { \fp_to_int:N \l_wrap_figlines_fp }
2336 | %
2337 | \iow_term:x { ...~wr-fig:~[BL:~\the\baselineskip] ~ ...}
2338 | \iow_term:x { ...~wr-fig:~[LINE-FP:~ \fp_use:N \l_wrap_figlines_fp]~ ...}
2339 | \iow_term:x { ...~wr-fig:~[LINE-INT:~ \int_use:N \l_wrap_figlines_int]~ ...}
2340 | }
2341 |
2342 | \newbox \l_bio_text_box
2343 |
2344 | \NewDocumentCommand \WrapFigure { o m }
2345 | {
2346 | \__fig_defaults:
2347 | \IfNoValueTF { #1 } { } { \keys_set:nn { wrap / fig } { #1 } }
2348 | \stepcounter { ca_biography_ctr }
2349 | \__find_fig_height:n { #2 }
2350 | \dim_zero:N \l_tmpb_dim
2351 | \dim_set:Nn \l_tmpb_dim
2352 | { \l_wrap_figwidth_dim + \l_wrap_fighspace_dim }
2353 | \int_gadd:Nn \l_wrap_figlines_int { \int_use:N \l_wrap_figlcorr_int }
2354 | \setlength { \columnsep } { 5pt }
2355 | \setlength { \intextsep } { 0pt }
2356 | % \mbox{}
2357 | \ifbool { dc }
2358 | { \xdef\Columnwidth{238.25pt} }
2359 | { \xdef\Columnwidth{\the\textwidth} }
2360 | \ifcsundef { cabio\theca_biography_ctr lines }
2361 | {
2362 | \setbox \l_bio_text_box = \vbox \bgroup
2363 | \hsize = \dimexpr ( \Columnwidth - 72.28pt )
2364 | }
2365 | {
2366 | \ifbool { dc } {
2367 | \int_gset:Nn \l_wrap_figlines_int
2368 | { \csuse { cabio\theca_biography_ctr lines } }
2369 | } { }
2370 | \skip_vertical:N \l_above_bio_dim
2371 | \begin{wrapfigure}[\int_use:N \l_wrap_figlines_int]
2372 | { \l_wrap_figpos_tl }
2373 | [ \dim_use:N \l_wrap_fighcorr_dim ]
2374 | { \dim_use:N \l_tmpb_dim }
2375 | %\skip_vertical:N \l_wrap_figvcorr_dim
2376 | \includegraphics[width=\l_wrap_figwidth_dim]{#2}
2377 | \end{wrapfigure}
2378 | \setbox \l_bio_text_box = \vbox \bgroup
2379 | \hsize = \dimexpr ( \Columnwidth )
2380 | }
2381 | }
2382 |
2383 | \cs_set:Nn \__fwidth: { 1in }
2384 | \cs_set:Nn \__fpos: { l }
2385 |
2386 | %
2387 | % short authors/title
2388 | %
2389 |
2390 | \newcommand\shortauthors[1]{ \cs_gset:Nn \__short_authors: { #1 } }
2391 | \newcommand\shorttitle[1]{ \cs_gset:Nn \__short_title: { #1 } }
2392 |
2393 | \shortauthors{First~Author~et~al.}
2394 | \shorttitle{Short ~Title ~of~the~Article}
2395 |
2396 | \newcounter { ca_biography_ctr }
2397 | \newbool { cas_no_pic_bio }
2398 | \boolfalse { cas_no_pic_bio }
2399 |
2400 | \ifnum\theblind>0\relax
2401 | \newbox\hidebiobox
2402 | \NewDocumentCommand \bio { O{} m }
2403 | {\setbox\hidebiobox=\vbox\bgroup}
2404 | \NewDocumentCommand \endbio { } {
2405 | \egroup
2406 | }
2407 | \else
2408 | \NewDocumentCommand \bio { O{} m }
2409 | {
2410 | \global \boolfalse { cas_no_pic_bio }
2411 | \casbiographyfont
2412 | \par \medskip \tl_set:Nn \l_tmpa_tl { #2 }
2413 | \tl_if_empty:NTF \l_tmpa_tl
2414 | { \global \booltrue { cas_no_pic_bio } }
2415 | { \WrapFigure [ #1 ]{ #2 } }
2416 | \noindent \ignorespaces
2417 | }
2418 |
2419 | \int_new:N \l_ca_temp_inta
2420 |
2421 | \NewDocumentCommand \endbio { } {
2422 | \ifbool{ cas_no_pic_bio } { } {
2423 | \egroup
2424 | % \fp_set:Nn \l_wrap_figlines_fp
2425 | % { \fp_eval:n { ( ( \l_tmpa_fp +
2426 | % \numexpr\dimexpr\the\ht\l_bio_text_box )
2427 | % / \l_tmpb_fp ) + .5 } }
2428 | \int_gset:Nn \l_ca_temp_inta
2429 | { \numexpr\dimexpr(\the\ht\l_bio_text_box + 2\baselineskip )/
2430 | \dimexpr\the\baselineskip }
2431 | \iow_now:Nx \@auxout {
2432 | \string\csgdef{cabio\theca_biography_ctr lines}
2433 | { \int_use:N \l_ca_temp_inta } }
2434 | \mbox{}\vspace*{-4.5pt}\noindent
2435 | \unvbox \l_bio_text_box }
2436 | }
2437 | \fi
2438 |
2439 | \let\casbiographyfont\relax
2440 |
2441 | \NewDocumentEnvironment { biography } { o m }
2442 | {
2443 | \IfValueTF { #1 }
2444 | { \par\medskip \noindent \includegraphics[width=1in]{#1} }
2445 | { }
2446 | \par\smallskip
2447 | \noindent \textbf{#2:}\enspace
2448 | }
2449 | { }
2450 |
2451 | \ExplSyntaxOff
2452 |
2453 | %
2454 | % Customized Enumeration
2455 | %
2456 | \def\blstr#1{\gdef\@bslstr{#1}}
2457 | \def\@blstr{1}
2458 | \newdimen\leftMargin
2459 | \leftMargin=2em
2460 | \newtoks\@enLab %\newtoks\@enfont
2461 | \def\@enQmark{?}
2462 | \def\@enLabel#1#2{%
2463 | \edef\@enThe{\noexpand#1{\@enumctr}}%
2464 | \@enLab\expandafter{\the\@enLab\csname the\@enumctr\endcsname}%
2465 | \@enloop}
2466 | \def\@enSpace{\afterassignment\@enSp@ce\let\@tempa= }
2467 | \def\@enSp@ce{\@enLab\expandafter{\the\@enLab\space}\@enloop}
2468 | \def\@enGroup#1{\@enLab\expandafter{\the\@enLab{#1}}\@enloop}
2469 | \def\@enOther#1{\@enLab\expandafter{\the\@enLab#1}\@enloop}
2470 | \def\@enloop{\futurelet\@entemp\@enloop@}
2471 | \def\@enloop@{%
2472 | \ifx A\@entemp \def\@tempa{\@enLabel\Alph }\else
2473 | \ifx a\@entemp \def\@tempa{\@enLabel\alph }\else
2474 | \ifx i\@entemp \def\@tempa{\@enLabel\roman }\else
2475 | \ifx I\@entemp \def\@tempa{\@enLabel\Roman }\else
2476 | \ifx 1\@entemp \def\@tempa{\@enLabel\arabic}\else
2477 | \ifx \@sptoken\@entemp \let\@tempa\@enSpace \else
2478 | \ifx \bgroup\@entemp \let\@tempa\@enGroup \else
2479 | \ifx \@enum@\@entemp \let\@tempa\@gobble \else
2480 | \let\@tempa\@enOther
2481 | \fi\fi\fi\fi\fi\fi\fi\fi
2482 | \@tempa}
2483 | \newlength{\@sep} \newlength{\@@sep}
2484 | \setlength{\@sep}{.5\baselineskip plus.2\baselineskip
2485 | minus.2\baselineskip}
2486 | \setlength{\@@sep}{.1\baselineskip plus.01\baselineskip
2487 | minus.05\baselineskip}
2488 | \providecommand{\sfbc}{\rmfamily\upshape}
2489 | \providecommand{\sfn}{\rmfamily\upshape}
2490 | \def\@enfont{\ifnum \@enumdepth >1\let\@nxt\sfn \else\let\@nxt\sfbc \fi\@nxt}
2491 | \def\enumerate{%
2492 | \ifnum \@enumdepth >3 \@toodeep\else
2493 | \advance\@enumdepth \@ne
2494 | \edef\@enumctr{enum\romannumeral\the\@enumdepth}\fi
2495 | \@ifnextchar[{\@@enum@}{\@enum@}}
2496 | \def\@@enum@[#1]{%
2497 | \@enLab{}\let\@enThe\@enQmark
2498 | \@enloop#1\@enum@
2499 | \ifx\@enThe\@enQmark\@warning{The counter will not be printed.%
2500 | ^^J\space\@spaces\@spaces\@spaces The label is: \the\@enLab}\fi
2501 | \expandafter\edef\csname label\@enumctr\endcsname{\the\@enLab}%
2502 | \expandafter\let\csname the\@enumctr\endcsname\@enThe
2503 | \csname c@\@enumctr\endcsname7
2504 | \expandafter\settowidth
2505 | \csname leftmargin\romannumeral\@enumdepth\endcsname
2506 | {\the\@enLab\hskip\labelsep}%
2507 | \@enum@}
2508 | \def\@enum@{\list{{\@enfont\csname label\@enumctr\endcsname}}%
2509 | {\usecounter{\@enumctr}\def\makelabel##1{\hss\llap{##1}}%
2510 | \ifnum \@enumdepth>1\setlength{\topsep}{\@@sep}\else
2511 | \setlength{\topsep}{\@sep}\fi
2512 | \ifnum \@enumdepth>1\setlength{\itemsep}{0pt plus1pt minus1pt}%
2513 | \else \setlength{\itemsep}{\@@sep}\fi
2514 | %\setlength\leftmargin{\leftMargin}%%%{1.8em}
2515 | \setlength{\parsep}{0pt plus1pt minus1pt}%
2516 | \setlength{\parskip}{0pt plus1pt minus1pt}
2517 | }}
2518 |
2519 | \def\endenumerate{\par\ifnum \@enumdepth >1\addvspace{\@@sep}\else
2520 | \addvspace{\@sep}\fi \endlist}
2521 |
2522 | \def\sitem{\@noitemargtrue\@item[\@itemlabel *]}
2523 |
2524 | \def\itemize{\@ifnextchar[{\@Itemize}{\@Itemize[]}}
2525 |
2526 | \def\@Itemize[#1]{\def\next{#1}%
2527 | \ifnum \@itemdepth >\thr@@\@toodeep\else
2528 | \advance\@itemdepth\@ne
2529 | \ifx\next\@empty\else\expandafter\def\csname
2530 | labelitem\romannumeral\the\@itemdepth\endcsname{#1}\fi%
2531 | \edef\@itemitem{labelitem\romannumeral\the\@itemdepth}%
2532 | \expandafter\list\csname\@itemitem\endcsname
2533 | {\def\makelabel##1{\hss\llap{##1}}}%
2534 | \fi}
2535 |
2536 | %
2537 | % Customized theorem
2538 | % (non-italic enunciations)
2539 | %
2540 |
2541 | \def\newdefinition#1{%
2542 | \@ifnextchar[{\@odfn{#1}}{\@ndfn{#1}}}%]
2543 | \def\@ndfn#1#2{%
2544 | \@ifnextchar[{\@xndfn{#1}{#2}}{\@yndfn{#1}{#2}}}
2545 | \def\@xndfn#1#2[#3]{%
2546 | \expandafter\@ifdefinable\csname #1\endcsname
2547 | {\@definecounter{#1}\@newctr{#1}[#3]%
2548 | \expandafter\xdef\csname the#1\endcsname{%
2549 | \expandafter\noexpand\csname the#3\endcsname \@dfncountersep
2550 | \@dfncounter{#1}}%
2551 | \global\@namedef{#1}{\@dfn{#1}{#2}}%
2552 | \global\@namedef{end#1}{\@enddefinition}}}
2553 | \def\@yndfn#1#2{%
2554 | \expandafter\@ifdefinable\csname #1\endcsname
2555 | {\@definecounter{#1}%
2556 | \expandafter\xdef\csname the#1\endcsname{\@dfncounter{#1}}%
2557 | \global\@namedef{#1}{\@dfn{#1}{#2}}%
2558 | \global\@namedef{end#1}{\@enddefinition}}}
2559 | \def\@odfn#1[#2]#3{%
2560 | \@ifundefined{c@#2}{\@nocounterr{#2}}%
2561 | {\expandafter\@ifdefinable\csname #1\endcsname
2562 | {\global\@namedef{the#1}{\@nameuse{the#2}}
2563 | \global\@namedef{#1}{\@dfn{#2}{#3}}%
2564 | \global\@namedef{end#1}{\@enddefinition}}}}
2565 | \def\@dfn#1#2{%
2566 | \refstepcounter{#1}%
2567 | \@ifnextchar[{\@ydfn{#1}{#2}}{\@xdfn{#1}{#2}}}
2568 | \def\@xdfn#1#2{%
2569 | \@begindefinition{#2}{\csname the#1\endcsname}\ignorespaces}
2570 | \def\@ydfn#1#2[#3]{%
2571 | \@opargbegindefinition{#2}{\csname the#1\endcsname}{#3}\ignorespaces}
2572 | \def\@dfncounter#1{\noexpand\arabic{#1}}
2573 | \def\@dfncountersep{.}
2574 | \def\@begindefinition#1#2{\trivlist
2575 | \item[\hskip\labelsep{\bfseries #1\ #2.}]\upshape}
2576 | \def\@opargbegindefinition#1#2#3{\trivlist
2577 | \item[\hskip\labelsep{\bfseries #1\ #2\ (#3).}]\upshape}
2578 | \def\@enddefinition{\endtrivlist}
2579 |
2580 | \def\@begintheorem#1#2{\trivlist
2581 | \let\baselinestretch\@blstr
2582 | \item[\hskip \labelsep{\bfseries #1\ #2.}]\itshape}
2583 | \def\@opargbegintheorem#1#2#3{\trivlist
2584 | \let\baselinestretch\@blstr
2585 | \item[\hskip \labelsep{\bfseries #1\ #2\ (#3).}]\itshape}
2586 | %
2587 | % Unnumbered roman proofs
2588 | %
2589 | \def\newproof#1{%
2590 | \@ifnextchar[{\@oprf{#1}}{\@nprf{#1}}}
2591 | \def\@nprf#1#2{%
2592 | \@ifnextchar[{\@xnprf{#1}{#2}}{\@ynprf{#1}{#2}}}
2593 | \def\@xnprf#1#2[#3]{%
2594 | \expandafter\@ifdefinable\csname #1\endcsname
2595 | {\@definecounter{#1}\@newctr{#1}[#3]%
2596 | \expandafter\xdef\csname the#1\endcsname{%
2597 | \expandafter\noexpand\csname the#3\endcsname \@prfcountersep
2598 | \@prfcounter{#1}}%
2599 | \global\@namedef{#1}{\@prf{#1}{#2}}%
2600 | \global\@namedef{end#1}{\@endproof}}}
2601 | \def\@ynprf#1#2{%
2602 | \expandafter\@ifdefinable\csname #1\endcsname
2603 | {\@definecounter{#1}%
2604 | \expandafter\xdef\csname the#1\endcsname{\@prfcounter{#1}}%
2605 | \global\@namedef{#1}{\@prf{#1}{#2}}%
2606 | \global\@namedef{end#1}{\@endproof}}}
2607 | \def\@oprf#1[#2]#3{%
2608 | \@ifundefined{c@#2}{\@nocounterr{#2}}%
2609 | {\expandafter\@ifdefinable\csname #1\endcsname
2610 | {\global\@namedef{the#1}{\@nameuse{the#2}}%
2611 | \global\@namedef{#1}{\@prf{#2}{#3}}%
2612 | \global\@namedef{end#1}{\@endproof}}}}
2613 | \def\@prf#1#2{%
2614 | \refstepcounter{#1}%
2615 | \@ifnextchar[{\@yprf{#1}{#2}}{\@xprf{#1}{#2}}}
2616 | \def\@xprf#1#2{%
2617 | \@beginproof{#2}{\csname the#1\endcsname}\ignorespaces}
2618 | \def\@yprf#1#2[#3]{%
2619 | \@opargbeginproof{#2}{\csname the#1\endcsname}{#3}\ignorespaces}
2620 | \def\@prfcounter#1{\noexpand\arabic{#1}}
2621 | \def\@prfcountersep{.}
2622 | \def\@beginproof#1#2{\trivlist\let\baselinestretch\@blstr
2623 | \item[\hskip \labelsep{\scshape #1.}]\rmfamily}
2624 | \def\@opargbeginproof#1#2#3{\trivlist\let\baselinestretch\@blstr
2625 | \item[\hskip \labelsep{\scshape #1\ (#3).}]\rmfamily}
2626 | \def\@endproof{\endtrivlist}
2627 | \newcommand*{\qed}{\hbox{}\hfill$\Box$}
2628 |
2629 | \xspaceaddexceptions{]}
2630 |
2631 | \ABD{\bibsep=0pt}
2632 | %\ifbool{casfinallayout}
2633 | % {%
2634 | \ABD{\gdef\bibfont{\fontsize{8pt}{10pt}\selectfont}%
2635 | \gdef\casbiographyfont{\fontsize{8pt}{10pt}\selectfont}%
2636 | }%
2637 | % }
2638 | % {}
2639 |
2640 | \endinput
2641 |
--------------------------------------------------------------------------------
/cas-dc-template.tex:
--------------------------------------------------------------------------------
1 | \documentclass[a4paper,fleqn]{cas-dc}
2 | %\documentclass[a4paper,fleqn,longmktitle]{cas-dc}
3 | \usepackage[numbers]{natbib}
4 | %\usepackage[authoryear]{natbib}
5 | %\usepackage[authoryear,longnamesfirst]{natbib}
6 |
7 | %%%Author macros
8 | \def\tsc#1{\csdef{#1}{\textsc{\lowercase{#1}}\xspace}}
9 | \tsc{WGM}
10 | \tsc{QE}
11 | %%%
12 |
13 | \begin{document}
14 | \let\WriteBookmarks\relax
15 | \def\floatpagepagefraction{1}
16 | \def\textpagefraction{.001}
17 | \let\printorcid\relax % 可去掉页面下方的ORCID(s)
18 |
19 | % Short title
20 | % \shorttitle{}
21 | \shorttitle{}
22 |
23 | % Short author
24 | % \shortauthors{}
25 | \shortauthors{Ming Xiao et al.}
26 |
27 | %论文标题
28 | \title[mode = title]{This is the title of the paper}
29 |
30 | %作者信息
31 | \author[1]{Ming Xiao}
32 | \author[1]{San Zhang}
33 | \author[2]{Si Li}
34 | \author[2]{Ming Da}
35 | \cormark[1]
36 |
37 | \address[1]{xxx Laboratory, xxx University, Changsha 410073, China} %声明第一单位
38 | \address[2]{xxx Laboratory, xxx University, Changsha 410073, China} %声明第二单位
39 | \cortext[1]{Corresponding author} %声明通讯作者
40 |
41 |
42 | % Here goes the abstract
43 | \begin{abstract}
44 | In this work we demonstrate $a_b$ the formation Y\_1 of a new type of polariton on the interface between a cuprous oxide slab and a polystyrene micro-sphere placed on the slab. The evanescent field of the resonant whispering gallery mode of the micro sphere has a substantial gradient, and therefore effectively couples with the quadrupole $1^S$ excitons in cuprous oxide. This evanescent polariton has a long life-time, which is determined only by its excitonic and component. The polariton lower branch has a well pronounced minimum. This suggests that this excitation is localized and can be utilized for possible. The spatial coherence of the polariton can be improved by assembling the micro-spheres into a linear chain.
45 | \end{abstract}
46 |
47 | % Use if graphical abstract is present
48 | %\begin{graphicalabstract}
49 | %\includegraphics{}
50 | %\end{graphicalabstract}
51 |
52 | % Research highlights
53 | % \begin{highlights}
54 | % \item highlight-1
55 | % \item highlight-2
56 | % \item highlight-3
57 | % \end{highlights}
58 |
59 | % Keywords
60 | % Each keyword is seperated by \sep
61 | \begin{keywords}
62 | keyword-1 \sep
63 | keyword-2 \sep
64 | keyword-3
65 | \end{keywords}
66 |
67 | \maketitle
68 |
69 | % Main text
70 | \section{Section-1}
71 |
72 | Text of section-1 \cite{Fortunato2010}.
73 |
74 | \section{Section-2}
75 |
76 | Text of section-2 \cite{NewmanGirvan2004}.
77 |
78 | \section{Section-3}
79 |
80 | Text of section-3 \cite{Vehlowetal2013}.
81 |
82 |
83 |
84 | %% Loading bibliography style file
85 | %\bibliographystyle{model1-num-names}
86 | \bibliographystyle{cas-model2-names}
87 |
88 | % Loading bibliography database
89 | \bibliography{cas-refs}
90 |
91 | % Biography
92 | % \bio{}
93 | % % Here goes the biography details.
94 | % \endbio
95 |
96 | % \bio{pic1}
97 | % % Here goes the biography details.
98 | % \endbio
99 |
100 | \end{document}
--------------------------------------------------------------------------------
/cas-dc-templates.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/oyoycr/els-cas-templates/420cfa9a16f78ef18857f320fd3ebeefcd30506a/cas-dc-templates.pdf
--------------------------------------------------------------------------------
/cas-dc.cls:
--------------------------------------------------------------------------------
1 | %%
2 | %% This is file `cas-sc.cls'.
3 | %%
4 | %% This file is part of the 'CAS Bundle'.
5 | %% ......................................
6 | %%
7 | %% It may be distributed under the conditions of the LaTeX Project Public
8 | %% License, either version 1.2 of this license or (at your option) any
9 | %% later version. The latest version of this license is in
10 | %% http://www.latex-project.org/lppl.txt
11 | %% and version 1.2 or later is part of all distributions of LaTeX
12 | %% version 1999/12/01 or later.
13 | %%
14 | %% The list of all files belonging to the 'CAS Bundle' is
15 | %% given in the file `manifest.txt'.
16 | %%
17 |
18 | %% $Id: cas-dc.cls 66 2021-05-11 14:17:42Z rishi $
19 |
20 | \def\RCSfile{cas-dc}%
21 | \def\RCSversion{2.3}%
22 | \def\RCSdate{2021/05/11}%
23 | \NeedsTeXFormat{LaTeX2e}[1995/12/01]
24 | \ProvidesClass{\RCSfile}[\RCSdate, \RCSversion: Formatting class
25 | for CAS double column articles]
26 | %
27 | \def\ABD{\AtBeginDocument}
28 | %
29 | % switches
30 | %
31 | \newif\iflongmktitle \longmktitlefalse
32 | \newif\ifdc \global\dctrue
33 | \newif\ifsc \global\scfalse
34 | \newif\ifcasreviewlayout \global\casreviewlayoutfalse
35 | \newif\ifcasfinallayout \global\casfinallayoutfalse
36 |
37 | \newcounter{blind}
38 | \setcounter{blind}{0}
39 |
40 | \def\blstr#1{\gdef\@blstr{#1}}
41 | \def\@blstr{1}
42 | \newdimen\@bls
43 | \@bls=\baselineskip
44 |
45 | \DeclareOption{singleblind}{\setcounter{blind}{1}}
46 | \DeclareOption{doubleblind}{\setcounter{blind}{2}}
47 | \DeclareOption{longmktitle}{\global\longmktitletrue}
48 | \DeclareOption{final}{\global\casfinallayouttrue}
49 | \DeclareOption{review}{\global\casreviewlayouttrue}
50 |
51 | \ExecuteOptions{a4paper,10pt,oneside,fleqn,review}
52 | \DeclareOption*{\PassOptionsToClass{\CurrentOption}{article}}
53 | \ProcessOptions
54 | \LoadClass{article}
55 |
56 | \RequirePackage{graphicx}
57 | \RequirePackage{amsmath,amsfonts,amssymb}
58 | \allowdisplaybreaks
59 |
60 | \RequirePackage{expl3,xparse}
61 | \@ifundefined{regex_match:nnTF}{\RequirePackage{l3regex}}{}
62 | \RequirePackage{etoolbox,balance}
63 | \RequirePackage{booktabs,makecell,multirow,array,colortbl,dcolumn,stfloats}
64 | \RequirePackage{xspace,xstring,footmisc}
65 | \RequirePackage[svgnames,dvipsnames]{xcolor}
66 |
67 | \RequirePackage[colorlinks]{hyperref}
68 | \colorlet{scolor}{black}
69 | \colorlet{hscolor}{DarkSlateGrey}
70 | \hypersetup{%
71 | pdftitle={\csuse{__short_title:}},
72 | pdfauthor={\csuse{__short_authors:}},
73 | pdfcreator={LaTeX3; cas-sc.cls; hyperref.sty},
74 | pdfproducer={pdfTeX;},
75 | linkcolor={hscolor},
76 | urlcolor={hscolor},
77 | citecolor={hscolor},
78 | filecolor={hscolor},
79 | menucolor={hscolor},
80 | }
81 |
82 | \let\comma\@empty
83 | \let\tnotesep\@empty
84 | \let\@title\@empty
85 | %
86 | % Load Common items
87 | %
88 |
89 | \RequirePackage{cas-common}
90 |
91 | %
92 | % Specific to Single Column
93 | %
94 | \ExplSyntaxOn
95 |
96 | \RenewDocumentCommand \maketitle { }
97 | {
98 | \ifbool { usecasgrabsbox }
99 | {
100 | \setcounter{page}{0}
101 | \thispagestyle{empty}
102 | \unvbox\casgrabsbox
103 | } { }
104 | \pagebreak
105 | \ifbool { usecashlsbox }
106 | {
107 | \setcounter{page}{0}
108 | \thispagestyle{empty}
109 | \unvbox\casauhlbox
110 | } { }
111 | \pagebreak
112 | \thispagestyle{first}
113 | \ifbool{longmktitle}
114 | {
115 | \LongMaketitleBox
116 | \ProcessLongTitleBox
117 | }
118 | {
119 | \twocolumn[\MaketitleBox]
120 | \printFirstPageNotes
121 | }
122 | \setcounter{footnote}{\int_use:N \g_stm_fnote_int}
123 | \renewcommand\thefootnote{\arabic{footnote}}
124 | \gdef\@pdfauthor{\infoauthors}
125 | \gdef\@pdfsubject{Complex ~STM ~Content}
126 | }
127 |
128 | %
129 | % Fonts
130 | %
131 | \RequirePackage[T1]{fontenc}
132 |
133 | \file_if_exist:nTF { stix.sty }
134 | {
135 | \file_if_exist:nTF { charis.sty }
136 | {
137 | \RequirePackage[notext]{stix}
138 | \RequirePackage{charis}
139 | }
140 | { \RequirePackage{stix} }
141 | }
142 | {
143 | \iow_term:x { *********************************************************** }
144 | \iow_term:x { ~Stix ~ and ~ Charis~ fonts ~ are ~ not ~ available ~ }
145 | \iow_term:x { ~ in ~TeX~system.~Hence~CMR~ fonts~ are ~ used. }
146 | \iow_term:x { *********************************************************** }
147 | }
148 |
149 | \file_if_exist:nTF { inconsolata.sty }
150 | { \RequirePackage[scaled=.85]{inconsolata} }
151 | { \tex_gdef:D \ttdefault { cmtt } }
152 |
153 |
154 | \ExplSyntaxOff
155 |
156 | %
157 | % Page geometry
158 | %
159 | \usepackage[%
160 | paperwidth=210mm,
161 | paperheight=280mm,
162 | vmargin={19.5mm,18.2mm},
163 | hmargin={18.1mm,18.1mm},
164 | headsep=12pt,
165 | footskip=12pt,
166 | columnsep=18pt
167 | ]{geometry}
168 |
169 |
170 | \endinput
171 |
172 | %
173 | % End of class 'cas-sc'
174 | %
175 |
176 |
--------------------------------------------------------------------------------
/cas-model2-names.bst:
--------------------------------------------------------------------------------
1 | %%
2 | %% This is file `cas-model2-names.bst' (Version 2.3),
3 | %%
4 | %% Copyright 2009-2021 Elsevier Ltd
5 | %%
6 | %% This file is part of the 'Elsarticle Bundle'.
7 | %% ---------------------------------------------
8 | %%
9 | %% It may be distributed under the conditions of the LaTeX Project Public
10 | %% License, either version 1.2 of this license or (at your option) any
11 | %% later version. The latest version of this license is in
12 | %% http://www.latex-project.org/lppl.txt
13 | %% and version 1.2 or later is part of all distributions of LaTeX
14 | %% version 1999/12/01 or later.
15 | %%
16 | %% $Id: cas-model2-names.bst$
17 | %%
18 | %% $URL: https://lenova.river-valley.com/svn/elscastemplates/trunk/cas-model2-names.bst $
19 | %%
20 |
21 | ENTRY
22 | { address
23 | archive
24 | author
25 | booktitle
26 | chapter
27 | collaboration
28 | edition
29 | editor
30 | howpublished
31 | institution
32 | journal
33 | key
34 | month
35 | note
36 | number
37 | organization
38 | pages
39 | publisher
40 | school
41 | series
42 | title
43 | type
44 | volume
45 | year
46 | url
47 | doi
48 | eprint
49 | pubmed
50 | }
51 | {}
52 | { label extra.label sort.label short.list }
53 |
54 | INTEGERS { output.state before.all mid.sentence after.sentence after.block }
55 |
56 | STRINGS { urlprefix doiprefix eprintprefix pubmedprefix }
57 |
58 | FUNCTION {init.web.variables}
59 | {
60 | "\URLprefix " 'urlprefix :=
61 | "\DOIprefix" 'doiprefix :=
62 | "\ArXivprefix " 'eprintprefix :=
63 | "\Pubmedprefix " 'pubmedprefix :=
64 | }
65 |
66 | FUNCTION {init.state.consts}
67 | { #0 'before.all :=
68 | #1 'mid.sentence :=
69 | #2 'after.sentence :=
70 | #3 'after.block :=
71 | }
72 | STRINGS { s t}
73 | FUNCTION {output.comma}
74 | { ", " * write$}
75 |
76 | FUNCTION {output.nonnull}
77 | { 's :=
78 | output.state mid.sentence =
79 | { ". " * write$ }
80 | { output.state after.block =
81 | { add.period$ write$
82 | newline$
83 | "\newblock " write$
84 | }
85 | { output.state before.all =
86 | 'write$
87 | { ", " * write$ }
88 | if$
89 | }
90 | if$
91 | mid.sentence 'output.state :=
92 | }
93 | if$
94 | s
95 | }
96 | FUNCTION {output.commanull}
97 | { 's :=
98 | output.state mid.sentence =
99 | { ", " * write$ }
100 | { output.state after.block =
101 | { ", " * write$
102 | newline$
103 | "\newblock " write$
104 | }
105 | { output.state before.all =
106 | 'write$
107 | { add.period$ " " * write$ }
108 | if$
109 | }
110 | if$
111 | mid.sentence 'output.state :=
112 | }
113 | if$
114 | s
115 | }
116 | FUNCTION {output}
117 | { duplicate$ empty$
118 | 'pop$
119 | 'output.nonnull
120 | if$
121 | }
122 | FUNCTION {output.check}
123 | { 't :=
124 | duplicate$ empty$
125 | { pop$ "empty " t * " in " * cite$ * warning$ }
126 | 'output.nonnull
127 | if$
128 | }
129 | FUNCTION {output.book.check}
130 | { 't :=
131 | duplicate$ empty$
132 | { pop$ "empty " t * " in " * cite$ * warning$ }
133 | 'output.nonnull
134 | if$
135 | }
136 | FUNCTION {fin.entry}
137 | { add.period$
138 | write$
139 | newline$
140 | }
141 |
142 | FUNCTION {new.block}
143 | { output.state before.all =
144 | 'skip$
145 | { after.block 'output.state := }
146 | if$
147 | }
148 | FUNCTION {new.sentence}
149 | { output.state after.block =
150 | 'skip$
151 | { output.state before.all =
152 | 'skip$
153 | { after.sentence 'output.state := }
154 | if$
155 | }
156 | if$
157 | }
158 | FUNCTION {add.blank}
159 | { " " * before.all 'output.state :=
160 | }
161 |
162 | FUNCTION {date.block}
163 | {
164 | new.block
165 | }
166 |
167 | FUNCTION {not}
168 | { { #0 }
169 | { #1 }
170 | if$
171 | }
172 | FUNCTION {and}
173 | { 'skip$
174 | { pop$ #0 }
175 | if$
176 | }
177 | FUNCTION {or}
178 | { { pop$ #1 }
179 | 'skip$
180 | if$
181 | }
182 | FUNCTION {new.block.checkb}
183 | { empty$
184 | swap$ empty$
185 | and
186 | 'skip$
187 | 'new.block
188 | if$
189 | }
190 | FUNCTION {field.or.null}
191 | { duplicate$ empty$
192 | { pop$ "" }
193 | 'skip$
194 | if$
195 | }
196 | FUNCTION {emphasize}
197 | { duplicate$ empty$
198 | { pop$ "" }
199 | { "\textit{" swap$ * "}" * }
200 | if$
201 | }
202 | FUNCTION {tie.or.space.prefix}
203 | { duplicate$ text.length$ #3 <
204 | { "~" }
205 | { " " }
206 | if$
207 | swap$
208 | }
209 |
210 | FUNCTION {capitalize}
211 | { "u" change.case$ "t" change.case$ }
212 |
213 | FUNCTION {space.word}
214 | { " " swap$ * " " * }
215 | % Here are the language-specific definitions for explicit words.
216 | % Each function has a name bbl.xxx where xxx is the English word.
217 | % The language selected here is ENGLISH
218 | FUNCTION {bbl.and}
219 | { "and"}
220 |
221 | FUNCTION {bbl.etal}
222 | { "et~al." }
223 |
224 | FUNCTION {bbl.editors}
225 | { "Eds." }
226 |
227 | FUNCTION {bbl.editor}
228 | { "Ed." }
229 |
230 | FUNCTION {bbl.edby}
231 | { "edited by" }
232 |
233 | FUNCTION {bbl.edition}
234 | { "ed." }
235 |
236 | FUNCTION {bbl.volume}
237 | { "volume" }
238 |
239 | FUNCTION {bbl.of}
240 | { "of" }
241 |
242 | FUNCTION {bbl.number}
243 | { "number" }
244 |
245 | FUNCTION {bbl.nr}
246 | { "no." }
247 |
248 | FUNCTION {bbl.in}
249 | { "in" }
250 |
251 | FUNCTION {bbl.pages}
252 | { "pp." }
253 |
254 | FUNCTION {bbl.page}
255 | { "p." }
256 |
257 | FUNCTION {bbl.chapter}
258 | { "chapter" }
259 |
260 | FUNCTION {bbl.techrep}
261 | { "Technical Report" }
262 |
263 | FUNCTION {bbl.mthesis}
264 | { "Master's thesis" }
265 |
266 | FUNCTION {bbl.phdthesis}
267 | { "Ph.D. thesis" }
268 |
269 | MACRO {jan} {"January"}
270 |
271 | MACRO {feb} {"February"}
272 |
273 | MACRO {mar} {"March"}
274 |
275 | MACRO {apr} {"April"}
276 |
277 | MACRO {may} {"May"}
278 |
279 | MACRO {jun} {"June"}
280 |
281 | MACRO {jul} {"July"}
282 |
283 | MACRO {aug} {"August"}
284 |
285 | MACRO {sep} {"September"}
286 |
287 | MACRO {oct} {"October"}
288 |
289 | MACRO {nov} {"November"}
290 |
291 | MACRO {dec} {"December"}
292 |
293 | MACRO {acmcs} {"ACM Comput. Surv."}
294 |
295 | MACRO {acta} {"Acta Inf."}
296 |
297 | MACRO {cacm} {"Commun. ACM"}
298 |
299 | MACRO {ibmjrd} {"IBM J. Res. Dev."}
300 |
301 | MACRO {ibmsj} {"IBM Syst.~J."}
302 |
303 | MACRO {ieeese} {"IEEE Trans. Software Eng."}
304 |
305 | MACRO {ieeetc} {"IEEE Trans. Comput."}
306 |
307 | MACRO {ieeetcad}
308 | {"IEEE Trans. Comput. Aid. Des."}
309 |
310 | MACRO {ipl} {"Inf. Process. Lett."}
311 |
312 | MACRO {jacm} {"J.~ACM"}
313 |
314 | MACRO {jcss} {"J.~Comput. Syst. Sci."}
315 |
316 | MACRO {scp} {"Sci. Comput. Program."}
317 |
318 | MACRO {sicomp} {"SIAM J. Comput."}
319 |
320 | MACRO {tocs} {"ACM Trans. Comput. Syst."}
321 |
322 | MACRO {tods} {"ACM Trans. Database Syst."}
323 |
324 | MACRO {tog} {"ACM Trans. Graphic."}
325 |
326 | MACRO {toms} {"ACM Trans. Math. Software"}
327 |
328 | MACRO {toois} {"ACM Trans. Office Inf. Syst."}
329 |
330 | MACRO {toplas} {"ACM Trans. Progr. Lang. Syst."}
331 |
332 | MACRO {tcs} {"Theor. Comput. Sci."}
333 |
334 | %% Begin - Added on March 13, 2013
335 |
336 | MACRO {aj} {"Astron. J."}
337 | MACRO {actaa} {"Acta Astron."}
338 | MACRO {araa} {"Annu. Rev. Astron. Astrophys."}
339 | MACRO {apj} {"Astrophys. J."}
340 | MACRO {apjl} {"Astrophys. J. Lett."}
341 | MACRO {apjs} {"Astrophys. J. Suppl. S"}
342 | MACRO {ao} {"Appl. Optics"}
343 | MACRO {apss} {"Astrophys. Space Sci."}
344 | MACRO {aap} {"Astronom. Astrophys."}
345 | MACRO {aapr} {"Astron. Astrophys Rev"}
346 | MACRO {aaps} {"Astron. Astrophys. Sup."}
347 | MACRO {azh} {"Astron. Zh+"}
348 | MACRO {caa} {"Chinese Astron. Astr."}
349 | MACRO {icarus} {"Icarus"}
350 | MACRO {jcap} {"J. Cosmol. Astropart. Phys."}
351 | MACRO {jrasc} {"J. Roy. Astron. Soc. Can."}
352 | MACRO {memras} {"Memoirs of the RAS"}
353 | MACRO {mnras} {"Mon. Not. R. Astron. Soc."}
354 | MACRO {na} {"New Astron."}
355 | MACRO {nar} {"New Astron. Rev."}
356 | MACRO {pra} {"Phys. Rev. A"}
357 | MACRO {prb} {"Phys. Rev. B"}
358 | MACRO {prc} {"Phys. Rev. C"}
359 | MACRO {prd} {"Phys. Rev. D"}
360 | MACRO {pre} {"Phys. Rev. E"}
361 | MACRO {prl} {"Phys. Rev. Lett"}
362 | MACRO {pasa} {"Publ. Astron. Soc. Aust."}
363 | MACRO {pasp} {"Publ. Astron. Soc. Pac."}
364 | MACRO {pasj} {"Publ. Astron. Soc. Jpn."}
365 | MACRO {rmxaa} {"Rev. Mex. Astron. Astr."}
366 | MACRO {rjras} {"Q. J. Roy. Astron. Soc."}
367 | MACRO {skytel} {"Sky Telescope"}
368 | MACRO {solphys} {"Sol. Phys."}
369 | MACRO {sovast} {"Sov. Astron."}
370 | MACRO {ssr} {"Space Sci. Rev."}
371 | MACRO {zap} {"Zeitschrift fuer Astrophysik"}
372 | MACRO {nat} {"Nature"}
373 | MACRO {iaucirc} {"IAU Cirulars"}
374 | MACRO {gca} {"Geochim. Cosmochim. Ac."}
375 | MACRO {grl} {"Geophys. Res. Lett."}
376 | MACRO {jcp} {"J. Chem. Phys."}
377 | MACRO {jgr} {"J. Geophys. Res."}
378 | MACRO {jqsrt} {"J. Quant. Spectrosc. RA"}
379 | MACRO {nphysa} {"Nucl. Phys. A"}
380 | MACRO {physrep} {"Phys. Rep."}
381 | MACRO {physscr} {"Phys. Scrip."}
382 | MACRO {planss} {"Planet. Space Sci."}
383 | MACRO {baas} {"Bull. Aust. Acoust. Soc"}
384 | MACRO {aplett} {"Astrophys. Lett."}
385 | MACRO {procspie} {"Proc. SPIE"}
386 | MACRO {cjaa} {"Chinese J. Astron. Ast."}
387 | MACRO {fcp} {"Fundam. Cosm. Phys."}
388 | MACRO {memsai} {"Mem. Soc. Astron. Ital."}
389 | MACRO {bain} {"Bull. Astron. Inst. Neth., Suppl. Ser."}
390 |
391 | %% End - Added on March 13, 2013
392 |
393 |
394 | FUNCTION {bibinfo.check}
395 | { swap$
396 | duplicate$ missing$
397 | {
398 | pop$ pop$
399 | ""
400 | }
401 | { duplicate$ empty$
402 | {
403 | swap$ pop$
404 | }
405 | { swap$
406 | "\bibinfo{" swap$ * "}{" * swap$ * "}" *
407 | }
408 | if$
409 | }
410 | if$
411 | }
412 | FUNCTION {bibinfo.warn}
413 | { swap$
414 | duplicate$ missing$
415 | {
416 | swap$ "missing " swap$ * " in " * cite$ * warning$ pop$
417 | ""
418 | }
419 | { duplicate$ empty$
420 | {
421 | swap$ "empty " swap$ * " in " * cite$ * warning$
422 | }
423 | { swap$
424 | pop$
425 | }
426 | if$
427 | }
428 | if$
429 | }
430 |
431 | STRINGS { bibinfo}
432 |
433 | INTEGERS { nameptr namesleft numnames }
434 |
435 | FUNCTION {format.names}
436 | { 'bibinfo :=
437 | duplicate$ empty$ 'skip$ {
438 | 's :=
439 | "" 't :=
440 | #1 'nameptr :=
441 | s num.names$ 'numnames :=
442 | numnames 'namesleft :=
443 | { namesleft #0 > }
444 | { s nameptr
445 | "{vv~}{ll}{, jj}{, f{.}.}"
446 | format.name$
447 | bibinfo bibinfo.check
448 | 't :=
449 | nameptr #1 >
450 | {
451 | namesleft #1 >
452 | { ", " * t * }
453 | {
454 | "," *
455 | s nameptr "{ll}" format.name$ duplicate$ "others" =
456 | { 't := }
457 | { pop$ }
458 | if$
459 | t "others" =
460 | {
461 | " " * bbl.etal *
462 | }
463 | { " " * t * }
464 | if$
465 | }
466 | if$
467 | }
468 | 't
469 | if$
470 | nameptr #1 + 'nameptr :=
471 | namesleft #1 - 'namesleft :=
472 | }
473 | while$
474 | } if$
475 | }
476 | FUNCTION {format.names.ed}
477 | {
478 | format.names
479 | }
480 | FUNCTION {format.key}
481 | { empty$
482 | { key field.or.null }
483 | { "" }
484 | if$
485 | }
486 |
487 | FUNCTION {format.authors}
488 | { author "author" format.names
489 | duplicate$ empty$ 'skip$
490 | { collaboration "collaboration" bibinfo.check
491 | duplicate$ empty$ 'skip$
492 | { " (" swap$ * ")" * }
493 | if$
494 | *
495 | }
496 | if$
497 | }
498 |
499 | FUNCTION {get.bbl.editor}
500 | { editor num.names$ #1 > 'bbl.editors 'bbl.editor if$ }
501 |
502 | FUNCTION {format.editors}
503 | { editor "editor" format.names duplicate$ empty$ 'skip$
504 | {
505 | " " *
506 | get.bbl.editor
507 | capitalize
508 | "(" swap$ * ")" *
509 | *
510 | }
511 | if$
512 | }
513 | FUNCTION {format.note}
514 | {
515 | note empty$
516 | { "" }
517 | { note #1 #1 substring$
518 | duplicate$ "{" =
519 | 'skip$
520 | { output.state mid.sentence =
521 | { "l" }
522 | { "u" }
523 | if$
524 | change.case$
525 | }
526 | if$
527 | note #2 global.max$ substring$ * "note" bibinfo.check
528 | }
529 | if$
530 | }
531 |
532 | FUNCTION {format.title}
533 | { title
534 | duplicate$ empty$ 'skip$
535 | { "t" change.case$ }
536 | if$
537 | "title" bibinfo.check
538 | }
539 | FUNCTION {format.full.names}
540 | {'s :=
541 | "" 't :=
542 | #1 'nameptr :=
543 | s num.names$ 'numnames :=
544 | numnames 'namesleft :=
545 | { namesleft #0 > }
546 | { s nameptr
547 | "{vv~}{ll}" format.name$
548 | 't :=
549 | nameptr #1 >
550 | {
551 | namesleft #1 >
552 | { ", " * t * }
553 | {
554 | s nameptr "{ll}" format.name$ duplicate$ "others" =
555 | { 't := }
556 | { pop$ }
557 | if$
558 | t "others" =
559 | {
560 | " " * bbl.etal *
561 | }
562 | {
563 | bbl.and
564 | space.word * t *
565 | }
566 | if$
567 | }
568 | if$
569 | }
570 | 't
571 | if$
572 | nameptr #1 + 'nameptr :=
573 | namesleft #1 - 'namesleft :=
574 | }
575 | while$
576 | }
577 |
578 | FUNCTION {author.editor.key.full}
579 | { author empty$
580 | { editor empty$
581 | { key empty$
582 | { cite$ #1 #3 substring$ }
583 | 'key
584 | if$
585 | }
586 | { editor format.full.names }
587 | if$
588 | }
589 | { author format.full.names }
590 | if$
591 | }
592 |
593 | FUNCTION {author.key.full}
594 | { author empty$
595 | { key empty$
596 | { cite$ #1 #3 substring$ }
597 | 'key
598 | if$
599 | }
600 | { author format.full.names }
601 | if$
602 | }
603 |
604 | FUNCTION {editor.key.full}
605 | { editor empty$
606 | { key empty$
607 | { cite$ #1 #3 substring$ }
608 | 'key
609 | if$
610 | }
611 | { editor format.full.names }
612 | if$
613 | }
614 |
615 | FUNCTION {make.full.names}
616 | { type$ "book" =
617 | type$ "inbook" =
618 | or
619 | 'author.editor.key.full
620 | { type$ "proceedings" =
621 | 'editor.key.full
622 | 'author.key.full
623 | if$
624 | }
625 | if$
626 | }
627 |
628 | FUNCTION {output.bibitem}
629 | { newline$
630 | "\bibitem[{" write$
631 | label write$
632 | ")" make.full.names duplicate$ short.list =
633 | { pop$ }
634 | { * }
635 | if$
636 | "}]{" * write$
637 | cite$ write$
638 | "}" write$
639 | newline$
640 | ""
641 | before.all 'output.state :=
642 | }
643 |
644 | FUNCTION {n.dashify}
645 | {
646 | 't :=
647 | ""
648 | { t empty$ not }
649 | { t #1 #1 substring$ "-" =
650 | { t #1 #2 substring$ "--" = not
651 | { "--" *
652 | t #2 global.max$ substring$ 't :=
653 | }
654 | { { t #1 #1 substring$ "-" = }
655 | { "-" *
656 | t #2 global.max$ substring$ 't :=
657 | }
658 | while$
659 | }
660 | if$
661 | }
662 | { t #1 #1 substring$ *
663 | t #2 global.max$ substring$ 't :=
664 | }
665 | if$
666 | }
667 | while$
668 | }
669 |
670 | FUNCTION {word.in}
671 | { bbl.in %capitalize
672 | ":" *
673 | " " * }
674 |
675 | FUNCTION {format.date}
676 | { year "year" bibinfo.check duplicate$ empty$
677 | {
678 | }
679 | 'skip$
680 | if$
681 | extra.label *
682 | before.all 'output.state :=
683 | ", " swap$ *
684 | }
685 | FUNCTION {format.btitle}
686 | { title "title" bibinfo.check
687 | duplicate$ empty$ 'skip$
688 | {
689 | }
690 | if$
691 | }
692 | FUNCTION {either.or.check}
693 | { empty$
694 | 'pop$
695 | { "can't use both " swap$ * " fields in " * cite$ * warning$ }
696 | if$
697 | }
698 | FUNCTION {format.bvolume}
699 | { volume empty$
700 | { "" }
701 | { bbl.volume volume tie.or.space.prefix
702 | "volume" bibinfo.check * *
703 | series "series" bibinfo.check
704 | duplicate$ empty$ 'pop$
705 | { swap$ bbl.of space.word * swap$
706 | emphasize * }
707 | if$
708 | "volume and number" number either.or.check
709 | }
710 | if$
711 | }
712 | FUNCTION {format.number.series}
713 | { volume empty$
714 | { number empty$
715 | { series field.or.null }
716 | { series empty$
717 | { number "number" bibinfo.check }
718 | { output.state mid.sentence =
719 | { bbl.number }
720 | { bbl.number capitalize }
721 | if$
722 | number tie.or.space.prefix "number" bibinfo.check * *
723 | bbl.in space.word *
724 | series "series" bibinfo.check *
725 | }
726 | if$
727 | }
728 | if$
729 | }
730 | { "" }
731 | if$
732 | }
733 |
734 | FUNCTION {format.edition}
735 | { edition duplicate$ empty$ 'skip$
736 | {
737 | output.state mid.sentence =
738 | { "l" }
739 | { "t" }
740 | if$ change.case$
741 | "edition" bibinfo.check
742 | " " * bbl.edition *
743 | }
744 | if$
745 | }
746 | INTEGERS { multiresult }
747 | FUNCTION {multi.page.check}
748 | { 't :=
749 | #0 'multiresult :=
750 | { multiresult not
751 | t empty$ not
752 | and
753 | }
754 | { t #1 #1 substring$
755 | duplicate$ "-" =
756 | swap$ duplicate$ "," =
757 | swap$ "+" =
758 | or or
759 | { #1 'multiresult := }
760 | { t #2 global.max$ substring$ 't := }
761 | if$
762 | }
763 | while$
764 | multiresult
765 | }
766 | %FUNCTION {format.pages}
767 | %{ pages duplicate$ empty$ 'skip$
768 | % { duplicate$ multi.page.check
769 | % {
770 | % n.dashify
771 | % }
772 | % {
773 | % }
774 | % if$
775 | % "pages" bibinfo.check
776 | % }
777 | % if$
778 | %}
779 |
780 | FUNCTION {format.pages}
781 | { pages duplicate$ empty$ 'skip$
782 | { duplicate$ multi.page.check
783 | {
784 | bbl.pages swap$
785 | n.dashify
786 | }
787 | {
788 | bbl.page swap$
789 | }
790 | if$
791 | tie.or.space.prefix
792 | "pages" bibinfo.check
793 | * *
794 | }
795 | if$
796 | }
797 |
798 | FUNCTION {format.journal.pages}
799 | { pages duplicate$ empty$ 'pop$
800 | { swap$ duplicate$ empty$
801 | { pop$ pop$ format.pages }
802 | {
803 | ", " *
804 | swap$
805 | n.dashify
806 | "pages" bibinfo.check
807 | *
808 | }
809 | if$
810 | }
811 | if$
812 | }
813 | FUNCTION {format.vol.num.pages}
814 | { volume field.or.null
815 | duplicate$ empty$ 'skip$
816 | {
817 | "volume" bibinfo.check
818 | }
819 | if$
820 | }
821 |
822 | FUNCTION {format.chapter.pages}
823 | { chapter empty$
824 | { "" }
825 | { type empty$
826 | { bbl.chapter }
827 | { type "l" change.case$
828 | "type" bibinfo.check
829 | }
830 | if$
831 | chapter tie.or.space.prefix
832 | "chapter" bibinfo.check
833 | * *
834 | }
835 | if$
836 | }
837 |
838 | FUNCTION {format.booktitle}
839 | {
840 | booktitle "booktitle" bibinfo.check
841 | }
842 | FUNCTION {format.in.ed.booktitle}
843 | { format.booktitle duplicate$ empty$ 'skip$
844 | {
845 | editor "editor" format.names.ed duplicate$ empty$ 'pop$
846 | {
847 | " " *
848 | get.bbl.editor
849 | capitalize
850 | "(" swap$ * "), " *
851 | * swap$
852 | * }
853 | if$
854 | word.in swap$ *
855 | }
856 | if$
857 | }
858 | FUNCTION {format.thesis.type}
859 | { type duplicate$ empty$
860 | 'pop$
861 | { swap$ pop$
862 | "t" change.case$ "type" bibinfo.check
863 | }
864 | if$
865 | }
866 | FUNCTION {format.tr.number}
867 | { number "number" bibinfo.check
868 | type duplicate$ empty$
869 | { pop$ bbl.techrep }
870 | 'skip$
871 | if$
872 | "type" bibinfo.check
873 | swap$ duplicate$ empty$
874 | { pop$ "t" change.case$ }
875 | { tie.or.space.prefix * * }
876 | if$
877 | }
878 | FUNCTION {format.article.crossref}
879 | {
880 | word.in
881 | " \cite{" * crossref * "}" *
882 | }
883 | FUNCTION {format.book.crossref}
884 | { volume duplicate$ empty$
885 | { "empty volume in " cite$ * "'s crossref of " * crossref * warning$
886 | pop$ word.in
887 | }
888 | { bbl.volume
889 | capitalize
890 | swap$ tie.or.space.prefix "volume" bibinfo.check * * bbl.of space.word *
891 | }
892 | if$
893 | " \cite{" * crossref * "}" *
894 | }
895 | FUNCTION {format.incoll.inproc.crossref}
896 | {
897 | word.in
898 | " \cite{" * crossref * "}" *
899 | }
900 | FUNCTION {format.org.or.pub}
901 | { 't :=
902 | ""
903 | address empty$ t empty$ and
904 | 'skip$
905 | {
906 | t empty$
907 | { address "address" bibinfo.check *
908 | }
909 | { t *
910 | address empty$
911 | 'skip$
912 | { ", " * address "address" bibinfo.check * }
913 | if$
914 | }
915 | if$
916 | }
917 | if$
918 | }
919 | FUNCTION {format.publisher.address}
920 | { publisher "publisher" bibinfo.check format.org.or.pub
921 | }
922 |
923 | FUNCTION {format.organization.address}
924 | { organization "organization" bibinfo.check format.org.or.pub
925 | }
926 |
927 | FUNCTION {print.url}
928 | {url duplicate$ empty$
929 | { pop$ "" }
930 | { new.sentence
931 | urlprefix "\url{" * swap$ * "}" *
932 | }
933 | if$
934 | }
935 |
936 | FUNCTION {print.doi}
937 | {doi duplicate$ empty$
938 | { pop$ "" }
939 | { new.sentence
940 | doiprefix "\doi{" * swap$ * "}" *
941 | }
942 | if$
943 | }
944 |
945 | FUNCTION {print.eprint}
946 | {eprint duplicate$ empty$
947 | { pop$ "" }
948 | { new.sentence
949 | duplicate$ "\href{http://arxiv.org/abs/" swap$ * "}{\tt arXiv:" * swap$ * "}" * }
950 | if$
951 | }
952 |
953 | FUNCTION {print.pubmed}
954 | {pubmed duplicate$ empty$
955 | { pop$ "" }
956 | { new.sentence
957 | pubmedprefix "\Pubmed{" * swap$ * "}" *
958 | }
959 | if$
960 | }
961 |
962 | FUNCTION {webpage}
963 | { "%Type = Webpage" write$
964 | output.bibitem
965 | format.authors "author" output.check
966 | author format.key output
967 | author empty$
968 | {
969 | format.title "title" output.check
970 | new.block
971 | format.date "year" output.check
972 | date.block
973 | }
974 | {
975 | format.date "year" output.check
976 | date.block
977 | format.title "title" output.check
978 | new.block
979 | }
980 | if$
981 | print.url output
982 | fin.entry
983 | }
984 |
985 |
986 | FUNCTION {article}
987 | { "%Type = Article" write$
988 | output.bibitem
989 | format.authors "author" output.check
990 | author format.key output
991 | format.date "year" output.check
992 | date.block
993 | format.title "title" output.check
994 | new.block
995 | crossref missing$
996 | {
997 | journal
998 | "journal" bibinfo.check
999 | "journal" output.check
1000 | add.blank
1001 | format.vol.num.pages output
1002 | }
1003 | { format.article.crossref output.nonnull
1004 | }
1005 | if$
1006 | format.journal.pages
1007 | new.block
1008 | print.url output
1009 | print.doi output
1010 | print.eprint output
1011 | print.pubmed output
1012 | format.note output
1013 | fin.entry
1014 | }
1015 |
1016 | FUNCTION {book}
1017 | { "%Type = Book" write$
1018 | output.bibitem
1019 | author empty$
1020 | { format.editors "author and editor" output.check
1021 | editor format.key output
1022 | }
1023 | { format.authors output.nonnull
1024 | crossref missing$
1025 | { "author and editor" editor either.or.check }
1026 | 'skip$
1027 | if$
1028 | }
1029 | if$
1030 | format.date "year" output.check
1031 | date.block
1032 | format.btitle "title" output.check
1033 | crossref missing$
1034 | { format.bvolume output
1035 | new.block
1036 | format.number.series output
1037 | format.edition output
1038 | new.sentence
1039 | format.publisher.address output
1040 | }
1041 | {
1042 | new.block
1043 | format.book.crossref output.nonnull
1044 | }
1045 | if$
1046 | new.block
1047 | print.url output
1048 | print.doi output
1049 | print.eprint output
1050 | print.pubmed output
1051 | format.note output
1052 | fin.entry
1053 | }
1054 |
1055 | FUNCTION {booklet}
1056 | { "%Type = Booklet" write$
1057 | output.bibitem
1058 | format.authors output
1059 | author format.key output
1060 | format.date "year" output.check
1061 | date.block
1062 | format.title "title" output.check
1063 | new.block
1064 | howpublished "howpublished" bibinfo.check output
1065 | address "address" bibinfo.check output
1066 | new.block
1067 | print.url output
1068 | print.doi output
1069 | print.eprint output
1070 | print.pubmed output
1071 | format.note output
1072 | fin.entry
1073 | }
1074 |
1075 | FUNCTION {inbook}
1076 | { "%Type = Inbook" write$
1077 | output.bibitem
1078 | author empty$
1079 | { format.editors "author and editor" output.check
1080 | editor format.key output
1081 | }
1082 | { format.authors output.nonnull
1083 | crossref missing$
1084 | { "author and editor" editor either.or.check }
1085 | 'skip$
1086 | if$
1087 | }
1088 | if$
1089 | format.date "year" output.check
1090 | date.block
1091 | format.btitle "title" output.check
1092 | format.edition output
1093 | crossref missing$
1094 | {
1095 | format.publisher.address output
1096 | format.bvolume output
1097 | format.chapter.pages "chapter and pages" output.check
1098 | new.block
1099 | format.number.series output
1100 | new.sentence
1101 | }
1102 | {
1103 | format.chapter.pages "chapter and pages" output.check
1104 | new.block
1105 | format.book.crossref output.nonnull
1106 | }
1107 | if$
1108 | format.pages "pages" output.check
1109 | new.block
1110 | print.url output
1111 | print.doi output
1112 | print.eprint output
1113 | print.pubmed output
1114 | format.note output
1115 | fin.entry
1116 | }
1117 |
1118 | FUNCTION {incollection}
1119 | { "%Type = Incollection" write$
1120 | output.bibitem
1121 | format.authors "author" output.check
1122 | author format.key output
1123 | format.date "year" output.check
1124 | date.block
1125 | format.title "title" output.book.check
1126 | new.sentence
1127 | crossref missing$
1128 | { format.in.ed.booktitle "booktitle" output.book.check
1129 | format.edition output
1130 | format.publisher.address output
1131 | format.bvolume output
1132 | format.number.series output
1133 | format.chapter.pages output
1134 | new.sentence
1135 | }
1136 | { format.incoll.inproc.crossref output.nonnull
1137 | format.chapter.pages output
1138 | }
1139 | if$
1140 | format.pages "pages" output.check
1141 | new.block
1142 | print.url output
1143 | print.doi output
1144 | print.eprint output
1145 | print.pubmed output
1146 | format.note output
1147 | fin.entry
1148 | }
1149 |
1150 | FUNCTION {inproceedings}
1151 | { "%Type = Inproceedings" write$
1152 | output.bibitem
1153 | format.authors "author" output.check
1154 | author format.key output
1155 | format.date "year" output.check
1156 | date.block
1157 | format.title "title" output.book.check
1158 | new.sentence
1159 | crossref missing$
1160 | { format.in.ed.booktitle "booktitle" output.check
1161 | new.sentence
1162 | publisher empty$
1163 | { format.organization.address output }
1164 | { organization "organization" bibinfo.check output
1165 | format.publisher.address output
1166 | }
1167 | if$
1168 | % format.bvolume output
1169 | % format.number.series output
1170 | % format.pages output
1171 | }
1172 | { format.incoll.inproc.crossref output.nonnull
1173 | format.pages output
1174 | }
1175 | if$
1176 | format.pages "pages" output.check
1177 | new.block
1178 | print.url output
1179 | print.doi output
1180 | print.eprint output
1181 | print.pubmed output
1182 | format.note output
1183 | fin.entry
1184 | }
1185 |
1186 | FUNCTION {conference} { inproceedings }
1187 |
1188 | FUNCTION {manual}
1189 | { "%Type = Manual" write$
1190 | output.bibitem
1191 | format.authors output
1192 | author format.key output
1193 | format.date "year" output.check
1194 | date.block
1195 | format.btitle "title" output.check
1196 | format.edition output
1197 | organization address new.block.checkb
1198 | organization "organization" bibinfo.check output
1199 | address "address" bibinfo.check output
1200 | new.block
1201 | print.url output
1202 | print.doi output
1203 | print.eprint output
1204 | print.pubmed output
1205 | format.note output
1206 | fin.entry
1207 | }
1208 |
1209 | FUNCTION {mastersthesis}
1210 | { "%Type = Masterthesis" write$
1211 | output.bibitem
1212 | format.authors "author" output.check
1213 | author format.key output
1214 | format.date "year" output.check
1215 | date.block
1216 | format.btitle
1217 | "title" output.check
1218 | new.block
1219 | bbl.mthesis format.thesis.type output.nonnull
1220 | school "school" bibinfo.warn output
1221 | address "address" bibinfo.check output
1222 | new.block
1223 | print.url output
1224 | print.doi output
1225 | print.eprint output
1226 | print.pubmed output
1227 | format.note output
1228 | fin.entry
1229 | }
1230 |
1231 | FUNCTION {misc}
1232 | { "%Type = Misc" write$
1233 | output.bibitem
1234 | format.authors output
1235 | author format.key output
1236 | format.date "year" output.check
1237 | date.block
1238 | format.title output
1239 | new.block
1240 | howpublished "howpublished" bibinfo.check output
1241 | new.block
1242 | print.url output
1243 | print.doi output
1244 | print.eprint output
1245 | print.pubmed output
1246 | format.note output
1247 | fin.entry
1248 | }
1249 |
1250 | FUNCTION {phdthesis}
1251 | { "%Type = Phdthesis" write$
1252 | output.bibitem
1253 | format.authors "author" output.check
1254 | author format.key output
1255 | format.date "year" output.check
1256 | date.block
1257 | format.btitle
1258 | "title" output.check
1259 | new.block
1260 | bbl.phdthesis format.thesis.type output.nonnull
1261 | school "school" bibinfo.warn output
1262 | address "address" bibinfo.check output
1263 | new.block
1264 | print.url output
1265 | print.doi output
1266 | print.eprint output
1267 | print.pubmed output
1268 | format.note output
1269 | fin.entry
1270 | }
1271 |
1272 | FUNCTION {proceedings}
1273 | { "%Type = Proceedings" write$
1274 | output.bibitem
1275 | format.editors output
1276 | editor format.key output
1277 | format.date "year" output.check
1278 | date.block
1279 | format.btitle "title" output.check
1280 | format.bvolume output
1281 | format.number.series output
1282 | new.sentence
1283 | publisher empty$
1284 | { format.organization.address output }
1285 | { organization "organization" bibinfo.check output
1286 | format.publisher.address output
1287 | }
1288 | if$
1289 | new.block
1290 | print.url output
1291 | print.doi output
1292 | print.eprint output
1293 | print.pubmed output
1294 | format.note output
1295 | fin.entry
1296 | }
1297 |
1298 | FUNCTION {techreport}
1299 | { "%Type = Techreport" write$
1300 | output.bibitem
1301 | format.authors "author" output.check
1302 | author format.key output
1303 | format.date "year" output.check
1304 | date.block
1305 | format.btitle
1306 | "title" output.check
1307 | new.block
1308 | format.tr.number output.nonnull
1309 | institution "institution" bibinfo.warn output
1310 | address "address" bibinfo.check output
1311 | new.block
1312 | print.url output
1313 | print.doi output
1314 | print.eprint output
1315 | print.pubmed output
1316 | format.note output
1317 | fin.entry
1318 | }
1319 |
1320 | FUNCTION {unpublished}
1321 | { "%Type = Unpublished" write$
1322 | output.bibitem
1323 | format.authors "author" output.check
1324 | author format.key output
1325 | format.date "year" output.check
1326 | date.block
1327 | format.title "title" output.check
1328 | new.block
1329 | print.url output
1330 | print.doi output
1331 | print.eprint output
1332 | print.pubmed output
1333 | format.note "note" output.check
1334 | fin.entry
1335 | }
1336 |
1337 | FUNCTION {default.type} { misc }
1338 | READ
1339 | FUNCTION {sortify}
1340 | { purify$
1341 | "l" change.case$
1342 | }
1343 | INTEGERS { len }
1344 | FUNCTION {chop.word}
1345 | { 's :=
1346 | 'len :=
1347 | s #1 len substring$ =
1348 | { s len #1 + global.max$ substring$ }
1349 | 's
1350 | if$
1351 | }
1352 | FUNCTION {format.lab.names}
1353 | { 's :=
1354 | "" 't :=
1355 | s #1 "{vv~}{ll}" format.name$
1356 | s num.names$ duplicate$
1357 | #2 >
1358 | { pop$
1359 | " " * bbl.etal *
1360 | }
1361 | { #2 <
1362 | 'skip$
1363 | { s #2 "{ff }{vv }{ll}{ jj}" format.name$ "others" =
1364 | {
1365 | " " * bbl.etal *
1366 | }
1367 | { bbl.and space.word * s #2 "{vv~}{ll}" format.name$
1368 | * }
1369 | if$
1370 | }
1371 | if$
1372 | }
1373 | if$
1374 | }
1375 |
1376 | FUNCTION {author.key.label}
1377 | { author empty$
1378 | { key empty$
1379 | { cite$ #1 #3 substring$ }
1380 | 'key
1381 | if$
1382 | }
1383 | { author format.lab.names }
1384 | if$
1385 | }
1386 |
1387 | FUNCTION {author.editor.key.label}
1388 | { author empty$
1389 | { editor empty$
1390 | { key empty$
1391 | { cite$ #1 #3 substring$ }
1392 | 'key
1393 | if$
1394 | }
1395 | { editor format.lab.names }
1396 | if$
1397 | }
1398 | { author format.lab.names }
1399 | if$
1400 | }
1401 |
1402 | FUNCTION {editor.key.label}
1403 | { editor empty$
1404 | { key empty$
1405 | { cite$ #1 #3 substring$ }
1406 | 'key
1407 | if$
1408 | }
1409 | { editor format.lab.names }
1410 | if$
1411 | }
1412 |
1413 | FUNCTION {calc.short.authors}
1414 | { type$ "book" =
1415 | type$ "inbook" =
1416 | or
1417 | 'author.editor.key.label
1418 | { type$ "proceedings" =
1419 | 'editor.key.label
1420 | 'author.key.label
1421 | if$
1422 | }
1423 | if$
1424 | 'short.list :=
1425 | }
1426 |
1427 | FUNCTION {calc.label}
1428 | { calc.short.authors
1429 | short.list
1430 | "("
1431 | *
1432 | year duplicate$ empty$
1433 | short.list key field.or.null = or
1434 | { pop$ "" }
1435 | 'skip$
1436 | if$
1437 | *
1438 | 'label :=
1439 | }
1440 |
1441 | FUNCTION {sort.format.names}
1442 | { 's :=
1443 | #1 'nameptr :=
1444 | ""
1445 | s num.names$ 'numnames :=
1446 | numnames 'namesleft :=
1447 | { namesleft #0 > }
1448 | { s nameptr
1449 | "{ll{ }}{ f{ }}{ jj{ }}"
1450 | format.name$ 't :=
1451 | nameptr #1 >
1452 | {
1453 | " " *
1454 | namesleft #1 = t "others" = and
1455 | { "zzzzz" * }
1456 | { t sortify * }
1457 | if$
1458 | }
1459 | { t sortify * }
1460 | if$
1461 | nameptr #1 + 'nameptr :=
1462 | namesleft #1 - 'namesleft :=
1463 | }
1464 | while$
1465 | }
1466 |
1467 | FUNCTION {sort.format.title}
1468 | { 't :=
1469 | "A " #2
1470 | "An " #3
1471 | "The " #4 t chop.word
1472 | chop.word
1473 | chop.word
1474 | sortify
1475 | #1 global.max$ substring$
1476 | }
1477 | FUNCTION {author.sort}
1478 | { author empty$
1479 | { key empty$
1480 | { "to sort, need author or key in " cite$ * warning$
1481 | ""
1482 | }
1483 | { key sortify }
1484 | if$
1485 | }
1486 | { author sort.format.names }
1487 | if$
1488 | }
1489 | FUNCTION {author.editor.sort}
1490 | { author empty$
1491 | { editor empty$
1492 | { key empty$
1493 | { "to sort, need author, editor, or key in " cite$ * warning$
1494 | ""
1495 | }
1496 | { key sortify }
1497 | if$
1498 | }
1499 | { editor sort.format.names }
1500 | if$
1501 | }
1502 | { author sort.format.names }
1503 | if$
1504 | }
1505 | FUNCTION {editor.sort}
1506 | { editor empty$
1507 | { key empty$
1508 | { "to sort, need editor or key in " cite$ * warning$
1509 | ""
1510 | }
1511 | { key sortify }
1512 | if$
1513 | }
1514 | { editor sort.format.names }
1515 | if$
1516 | }
1517 | FUNCTION {presort}
1518 | { calc.label
1519 | label sortify
1520 | " "
1521 | *
1522 | type$ "book" =
1523 | type$ "inbook" =
1524 | or
1525 | 'author.editor.sort
1526 | { type$ "proceedings" =
1527 | 'editor.sort
1528 | 'author.sort
1529 | if$
1530 | }
1531 | if$
1532 | #1 entry.max$ substring$
1533 | 'sort.label :=
1534 | sort.label
1535 | *
1536 | " "
1537 | *
1538 | title field.or.null
1539 | sort.format.title
1540 | *
1541 | #1 entry.max$ substring$
1542 | 'sort.key$ :=
1543 | }
1544 |
1545 | ITERATE {presort}
1546 | SORT
1547 | STRINGS { last.label next.extra }
1548 | INTEGERS { last.extra.num number.label }
1549 | FUNCTION {initialize.extra.label.stuff}
1550 | { #0 int.to.chr$ 'last.label :=
1551 | "" 'next.extra :=
1552 | #0 'last.extra.num :=
1553 | #0 'number.label :=
1554 | }
1555 | FUNCTION {forward.pass}
1556 | { last.label label =
1557 | { last.extra.num #1 + 'last.extra.num :=
1558 | last.extra.num int.to.chr$ 'extra.label :=
1559 | }
1560 | { "a" chr.to.int$ 'last.extra.num :=
1561 | "" 'extra.label :=
1562 | label 'last.label :=
1563 | }
1564 | if$
1565 | number.label #1 + 'number.label :=
1566 | }
1567 | FUNCTION {reverse.pass}
1568 | { next.extra "b" =
1569 | { "a" 'extra.label := }
1570 | 'skip$
1571 | if$
1572 | extra.label 'next.extra :=
1573 | extra.label
1574 | duplicate$ empty$
1575 | 'skip$
1576 | % { "{\natexlab{" swap$ * "}}" * }
1577 | { "" swap$ * "" * }
1578 | if$
1579 | 'extra.label :=
1580 | label extra.label * 'label :=
1581 | }
1582 | EXECUTE {initialize.extra.label.stuff}
1583 | ITERATE {forward.pass}
1584 | REVERSE {reverse.pass}
1585 | FUNCTION {bib.sort.order}
1586 | { sort.label
1587 | " "
1588 | *
1589 | year field.or.null sortify
1590 | *
1591 | " "
1592 | *
1593 | title field.or.null
1594 | sort.format.title
1595 | *
1596 | #1 entry.max$ substring$
1597 | 'sort.key$ :=
1598 | }
1599 | ITERATE {bib.sort.order}
1600 | SORT
1601 | FUNCTION {begin.bib}
1602 | { preamble$ empty$
1603 | 'skip$
1604 | { preamble$ write$ newline$ }
1605 | if$
1606 | "\begin{thebibliography}{" number.label int.to.str$ * "}" *
1607 | write$ newline$
1608 | "\expandafter\ifx\csname natexlab\endcsname\relax\def\natexlab#1{#1}\fi"
1609 | write$ newline$
1610 | "\providecommand{\url}[1]{\texttt{#1}}"
1611 | write$ newline$
1612 | "\providecommand{\href}[2]{#2}"
1613 | write$ newline$
1614 | "\providecommand{\path}[1]{#1}"
1615 | write$ newline$
1616 | "\providecommand{\DOIprefix}{doi:}"
1617 | write$ newline$
1618 | "\providecommand{\ArXivprefix}{arXiv:}"
1619 | write$ newline$
1620 | "\providecommand{\URLprefix}{URL: }"
1621 | write$ newline$
1622 | "\providecommand{\Pubmedprefix}{pmid:}"
1623 | write$ newline$
1624 | "\providecommand{\doi}[1]{\href{http://dx.doi.org/#1}{\path{#1}}}"
1625 | write$ newline$
1626 | "\providecommand{\Pubmed}[1]{\href{pmid:#1}{\path{#1}}}"
1627 | write$ newline$
1628 | "\providecommand{\bibinfo}[2]{#2}"
1629 | write$ newline$
1630 | "\ifx\xfnm\relax \def\xfnm[#1]{\unskip,\space#1}\fi"
1631 | write$ newline$
1632 | }
1633 | EXECUTE {begin.bib}
1634 | EXECUTE {init.state.consts}
1635 | EXECUTE {init.web.variables}
1636 | ITERATE {call.type$}
1637 | FUNCTION {end.bib}
1638 | { newline$
1639 | "\end{thebibliography}" write$ newline$
1640 | }
1641 | EXECUTE {end.bib}
1642 | %% End of customized bst file
1643 | %%
1644 | %% End of file `cas-model2-names.bst'.
1645 |
--------------------------------------------------------------------------------
/cas-refs.bib:
--------------------------------------------------------------------------------
1 | @ARTICLE{Fortunato2010,
2 | author = {Fortunato, S.},
3 | title = {Community detection in graphs},
4 | journal = {Phys. Rep.-Rev. Sec. Phys. Lett.},
5 | volume = {486},
6 | year = {2010},
7 | pages = {75-174}
8 | }
9 |
10 | @ARTICLE{NewmanGirvan2004,
11 | author = {Newman, M. E. J. and Girvan, M.},
12 | title = {Finding and evaluating community structure in networks},
13 | journal = {Phys. Rev. E.},
14 | volume = {69},
15 | year = {2004},
16 | pages = {026113}
17 | }
18 |
19 | @ARTICLE{Vehlowetal2013,
20 | author = {Vehlow, C. and Reinhardt, T. and Weiskopf, D.},
21 | title = {Visualizing Fuzzy Overlapping Communities in Networks},
22 | journal = {IEEE Trans. Vis. Comput. Graph.},
23 | volume = {19},
24 | year = {2013},
25 | pages = {2486-2495}
26 | }
27 |
28 | @ARTICLE{Raghavanetal2007,
29 | author = {Raghavan, U. and Albert, R. and Kumara, S.},
30 | title = {Near linear time algorithm to detect community structures in large-scale networks},
31 | journal = {Phys. Rev E.},
32 | volume = {76},
33 | year = {2007},
34 | pages = {036106}
35 | }
36 |
37 | @ARTICLE{SubeljBajec2011a,
38 | author = {\v{S}ubelj, L. and Bajec, M.},
39 | title = {Robust network community detection using balanced propagation},
40 | journal = {Eur. Phys. J. B.},
41 | volume = {81},
42 | year = {2011},
43 | pages = {353-362}
44 | }
45 |
46 | @ARTICLE{Louetal2013,
47 | author = {Lou, H. and Li, S. and Zhao, Y.},
48 | title = {Detecting community structure using label propagation with weighted coherent neighborhood propinquity},
49 | journal = {Physica A.},
50 | volume = {392},
51 | year = {2013},
52 | pages = {3095-3105}
53 | }
54 |
55 | @ARTICLE{Clausetetal2004,
56 | author = {Clauset, A. and Newman, M. E. J. and Moore, C.},
57 | title = {Finding community structure in very large networks},
58 | journal = {Phys. Rev. E.},
59 | volume = {70},
60 | year = {2004},
61 | pages = {066111}
62 | }
63 |
64 | @ARTICLE{Blondeletal2008,
65 | author = {Blondel, V. D. and Guillaume, J. L. and Lambiotte, R. and Lefebvre, E.},
66 | title = {Fast unfolding of communities in large networks},
67 | journal = {J. Stat. Mech.-Theory Exp.},
68 | volume = {2008},
69 | year = {2008},
70 | pages = {P10008}
71 | }
72 |
73 | @ARTICLE{SobolevskyCampari2014,
74 | author = {Sobolevsky, S. and Campari, R.},
75 | title = {General optimization technique for high-quality community detection in complex networks},
76 | journal = {Phys. Rev. E.},
77 | volume = {90},
78 | year = {2014},
79 | pages = {012811}
80 | }
81 |
82 | @ARTICLE{FortunatoBarthelemy2007,
83 | author = {Fortunato, S. and Barthelemy, M.},
84 | title = {Resolution limit in community detection},
85 | journal = {Proc. Natl. Acad. Sci. U. S. A.},
86 | volume = {104},
87 | year = {2007},
88 | pages = {36-41}
89 | }
90 |
91 | @ARTICLE{SubeljBajec2011b,
92 | author = {\v{S}ubelj, L. and Bajec, M.},
93 | title = {Unfolding communities in large complex networks: Combining defensive and offensive label propagation for core extraction},
94 | journal = {Phys. Rev. E.},
95 | volume = {83},
96 | year = {2011},
97 | pages = {036103}
98 | }
99 |
100 | @ARTICLE{WangLi2013,
101 | author = {Wang, X. and Li, J.},
102 | title = {Detecting communities by the core-vertex and intimate degree in complex networks},
103 | journal = {Physica A.},
104 | volume = {392},
105 | year = {2013},
106 | pages = {2555-2563}
107 | }
108 |
109 | @ARTICLE{Lietal2013,
110 | author = {Li, J. and Wang, X. and Eustace, J.},
111 | title = {Detecting overlapping communities by seed community in weighted complex networks},
112 | journal = {Physica A.},
113 | volume = {392},
114 | year = {2013},
115 | pages = {6125-6134}
116 | }
117 |
118 | @ARTICLE{Fabioetal2013,
119 | author = {Fabio, D. R. and Fabio, D. and Carlo, P.},
120 | title = {Profiling core-periphery network structure by random walkers},
121 | journal = {Sci. Rep.},
122 | volume = {3},
123 | year = {2013},
124 | pages = {1467}
125 | }
126 |
127 | @ARTICLE{Chenetal2013,
128 | author = {Chen, Q. and Wu, T. T. and Fang, M.},
129 | title = {Detecting local community structure in complex networks based on local degree central nodes},
130 | journal = {Physica A.},
131 | volume = {392},
132 | year = {2013},
133 | pages = {529-537}
134 | }
135 |
136 | @ARTICLE{Zhangetal2007,
137 | author = {Zhang, S. and Wang, R. and Zhang, X.},
138 | title = {Identification of overlapping community structure in complex networks using fuzzy c-means clustering},
139 | journal = {Physica A.},
140 | volume = {374},
141 | year = {2007},
142 | pages = {483-490}
143 | }
144 |
145 | @ARTICLE{Nepuszetal2008,
146 | author = {Nepusz, T. and Petr\'oczi, A. and N\'egyessy, L. and Bazs\'o, F.},
147 | title = {Fuzzy communities and the concept of bridgeness in complex networks},
148 | journal = {Phys. Rev. E.},
149 | volume = {77},
150 | year = {2008},
151 | pages = {016107}
152 | }
153 |
154 | @ARTICLE{FabricioLiang2013,
155 | author = {Fabricio, B. and Liang, Z.},
156 | title = {Fuzzy community structure detection by particle competition and cooperation},
157 | journal = {Soft Comput.},
158 | volume = {17},
159 | year = {2013},
160 | pages = {659-673}
161 | }
162 |
163 | @ARTICLE{Sunetal2011,
164 | author = {Sun, P. and Gao, L. and Han, S.},
165 | title = {Identification of overlapping and non-overlapping community structure by fuzzy clustering in complex networks},
166 | journal = {Inf. Sci.},
167 | volume = {181},
168 | year = {2011},
169 | pages = {1060-1071}
170 | }
171 |
172 | @ARTICLE{Wangetal2013,
173 | author = {Wang, W. and Liu, D. and Liu, X. and Pan, L.},
174 | title = {Fuzzy overlapping community detection based on local random walk and multidimensional scaling},
175 | journal = {Physica A.},
176 | volume = {392},
177 | year = {2013},
178 | pages = {6578-6586}
179 | }
180 |
181 | @ARTICLE{Psorakisetal2011,
182 | author = {Psorakis, I. and Roberts, S. and Ebden, M. and Sheldon, B.},
183 | title = {Overlapping community detection using Bayesian non-negative matrix factorization},
184 | journal = {Phys. Rev. E.},
185 | volume = {83},
186 | year = {2011},
187 | pages = {066114}
188 | }
189 |
190 | @CONFERENCE{ZhangYeung2012,
191 | author = {Zhang, Y. and Yeung, D.},
192 | title = {Overlapping Community Detection via Bounded Nonnegative Matrix Tri-Factorization},
193 | booktitle = {In Proc. ACM SIGKDD Conf.},
194 | year = {2012},
195 | pages = {606-614}
196 | }
197 |
198 | @ARTICLE{Liu2010,
199 | author = {Liu, J.},
200 | title = {Fuzzy modularity and fuzzy community structure in networks},
201 | journal = {Eur. Phys. J. B.},
202 | volume = {77},
203 | year = {2010},
204 | pages = {547-557}
205 | }
206 |
207 | @ARTICLE{Havensetal2013,
208 | author = {Havens, T. C. and Bezdek, J. C. and Leckie, C., Ramamohanarao, K. and Palaniswami, M.},
209 | title = {A Soft Modularity Function For Detecting Fuzzy Communities in Social Networks},
210 | journal = {IEEE Trans. Fuzzy Syst.},
211 | volume = {21},
212 | year = {2013},
213 | pages = {1170-1175}
214 | }
215 |
216 | @misc{Newman2013,
217 | author = {Newman, M. E. J.},
218 | title = {Network data},
219 | howpublished = "\url{http://www-personal.umich.edu/~mejn/netdata/}",
220 | year = {2013}
221 | }
222 |
223 | @ARTICLE{SubeljBajec2012,
224 | author = {\v{S}ubelj, L. and Bajec, M.},
225 | title = {Ubiquitousness of link-density and link-pattern communities in real-world networks},
226 | journal = {Eur. Phys. J. B.},
227 | volume = {85},
228 | year = {2012},
229 | pages = {1-11}
230 | }
231 |
232 | @ARTICLE{Lancichinettietal2008,
233 | author = {Lancichinetti, A. and Fortunato, S. and Radicchi, F.},
234 | title = {Benchmark graphs for testing community detection algorithms},
235 | journal = {Phys. Rev. E.},
236 | volume = {78},
237 | year = {2008},
238 | pages = {046110}
239 | }
240 |
241 | @ARTICLE{Liuetal2014,
242 | author = {Liu, W. and Pellegrini, M. and Wang, X.},
243 | title = {Detecting Communities Based on Network Topology},
244 | journal = {Sci. Rep.},
245 | volume = {4},
246 | year = {2014},
247 | pages = {5739}
248 | }
249 |
250 | @ARTICLE{Danonetal2005,
251 | author = {Danon, L. and Diaz-Guilera, A. and Duch, J. and Arenas, A.},
252 | title = {Comparing community structure identification},
253 | journal = {J. Stat. Mech.-Theory Exp.},
254 | volume = {},
255 | year = {2005},
256 | pages = {P09008}
257 | }
258 |
259 | @ARTICLE{Gregory2011,
260 | author = {Gregory, S.},
261 | title = {Fuzzy overlapping communities in networks},
262 | journal = {J. Stat. Mech.-Theory Exp.},
263 | volume = {},
264 | year = {2011},
265 | pages = {P02017}
266 | }
267 |
268 | @ARTICLE{LancichinettiFortunato2009,
269 | author = {Lancichinetti, A. and Fortunato, S.},
270 | title = {Benchmarks for testing community detection algorithms on directed and weighted graphs with overlapping communities},
271 | journal = {Phys. Rev. E.},
272 | volume = {80},
273 | year = {2009},
274 | pages = {016118}
275 | }
276 |
277 | @CONFERENCE{HullermeierRifqi2009,
278 | author = {Hullermeier, E. and Rifqi, M.},
279 | title = {A Fuzzy Variant of the Rand Index for Comparing Clustering Structures},
280 | booktitle = {in Proc. IFSA/EUSFLAT Conf.},
281 | year = {2009},
282 | pages = {1294-1298}
283 | }
284 |
--------------------------------------------------------------------------------
/image.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/oyoycr/els-cas-templates/420cfa9a16f78ef18857f320fd3ebeefcd30506a/image.jpeg
--------------------------------------------------------------------------------
/thumbnails/cas-email.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/oyoycr/els-cas-templates/420cfa9a16f78ef18857f320fd3ebeefcd30506a/thumbnails/cas-email.jpeg
--------------------------------------------------------------------------------
/thumbnails/cas-facebook.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/oyoycr/els-cas-templates/420cfa9a16f78ef18857f320fd3ebeefcd30506a/thumbnails/cas-facebook.jpeg
--------------------------------------------------------------------------------
/thumbnails/cas-gplus.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/oyoycr/els-cas-templates/420cfa9a16f78ef18857f320fd3ebeefcd30506a/thumbnails/cas-gplus.jpeg
--------------------------------------------------------------------------------
/thumbnails/cas-linkedin.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/oyoycr/els-cas-templates/420cfa9a16f78ef18857f320fd3ebeefcd30506a/thumbnails/cas-linkedin.jpeg
--------------------------------------------------------------------------------
/thumbnails/cas-twitter.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/oyoycr/els-cas-templates/420cfa9a16f78ef18857f320fd3ebeefcd30506a/thumbnails/cas-twitter.jpeg
--------------------------------------------------------------------------------
/thumbnails/cas-url.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/oyoycr/els-cas-templates/420cfa9a16f78ef18857f320fd3ebeefcd30506a/thumbnails/cas-url.jpeg
--------------------------------------------------------------------------------