texlive[60911] Master/texmf-dist: pst-func (31oct21)

commits+karl at tug.org commits+karl at tug.org
Sun Oct 31 22:08:14 CET 2021


Revision: 60911
          http://tug.org/svn/texlive?view=revision&revision=60911
Author:   karl
Date:     2021-10-31 22:08:14 +0100 (Sun, 31 Oct 2021)
Log Message:
-----------
pst-func (31oct21)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/generic/pst-func/Changes
    trunk/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.pdf
    trunk/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex
    trunk/Master/texmf-dist/dvips/pst-func/pst-func.pro
    trunk/Master/texmf-dist/tex/generic/pst-func/pst-func.tex
    trunk/Master/texmf-dist/tex/latex/pst-func/pst-func.sty

Modified: trunk/Master/texmf-dist/doc/generic/pst-func/Changes
===================================================================
--- trunk/Master/texmf-dist/doc/generic/pst-func/Changes	2021-10-31 21:07:56 UTC (rev 60910)
+++ trunk/Master/texmf-dist/doc/generic/pst-func/Changes	2021-10-31 21:08:14 UTC (rev 60911)
@@ -1,4 +1,5 @@
 ..... pst-func.tex
+0.98  2021-10-30  - fix for Gini coefficiant
 0.97  2021-10-29  - fix and extension for \psLorenz curve
 0.96  2021-04-06  - added start/endAngle for \psLame
 0.95  2020-06-07  - another two more polynomial functions
@@ -117,6 +118,7 @@
 
 
 ..... pst-func.pro
+0.18  2021-10-30  - added arraysum and arrayprod
 0.17  2018-12-13  - allow algebraic mode for Simpson
 0.16  2018-11-15  - new algorithm for Si/si/Ci/ci
 0.15  2013-06-10  - fix bug with wrong arrow in psBezier#

Modified: trunk/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex
===================================================================
--- trunk/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex	2021-10-31 21:07:56 UTC (rev 60910)
+++ trunk/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex	2021-10-31 21:08:14 UTC (rev 60911)
@@ -2169,6 +2169,21 @@
 \endpsgraph
 \end{LTXexample}
 
+
+\begin{LTXexample}[pos=t,preset=\centering]
+\psset{lly=-13mm,llx=-5mm}
+\psgraph[Dx=0.2,Dy=0.2,axesstyle=frame](0,0)(1,1){6cm}{6cm}
+\psline[linestyle=dashed](1,1)
+\psLorenz[Gini,linecolor=red,linewidth=1.5pt]<.2 .2 .2 .2 .2>{.1 .1 .1 .35 .35 } 
+\psLorenz[Gini,linecolor=blue,linestyle=dashed,linewidth=1.5pt]{.1 .1 .1 .35 .35 } 
+\endpsgraph
+\end{LTXexample}
+
+
+
+
+
+
 \clearpage
 \section{\nxLcs{psLame} -- Lam\'e Curve, a superellipse}
 A superellipse is a curve with Cartesian equation

Modified: trunk/Master/texmf-dist/dvips/pst-func/pst-func.pro
===================================================================
--- trunk/Master/texmf-dist/dvips/pst-func/pst-func.pro	2021-10-31 21:07:56 UTC (rev 60910)
+++ trunk/Master/texmf-dist/dvips/pst-func/pst-func.pro	2021-10-31 21:08:14 UTC (rev 60911)
@@ -16,7 +16,7 @@
 %%   `pst-func' is a PSTricks package to plot special math functions
 %%
 %%
-%% version 0.17 / 2018-12-13  Herbert Voss
+%% version 0.18 / 2021-10-30  Herbert Voss
 %
 /tx at FuncDict 100 dict def
 tx at FuncDict begin

Modified: trunk/Master/texmf-dist/tex/generic/pst-func/pst-func.tex
===================================================================
--- trunk/Master/texmf-dist/tex/generic/pst-func/pst-func.tex	2021-10-31 21:07:56 UTC (rev 60910)
+++ trunk/Master/texmf-dist/tex/generic/pst-func/pst-func.tex	2021-10-31 21:08:14 UTC (rev 60911)
@@ -1,4 +1,4 @@
-%% $Id: pst-func.tex 306 2021-10-29 14:48:08Z herbert $
+%% $Id: pst-func.tex 308 2021-10-30 14:11:45Z herbert $
 %%
 %% This is file `pst-func.tex',
 %%
@@ -31,8 +31,8 @@
 % interface to the `xkeyval' package
 \pst at addfams{pst-func}
 %
-\def\fileversion{0.97}
-\def\filedate{2021/10/29}
+\def\fileversion{0.98}
+\def\filedate{2021/10/30}
 \message{`PST-func' v\fileversion, \filedate\space (hv)}
 %
 \pstheader{pst-func.pro}
@@ -1326,70 +1326,71 @@
     /Coors [xOld dx sub scx 0] def                % speichern der Koordinaten f\"{u}r den Spline
 %%----------------------------------------------------------------------------------------------------------------------------------------------------------------
 %%-------------------- Code, der \"{u}ber den Logarithmus arbeitet von Manuel Luque ---------------------------------------------
-                     /SumLog {%                                                                               log(1) + log(2) + ... + log(n)   =  log(n!)
-                                        1 dict begin %                                                         Erwartet die Eingabe eines Wertes, n\"{a}mlich bis zu welchem Wert addiert werden soll ---> n
-                                        /nV exch def %                                                       der \"{u}bergebene Wert wird in nV abgespeichert
-                                        /iV 1 def %                                                               Startwert ist  iV=1
-                                        0 nV { iV log add /iV iV 1 add def } repeat %  0 + log(1) + log(2) + ... + log(n)   Die Null ist dazu n\"{o}tig um die erste Addition machen zu k\"{o}nnen
-                                        end
-                                     } def
-                /binomial_comb{ %                                                                      log(N!) - log(k!) - log((n-k)!)    =  log[N!/(k!*(n-k)!)]
-                                                  2 dict begin
-                                                  /nV exch def
-                                                  /NV exch def
-                                                  NV SumLog nV SumLog sub
-                                                  NV nV sub SumLog sub
-                                                end
-                                              } def
-                /PnN {
-                              3 dict begin
-                              /pV exch def
-                              /nV exch def
-                              /NV exch def
-                              10
-                              NV nV binomial_comb
-                              nV pV log mul
-                              NV nV sub 1 pV sub log mul add add
-                              exp
-       end
-                             } def
+    /SumLog {%                        log(1) + log(2) + ... + log(n)   =  log(n!)
+      2 dict begin %                  Erwartet die Eingabe eines Wertes, n\"{a}mlich bis zu welchem Wert addiert werden soll ---> n
+      /nV exch def %                  der \"{u}bergebene Wert wird in nV abgespeichert
+      /iV 1 def %                     Startwert ist  iV=1
+      0 nV { iV log add /iV iV 1 add def } repeat %  0 + log(1) + log(2) + ... + log(n)   
+      %Die Null ist dazu n\"{o}tig um die erste Addition machen zu k\"{o}nnen
+      end
+    } def
+    /binomial_comb{ %                 log(N!) - log(k!) - log((n-k)!)    =  log[N!/(k!*(n-k)!)]
+      2 dict begin
+      /nV exch def
+      /NV exch def
+      NV SumLog nV SumLog sub
+      NV nV sub SumLog sub
+      end
+    } def
+    /PnN {
+      3 dict begin
+      /pV exch def
+      /nV exch def
+      /NV exch def
+      10
+      NV nV binomial_comb
+      nV pV log mul
+      NV nV sub 1 pV sub log mul add add
+      exp
+      end
+    } def
 %%------------------------------------------------------------------------------------------------
 %%------------------------------------------------------------------------------------------------
 %------------------------------- 3 Punkte um die Kurve links auf Null zu bringen mit dem weiter oben gew\"{a}hlten Startwert sind es also 4 ------------
-         /x -2 dx add def
-         /y 0 def		
-         x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
-         /x  -0.65 dx add def
-         /y N 0 p PnN 10 -1.3 exp mul def		
-         x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
-         /x  -0.375 dx add def
-         /y N 0 p PnN 3 div def		
-         x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
+    /x -2 dx add def
+    /y 0 def		
+    x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
+    /x  -0.65 dx add def
+    /y N 0 p PnN 10 -1.3 exp mul def		
+    x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
+    /x  -0.375 dx add def
+    /y N 0 p PnN 3 div def		
+    x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
 %----------------------------  Ende der 3 Punkte und Beginn eigentlicher Code ----------------
-                               0 1 N {%            % Schleife geht von 0 bis N in 1-er Schritten
-                                             /k exch def       % save loop variable
-                                             N k p PnN /Y exch def
-                                             /x k dx add def
-                                             /y Y def		
-                                             x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
-                                            /xOld x def
-                                          } for
+    0 1 N {%            % Schleife geht von 0 bis N in 1-er Schritten
+      /k exch def       % save loop variable
+      N k p PnN /Y exch def
+      /x k dx add def
+      /y Y def		
+      x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
+      /xOld x def
+    } for
 %--------------------------- Ende des eigentlichen Codes und Beginn von  ---
 %------------------------------- 4 Punkte um die Kurve rechts auf Null zu bringen -----------
-         /x N 0.375 add dx add def
-         /y Y 3 div def		
-         x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
-         /x N 0.65 add dx add def
-         /y Y 10 -1.3 exp mul def		
-         x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
-         /x N 2 add dx add def
-         /y 0 def		
-         x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
-         /x N 3 add dx add def
-         /y 0 def		
-         x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
+    /x N 0.375 add dx add def
+    /y Y 3 div def		
+    x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
+    /x N 0.65 add dx add def
+    /y Y 10 -1.3 exp mul def		
+    x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
+    /x N 2 add dx add def
+    /y 0 def		
+    x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
+    /x N 3 add dx add def
+    /y 0 def		
+    x dx sub scx y scy Coors aload length 2 add array astore /Coors exch def
 %----------------------------  Ende der 4 Punkte und Laden der Koordinaten des arrays ; L\"{o}schen (pop) von showpoints??----------------------
-  [ xEnd 1 add 0 Coors aload pop % showpoints on top of the stack
+    [ xEnd 1 add 0 Coors aload pop % showpoints on top of the stack
    }%
 \endplot at cspline
 \use at pscode
@@ -1610,7 +1611,9 @@
     Yval arraySum /Ysum ED
     Yval { Ysum div } forall nVal array astore /YvalRel ED %  Pred dist
     \if$#1$
-      [ 1 1 nVal { nVal div } for ] dup /XvalRel ED /XvalRelCum ED
+      /temp {1 nVal div} bind def
+      [ nVal { temp } repeat ] /XvalRel ED
+      [ 1 1 nVal { nVal div } for ] /XvalRelCum ED
       YvalRel bubblesort /YvalRel ED      
     \else
       [ #1 ] /Xval ED

Modified: trunk/Master/texmf-dist/tex/latex/pst-func/pst-func.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/pst-func/pst-func.sty	2021-10-31 21:07:56 UTC (rev 60910)
+++ trunk/Master/texmf-dist/tex/latex/pst-func/pst-func.sty	2021-10-31 21:08:14 UTC (rev 60911)
@@ -1,5 +1,5 @@
 \RequirePackage{pstricks}
-\ProvidesPackage{pst-func}[2018/12/13 package wrapper for pst-func.tex (hv)]
+\ProvidesPackage{pst-func}[2021/10/30 package wrapper for pst-func.tex (hv)]
 \RequirePackage{pst-plot}
 \RequirePackage{pst-math}
 \RequirePackage{pst-tools}
@@ -10,7 +10,7 @@
 \ProvidesFile{pst-func.tex}
   [\filedate\space v\fileversion\space `PST-func' (hv)]
 \IfFileExists{pst-func.pro}{%
-  \ProvidesFile{pst-func.pro}[2018/12/13 v. 0.17,  PostScript prologue file (hv)]
+  \ProvidesFile{pst-func.pro}[2021/10/30 v. 0.18,  PostScript prologue file (hv)]
 \@addtofilelist{pst-func.pro}}{}%
 \endinput
-%% $Id: pst-func.sty 306 2021-10-29 14:48:08Z herbert $
+%% $Id: pst-func.sty 308 2021-10-30 14:11:45Z herbert $



More information about the tex-live-commits mailing list.