summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Master/texmf-dist/doc/generic/pst-func/Changes3
-rw-r--r--Master/texmf-dist/doc/generic/pst-func/README18
-rw-r--r--Master/texmf-dist/doc/generic/pst-func/pst-func-doc.bib10
-rw-r--r--Master/texmf-dist/doc/generic/pst-func/pst-func-doc.pdfbin2083694 -> 2138874 bytes
-rw-r--r--Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex88
-rw-r--r--Master/texmf-dist/tex/generic/pst-func/pst-func.tex43
-rw-r--r--Master/texmf-dist/tpm/pst-func.tpm6
7 files changed, 139 insertions, 29 deletions
diff --git a/Master/texmf-dist/doc/generic/pst-func/Changes b/Master/texmf-dist/doc/generic/pst-func/Changes
index 32a3c0e4b09..ea80f23b4c8 100644
--- a/Master/texmf-dist/doc/generic/pst-func/Changes
+++ b/Master/texmf-dist/doc/generic/pst-func/Changes
@@ -1,4 +1,7 @@
..... pst-func.tex
+0.46 2006-09-06 - using the bool key from xkeyval
+ - adding the superellipse function (Lame curve)
+ - uses pstricks-add for algebraic plot
0.45 2006-04-22 make polarplot and algebraic option work
added \psplotImp for plotting implicit
defined functions (experimental)
diff --git a/Master/texmf-dist/doc/generic/pst-func/README b/Master/texmf-dist/doc/generic/pst-func/README
index 0c204bf50f0..7aabf8766ee 100644
--- a/Master/texmf-dist/doc/generic/pst-func/README
+++ b/Master/texmf-dist/doc/generic/pst-func/README
@@ -1,3 +1,21 @@
+pst-func: plotting special mathematical functions:
+-- psPolynomial (with derivations)
+-- psFourier
+-- psBessel
+-- psGauss
+-- psGaussI (integral)
+-- psSi and pssi (integral sin)
+-- psCi (integral cosin)
+-- psIntegral
+-- psCumIntegral
+-- psConv
+-- psBinomial
+-- psBinomialN
+-- psLame (Lam\`e\ Curve -- a superellipse)
+-- psplotImp (plotting implicit defined functions)
+-- psPrintValue
+
+
Save the files pst-func.sty|pro|tex in a directory, which is part of your
local TeX tree. The pro file should go into $TEXMF/dvips/pstricks/
Then do not forget to run texhash to update this tree.
diff --git a/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.bib b/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.bib
index 34f2b8aa705..e9393cce5f0 100644
--- a/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.bib
+++ b/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.bib
@@ -62,7 +62,8 @@
Samarin},
title = {The {\LaTeX} {G}raphics {C}ompanion},
publisher = {{Addison-Wesley Publishing Company}},
- year = {1997},
+ year = {1994},
+ edition = {1.},
address = {Reading, Mass.}
}
@@ -140,3 +141,10 @@
address = {Heidelberg/Hamburg}
}
+@Book{voss:math,
+ author = {Herbert Vo\ss},
+ title = {\LaTeX\ in {M}athematik und {N}aturwissenschaften},
+ publisher = {{Franzis-Verlag}},
+ year = {2006},
+ address = {Poing}
+}
diff --git a/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.pdf b/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.pdf
index 2ec213a7d03..d0e3a216abf 100644
--- a/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.pdf
+++ b/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex b/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex
index 4e3ed6c7a00..3abf4f87a86 100644
--- a/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex
+++ b/Master/texmf-dist/doc/generic/pst-func/pst-func-doc.tex
@@ -1,4 +1,4 @@
-\documentclass[a4paper,12pt]{article}
+\documentclass[a4paper,11pt]{article}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage{pamathx}
@@ -19,8 +19,8 @@
\def\CMD#1{{\ttfamily\textbackslash #1}}
\def\dt{\ensuremath{\,\mathrm{d}t}}
%
-\def\pshlabel{\footnotesize}
-\def\psvlabel{\footnotesize}
+\def\pshlabel#1{\footnotesize#1}
+\def\psvlabel#1{\footnotesize#1}
\usepackage[colorlinks,linktocpage]{hyperref}
%
\begin{document}
@@ -361,10 +361,11 @@ way, at the cost of some reduction in graphics resolution.
\clearpage
\section{\CMD{psGauss} and \CMD{psGaussI}}
The Gauss function is defined as
+%
\begin{align}
f(x) &= \dfrac{1}{\sigma\sqrt{2\pi}}\,e^{-\dfrac{\left(x-\mu\right)^2}{2\sigma{}^2}}
\end{align}
-
+%
\noindent The syntax of the macros is
\begin{verbatim}
\psGauss[options]{xStart}{xEnd}
@@ -403,7 +404,7 @@ and is predefined with 5.
\egroup
-\begin{lstlisting}[xrightmargin=-1cm]
+\begin{lstlisting}[xrightmargin=-2cm]
\psset{yunit=4cm,xunit=3}
\begin{pspicture}(-2,-0.5)(2,1.25)
% \psgrid[griddots=10,gridlabels=0pt, subgriddiv=0]
@@ -506,8 +507,8 @@ step). The precision and the smoothness of the plot depend strongly on these two
\begin{LTXexample}
%\usepackage{pst-math}
\psset{xunit=0.5cm,yunit=2cm}
-\begin{pspicture}[linewidth=1pt](-10,-.5)(10,2)
- \psaxes[dx=1cm,Dx=2]{->}(0,0)(-10,0)(10,2)
+\begin{pspicture}[linewidth=1pt](-10,-.5)(10,1.5)
+ \psaxes[dx=1cm,Dx=2]{->}(0,0)(-10,0)(10,1.5)
\psCumIntegral[plotpoints=200,Simpson=10]{-10}{10}{0 1 GAUSS}
\psIntegral[plotpoints=200,Simpson=10,linecolor=red]{-10}{10}(-4,6){1 GAUSS}
\psIntegral[plotpoints=200,Simpson=100,linecolor=green]{.1}{10}(-3,3){0 exch GAUSS}
@@ -521,8 +522,8 @@ variance is varying from .1 to 10.
\begin{LTXexample}
\psset{xunit=1cm,yunit=4cm}
-\begin{pspicture}[linewidth=1pt](-5,-.2)(5,1.1)
- \psaxes[dx=1cm,Dx=1,Dy=0.5]{->}(0,0)(-5,0)(5,1.1)
+\begin{pspicture}[linewidth=1pt](-5,-.2)(5,0.75)
+ \psaxes[dx=1cm,Dx=1,Dy=0.5]{->}(0,0)(-5,0)(5,0.75)
\psplot[linecolor=blue,plotpoints=200]{-5}{5}{x abs 2 le {0.25}{0} ifelse}
\psplot[linecolor=green,plotpoints=200]{-5}{5}{x abs 1 le {.5}{0} ifelse}
\psConv[plotpoints=100,Simpson=1000,linecolor=red]{-5}{5}(-10,10)%
@@ -569,6 +570,7 @@ for the macro \verb+\psPrintValue+ are valid, too. The only special option is \v
which is a factor (no dimension) and set by default to 1. This option is only valid for
the macro \CMD{psBinomial} and not for the normalized one!
+\psset[pst-func]{barwidth=1}
\begin{LTXexample}[pos=t,preset=\centering]
\psset{xunit=1cm,yunit=5cm}%
\begin{pspicture}(-1,-0.15)(7,0.55)%
@@ -670,8 +672,76 @@ valid vor \CMD{psBinomialN}. The option \verb+showpoints+ is valid if \verb+curv
\end{pspicture*}
\end{LTXexample}
+\clearpage
+
+
+\section{\CMD{psLame} -- Lam\`e\ Curve, a superellipse}
+A superellipse is a curve with Cartesian equation
+%
+\begin{align}
+\left|\frac{x}{a}\right|^r + \left|\frac{y}{b}\right|^r & =1
+\end{align}
+%
+first discussed in 1818 by Gabriel Lamé (1795--1870)%
+\footnote{Lamé worked on a wide variety of different topics.
+His work on differential geometry and contributions to Fermat's Last Theorem
+are important. He proved the theorem for $n = 7$ in 1839.}.
+A superellipse may be described parametrically by
+%
+\begin{align}
+x = a\cdot\cos^{\frac{2}{r}} t\\
+y = b\cdot\sin^{\frac{2}{r}} t
+\end{align}
+%
+Superellipses with $a=b$ are also known as Lamé curves or Lamé ovals and
+the restriction to $r>2$ is sometimes also made. The following
+table summarizes a few special cases. Piet Hein used $\frac{5}{2}$ with a number of different
+$\frac{a}{b}$ ratios for various of his projects. For example, he used $\frac{a}{b}=\frac{6}{5}$
+for Sergels Torg
+(Sergel's Square) in Stockholm, and $\frac{a}{b}=\frac{3}{2}$ for his table.
+
+\begin{center}
+\begin{tabular}{@{}llm{1.5cm}@{}}
+r & curve type & example\\\hline
+$\frac{2}{3}$ & (squashed) astroid
+ & \pspicture(-.5,-.5)(.5,.5)\psLame[radiusA=.5,radiusB=.5]{0.6667}\endpspicture\\
+1 & (squashed) diamond
+ & \pspicture(-.5,-.5)(.5,.5)\psLame[radiusA=.5,radiusB=.5]{1}\endpspicture\\
+2 & ellipse
+ & \pspicture(-.5,-.5)(.5,.5)\psLame[radiusA=.5,radiusB=.5]{2}\endpspicture\\
+$\frac{5}{2}$ & Piet Hein's ,,superellipse``
+ & \pspicture(-.5,-.5)(.5,.5)\psLame[radiusA=.5,radiusB=.5]{2.5}\endpspicture
+\end{tabular}
+\end{center}
+
+If is a rational, then a superellipse is algebraic. However, for irrational,
+it is transcendental. For even integers, the curve becomes closer to a
+rectangle as increases. The syntax of the \verb+\psLame+ macro is:
+
+\begin{verbatim}
+\psLame[settings]{r}
+\end{verbatim}
+
+It is internally ploted as a parametric plot with $0\le\alpha\le360$. Available keywords
+are \verb+radiusA+ and \verb+radiusB+, both are preset to 1, but can have any valid value
+and unit.
+
+\bgroup
+\begin{LTXexample}[pos=t,preset=\centering]
+\definecolorseries{col}{rgb}{last}{red}{blue}
+\resetcolorseries[41]{col}
+\psset{unit=.5}
+\pspicture(-9,-9)(9,9)
+ \psaxes[Dx=2,Dy=2,tickstyle=bottom,ticksize=2pt]{->}(0,0)(-9,-9)(9,9)
+ \multido{\rA=0.2+0.1,\iA=0+1}{40}{%
+ \psLame[radiusA=8,radiusB=7,linecolor={col!![\iA]},linewidth=.5pt]{\rA}}
+\endpspicture
+\end{LTXexample}
+\egroup
\clearpage
+
+
\section{\CMD{psplotImp} -- plotting implicit defined functions}
This macro is still experimental! For a given area, the macro calculates in a
first step row by row for every pixel (1pt) the function $f(x,y)$ and checks for an
diff --git a/Master/texmf-dist/tex/generic/pst-func/pst-func.tex b/Master/texmf-dist/tex/generic/pst-func/pst-func.tex
index efb3b102086..b1a4b5c99f1 100644
--- a/Master/texmf-dist/tex/generic/pst-func/pst-func.tex
+++ b/Master/texmf-dist/tex/generic/pst-func/pst-func.tex
@@ -21,21 +21,18 @@
% Requires PSTricks, pst-node, pst-xkey
\ifx\PSTricksLoaded\endinput\else\input pstricks.tex\fi
\ifx\PSTnodesLoaded\endinput\else\input pst-plot.tex\fi
+\ifx\PSTricksAddLoaded\endinput\else\input pstricks-add.tex\fi
\ifx\PSTXKeyLoaded\endinput\else\input pst-xkey.tex \fi
%
\edef\PstAtCode{\the\catcode`\@} \catcode`\@=11\relax
% interface to the `xkeyval' package
\pst@addfams{pst-func}
-\def\fileversion{0.45}
-\def\filedate{2006/04/22}
+\def\fileversion{0.46}
+\def\filedate{2006/09/06}
\message{`PST-func' v\fileversion, \filedate\space (hv)}
%
\pstheader{pst-func.pro}
-%\pstheader{pstricks-add.pro}
-%\def\pst@funcdict{tx@FuncDict begin }
-%\def\tx@saveCoor{\pst@3ddict saveCoor end }
-%\def\tx@ConvertTo2D{\pst@3ddict ConvertTo2D end }
%
\define@key[psset]{pst-func}{xShift}{\def\psk@xShift{#1}}
\psset[pst-func]{xShift=0}
@@ -70,8 +67,7 @@
\define@key[psset]{pst-func}{coeff}{\def\psk@coeff{#1}}
\define@key[psset]{pst-func}{Abbreviation}{\def\psk@Deriviation{#1}}% compatibility
\define@key[psset]{pst-func}{Derivation}{\def\psk@Derivation{#1}}
-\newif\ifPst@markZeros%
-\define@key[psset]{pst-func}{markZeros}[true]{\@nameuse{Pst@markZeros#1}}
+\define@boolkey[psset]{pst-func}[Pst@]{markZeros}[true]{}
\define@key[psset]{pst-func}{epsZero}{\def\psk@epsZero{#1}}
\define@key[psset]{pst-func}{dZero}{\def\psk@dZero{#1}}
\define@key[psset]{pst-func}{zeroLineTo}{\def\psk@zeroLineTo{#1}}
@@ -385,8 +381,7 @@
\psIntegral[#1]{#2}{#3}(#4,#5){pop pop x #6\space x t neg add #7\space mul}%
}%
%
-\newif\ifPst@printValue%
-\define@key[psset]{pst-func}{printValue}[true]{\@nameuse{Pst@printValue#1}}
+\define@boolkey[psset]{pst-func}[Pst@]{printValue}[true]{}
\define@key[psset]{pst-func}{barwidth}{\def\psFunc@barwidth{#1 }}% a factor, not a dimen
\psset[pst-func]{printValue=false,barwidth=1}
%
@@ -480,12 +475,28 @@
\ignorespaces%
}
%
+% Superellipese / Lamefunction
+\define@key[psset]{pst-func}{radiusA}{\pst@getlength{#1}\pst@radiusA}
+\define@key[psset]{pst-func}{radiusB}{\pst@getlength{#1}\pst@radiusB}
+\psset[pst-func]{radiusA=1,radiusB=1}
+%
+\def\psLame{\pst@object{psLame}}
+\def\psLame@i#1{%
+ \addbefore@par{plotpoints=200}
+ \pst@killglue
+ \begin@SpecialObj
+ \parametricplot{0}{360}{%
+ t cos dup mul 1 #1\space div exp \pst@radiusA \pst@number\psxunit div mul
+ t 90 gt { t 270 lt { neg } if } if
+ t sin dup mul 1 #1\space div exp \pst@radiusB \pst@number\psyunit div mul
+ t 180 gt { neg } if }
+ \end@SpecialObj
+}
+%
% For polar plots
-\newif\ifpolarplot
-\define@key[psset]{pst-func}{polarplot}[true]{\@nameuse{polarplot#1}}
-\newif\ifPst@algebraic%
-\define@key[psset]{pst-func}{algebraic}[true]{\@nameuse{Pst@algebraic#1}}%
-\psset[pst-func]{polarplot=false,algebraic=false}
+%\define@boolkey[psset]{pst-func}[PstAdd@]{polarplot}[true]{}
+%\define@boolkey[psset]{pst-func}[PstAdd@]{algebraic}[true]{}
+%\psset[pst-func]{polarplot=false,algebraic=false}
%
\def\psplotImp{\pst@object{psplotImp}}% 20060420
\def\psplotImp@i(#1,#2)(#3,#4)#5{%
@@ -497,7 +508,7 @@
/xMax #3 def
/yMin #2 def
/yMax #4 def
- \ifpolarplot
+ \ifPst@polarplot
/@PolarAlgPlot (#5) tx@addDict begin AlgParser end cvx def
/Func {
/phi y x atan def
diff --git a/Master/texmf-dist/tpm/pst-func.tpm b/Master/texmf-dist/tpm/pst-func.tpm
index 925a89dc873..8752db2efe0 100644
--- a/Master/texmf-dist/tpm/pst-func.tpm
+++ b/Master/texmf-dist/tpm/pst-func.tpm
@@ -3,7 +3,7 @@
<rdf:Description about="http://texlive.dante.de/texlive/Package/pst-func.zip">
<TPM:Name>pst-func</TPM:Name>
<TPM:Type>Package</TPM:Type>
- <TPM:Date>2006/04/22 08:16:24</TPM:Date>
+ <TPM:Date>2006/09/05 13:56:31</TPM:Date>
<TPM:Version>1.0</TPM:Version>
<TPM:Creator>rahtz</TPM:Creator>
<TPM:Title>
@@ -24,13 +24,13 @@ defined by sigma
<TPM:Author>unknown</TPM:Author>
<TPM:Size>2148208</TPM:Size>
<TPM:Build/>
- <TPM:RunFiles size="26100">
+ <TPM:RunFiles size="26465">
texmf-dist/dvips/pst-func/pst-func.pro
texmf-dist/tex/generic/pst-func/pst-func.tex
texmf-dist/tex/latex/pst-func/pst-func.sty
texmf-dist/tpm/pst-func.tpm
</TPM:RunFiles>
- <TPM:DocFiles size="2122108">
+ <TPM:DocFiles size="2180539">
texmf-dist/doc/generic/pst-func/Changes
texmf-dist/doc/generic/pst-func/README
texmf-dist/doc/generic/pst-func/pst-func-doc.bib