Skip to content

Commit 390790d

Browse files
authored
Add files via upload
Fixed issue relating to the order when nesting derivatives (issues #14).
1 parent 86211ad commit 390790d

File tree

4 files changed

+172
-174
lines changed

4 files changed

+172
-174
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## README for derivative package v1.3 dated 2023-07-26
1+
## README for derivative package v1.31 dated 2023-11-04
22

33
The package provides a set of commands `\NewDerivative`, `\NewDifferential` etc. that can be used to define a derivative or a differential operator, respectively. The package have already defined several derivatives and differentials:
44

derivative.pdf

3.11 KB
Binary file not shown.

derivative.sty

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
\RequirePackage{expl3}[2021/11/07]
2020
\RequirePackage{xparse}[2021/11/07]
2121
\RequirePackage{l3keys2e}
22-
\ProvidesExplPackage{derivative}{2023/07/26}{1.3}{Nice and easy derivatives and differentials for LaTeX}
22+
\ProvidesExplPackage{derivative}{2023/11/04}{1.31}{Nice and easy derivatives and differentials for LaTeX}
2323

2424
\bool_new:N \l__deriv_pkg_italic_bool
2525
\bool_new:N \l__deriv_pkg_upright_bool
@@ -757,15 +757,9 @@
757757
\__deriv_var_bool_seq:cNN { l__deriv_#4_misc_var_clist } \l__deriv_tmpa_seq \l__deriv_var_count_int
758758
\int_set:Nn \l__deriv_tmpa_int { \seq_count:N #2 }
759759

760-
\seq_map_indexed_inline:Nn #2
761-
{
762-
\tl_put_right:Nx \l__deriv_tmpb_tl
763-
{
764-
\exp_not:n {##2}
765-
\int_compare:nNnF {##1} = { \l__deriv_tmpa_int }
766-
{ \__deriv_insert_mskip:nn {#4} { ord_ord } }
767-
}
768-
}
760+
% Temporary store the order argument
761+
\tl_set:Nf \l__deriv_tmpb_tl { \seq_use:Nn #2 { \__deriv_insert_mskip:nn {#4} { ord_ord } } }
762+
769763
\seq_pop_left:NN \l__deriv_tmpa_seq \l__deriv_tmpc_tl
770764
\tl_put_right:Nx #3
771765
{
@@ -775,6 +769,7 @@
775769
\__deriv_show_order:NT \l__deriv_tmpb_tl
776770
{ \__deriv_insert_ord:Nnn \l__deriv_tmpb_tl {#4} { var_ord } }
777771
}
772+
778773
\str_if_eq:cNT { l__deriv_#4_misc_mixed_order_tl } 1
779774
{ \tl_set_eq:cN { l__deriv_#4_misc_mixed_order_tl } \l__deriv_tmpb_tl }
780775
}

0 commit comments

Comments
 (0)