summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/skmath
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-12-30 22:14:46 +0000
committerKarl Berry <karl@freefriends.org>2018-12-30 22:14:46 +0000
commit15511bd89c498bd45f96d60182fb2ef8245041ab (patch)
treec6f504180a284a6bef9da8b7dee0d49ea960a541 /Master/texmf-dist/tex/latex/skmath
parent5892a627fcfd12a74574492588a18d1b5ca0c9f1 (diff)
skmath (30dec18)
git-svn-id: svn://tug.org/texlive/trunk@49550 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/skmath')
-rw-r--r--Master/texmf-dist/tex/latex/skmath/skmath.sty34
1 files changed, 32 insertions, 2 deletions
diff --git a/Master/texmf-dist/tex/latex/skmath/skmath.sty b/Master/texmf-dist/tex/latex/skmath/skmath.sty
index 57a8fd6c3b7..e856f324f67 100644
--- a/Master/texmf-dist/tex/latex/skmath/skmath.sty
+++ b/Master/texmf-dist/tex/latex/skmath/skmath.sty
@@ -1,7 +1,7 @@
%% This is file `skmath.sty', generated from `skmath.tex' (key `package').
%% skmath improved math commands
%%
-%% Copyright (C) 2012-2016 by Simon Sigurdhsson <sigurdhsson@gmail.com>
+%% Copyright (C) 2012-2019 by Simon Sigurdhsson <sigurdhsson@gmail.com>
%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3
@@ -20,7 +20,7 @@
\RequirePackage{expl3,l3keys2e,xparse}
\ProvidesExplPackage{skmath}
- {2017/01/08}{0.4b}{improved math commands}
+ {2018/12/29}{0.5}{improved math commands}
\PassOptionsToPackage{intlimits,sumlimits,namelimits}{amsmath}
\RequirePackage{amssymb,mathtools,xfrac}
\msg_new:nnnn{skmath}{undefined-macro}{The~macro~`\token_to_str:N#1'~was~undefined!}
@@ -36,6 +36,9 @@
\cs_gset_nopar:Npn\__skmath_imaginary_unit:n#1{
\msg_critical:nnn{skmath}{undefined-macro}{\__skmath_imaginary_unit:n}
}
+\cs_gset_nopar:Npn\__skmath_total_derivative_d:{
+ \msg_critical:nnn{skmath}{undefined-macro}{\__skmath_total_derivative_d:n}
+}
\keys_define:nn{skmath / internal}{
% More on this:
% * http://en.wikipedia.org/wiki/Typographical_conventions_in_mathematical_formulae
@@ -58,6 +61,10 @@
imaginary-unit / slanted .code:n = { \cs_gset_nopar:Npn\__skmath_imaginary_unit:n##1{{##1}} },
complex-part-symbols .bool_set_inverse:N = \g__skmath_iso_complex_parts_bool,
complex-part-symbols .value_required:n = true,
+ total-derivative-d .choice:,
+ total-derivative-d .value_required:n = true,
+ total-derivative-d / upright .code:n = { \cs_gset_nopar:Npn\__skmath_total_derivative_d:{{\operator@font d}} },
+ total-derivative-d / slanted .code:n = { \cs_gset_nopar:Npn\__skmath_total_derivative_d:{{d}} },
}
\keys_define:nn{skmath}{
commonsets .bool_set:N = \g__skmath_define_common_sets_bool,
@@ -71,6 +78,7 @@
natural-log = upright,
imaginary-unit = upright,
complex-part-symbols = false,
+ total-derivative-d = upright,
},
notation / german .meta:nn = {skmath / internal}{
integral-d = upright,
@@ -78,6 +86,7 @@
natural-log = slanted, %???
imaginary-unit = slanted, %???
complex-part-symbols = true, %???
+ total-derivative-d = upright, %???
},
notation / english .meta:nn = {skmath / internal}{
integral-d = slanted,
@@ -85,6 +94,7 @@
natural-log = slanted, %???
imaginary-unit = slanted, %???
complex-part-symbols = true, %???
+ total-derivative-d = slanted, %???
},
notation / legacy .meta:nn = {skmath / internal}{
integral-d = upright,
@@ -92,6 +102,7 @@
natural-log = slanted,
imaginary-unit = slanted,
complex-part-symbols = true,
+ total-derivative-d = slanted,
},
% Possibly more style sets... ?
notation .initial:n = legacy, % Or is it? Perhaps a legacy option is required.
@@ -231,6 +242,8 @@
{\ensuremath{\__skmath_log:\__skmath_parens:n{#2}}}
{\ensuremath{\__skmath_log:\c_math_subscript_token{#1}\__skmath_parens:n{#2}}}%
}
+ \DeclareDocumentCommand\ee{}{\ensuremath{\__skmath_natural_log_e:}}
+
\RenewDocumentCommand\exp{sm}{\ensuremath{
\IfBooleanTF{#1}{
\__skmath_exp:\__skmath_parens:n{#2}
@@ -369,6 +382,18 @@
\__skmath_pd_subscript_vars:n{#2}
}
}
+\cs_new_nopar:Npn\__skmath_td_fraction:nn#1#2{
+ \frac{
+ \__skmath_total_derivative_d:
+ \__skmath_pd_if_vars_sum_above_one:nT{#2}{
+ \c_math_superscript_token{\__skmath_pd_vars_sum:n{#2}}
+ }
+ {#1}
+ }{
+ \__skmath_total_derivative_d:
+ #2
+ }
+}
\AtBeginDocument{%
\DeclareDocumentCommand\bar{m}{%
\ensuremath{\mkern 1.5mu\overline{\mkern-1.5mu{#1}\mkern-1.5mu}\mkern 1.5mu}}
@@ -379,6 +404,11 @@
{\__skmath_pd_fraction:nn{#2}{#3}}
}
}
+\DeclareDocumentCommand\td{mm}{
+ \ensuremath{
+ \__skmath_td_fraction:nn{#1}{#2}
+ }
+}
\DeclareDocumentCommand\d{m}{\ensuremath{\,\__skmath_integral_d: #1%
\peek_meaning_ignore_spaces:NT\d{\!}}}
}