summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/pst-optexp
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2014-11-27 23:12:57 +0000
committerKarl Berry <karl@freefriends.org>2014-11-27 23:12:57 +0000
commite230e4df26ca959893b28b41dc5e4f189b7d5d7c (patch)
tree371c85bfe3aab74a850560e59c99843f6e025f1d /Master/texmf-dist/tex/latex/pst-optexp
parent92dfd63f1480de91bdf82d2ae9fd7a76110f39d7 (diff)
pst-optexp (27nov14)
git-svn-id: svn://tug.org/texlive/trunk@35673 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/pst-optexp')
-rw-r--r--Master/texmf-dist/tex/latex/pst-optexp/pst-optexp.sty194
1 files changed, 192 insertions, 2 deletions
diff --git a/Master/texmf-dist/tex/latex/pst-optexp/pst-optexp.sty b/Master/texmf-dist/tex/latex/pst-optexp/pst-optexp.sty
index c8ff7b8946f..14878a3afea 100644
--- a/Master/texmf-dist/tex/latex/pst-optexp/pst-optexp.sty
+++ b/Master/texmf-dist/tex/latex/pst-optexp/pst-optexp.sty
@@ -9,7 +9,7 @@
%% This is a generated file.
%%
%% Project: pst-optexp
-%% Version: 5.1 (2014/11/19)
+%% Version: 5.2 (2014/11/26)
%%
%% Copyright (C) 2007-2014 by Christoph Bersch <usenet@bersch.net>
%%
@@ -31,7 +31,7 @@
%%
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesPackage{pst-optexp}
- [2014/11/19 v5.1 Optical experimental setups with PSTricks]
+ [2014/11/26 v5.2 Optical experimental setups with PSTricks]
\RequirePackage{ifthen}
\RequirePackage{pstricks}
\RequirePackage{pst-xkey}
@@ -653,6 +653,50 @@
lensradiusleft=1,
lensradiusright=1
}%
+\define@key[psset]{optexp}{asphereheight}{%
+ \pst@checknum{#1}\POE@key@asphereheight
+}%
+\define@key[psset]{optexp}{aspherewidth}{%
+ \pst@checknum{#1}\POE@key@aspherewidth
+}%
+\define@key[psset]{optexp}{asphereradiusleft}{%
+ \pst@checknum{#1}\POE@key@asphereradiusleft
+}%
+\define@key[psset]{optexp}{asphereradiusright}{%
+ \pst@checknum{#1}\POE@key@asphereradiusright
+}%
+\define@key[psset]{optexp}{asphereconstant}{%
+ \pst@checknum{#1}\POE@key@asphereconstant
+}%
+\define@key[psset]{optexp}{aspherecoefficients}{%
+ \pst@expandafter\POE@psset@@aspherecoefficients{#1} {} {} {} {} {}\@nil
+}%
+\def\POE@psset@@aspherecoefficients#1 #2 #3 #4 #5\@nil{%
+ \def\POE@key@asphereAfour{0}%
+ \def\POE@key@asphereAsix{0}%
+ \def\POE@key@asphereAeight{0}%
+ \def\POE@key@asphereAten{0}%
+ \ifx\\#1\\\else
+ \def\POE@key@asphereAfour{#1}%
+ \ifx\\#2\\\else
+ \def\POE@key@asphereAsix{#2}%
+ \ifx\\#3\\\else
+ \def\POE@key@asphereAeight{#3}%
+ \ifx\\#4\\\else
+ \def\POE@key@asphereAten{#4}%
+ \fi
+ \fi
+ \fi
+ \fi
+}%
+\psset[optexp]{%
+ aspherewidth=0,
+ asphereheight=1,
+ asphereconstant=-1,
+ asphereradiusleft=1,
+ aspherecoefficients=0,
+ asphereradiusright=0
+}
\define@key[psset]{optexp}{innerheight}{%
\pst@checknum{#1}\POE@key@innerheight
}
@@ -974,6 +1018,44 @@
\fi
}%
\psset[optexp]{oapmirroraperture=1}
+\define@key[psset]{optexp}{axiconheight}{%
+ \pst@checknum{#1}\POE@key@axiconheight
+}%
+\define@key[psset]{optexp}{axiconwidth}{%
+ \pst@checknum{#1}\POE@key@axiconwidth
+}%
+\define@key[psset]{optexp}{axiconangle}{%
+ \pst@checknum{#1}\POE@key@axiconangle
+}%
+\psset[optexp]{axiconheight=1.5, axiconwidth=0.4, axiconangle=10}
+\define@key[psset]{optexp}{wedgeangles}{%
+ \pst@expandafter\POE@psset@@wedgeangles{#1} {} {} {}\@nil
+}%
+\def\POE@psset@@wedgeangles#1 #2 #3\@nil{%
+ \pst@checknum{#1}\POE@key@wedgeangleleft
+ \ifx\\#2\\%
+ \pst@checknum{#1}\POE@key@wedgeangleright
+ \else
+ \pst@checknum{#2}\POE@key@wedgeangleright
+ \fi
+}%
+\define@key[psset]{optexp}{wedgeangleleft}{%
+ \pst@checknum{#1}\POE@key@wedgeangleleft
+}%
+\define@key[psset]{optexp}{wedgeangleright}{%
+ \pst@checknum{#1}\POE@key@wedgeangleright
+}%
+\define@key[psset]{optexp}{wedgeheight}{%
+ \pst@checknum{#1}\POE@key@wedgeheight
+}%
+\define@key[psset]{optexp}{wedgewidth}{%
+ \pst@checknum{#1}\POE@key@wedgewidth
+}%
+\psset[optexp]{%
+ wedgeangles=0 10,
+ wedgeheight=0.8,
+ wedgewidth=0
+}%
\define@key[psset]{optexp}{optgridcount}{%
\pst@checknum{#1}\POE@key@gratingcount
\PackageWarning{pst-optexp}{%
@@ -3813,6 +3895,7 @@
\fi
}%
\newOptexpDipole{lens}
+\newOptexpDipole{asphericlens}
\newOptexpDipole{pinhole}
\newOptexpDipole{crystal}
\newOptexpDipole{polarization}
@@ -3825,6 +3908,8 @@
\newOptexpDipole{doveprism}
\newOptexpDipole{glanthompson}
\newOptexpDipole{parabolicmirror}{position=end, ref@angle=-90}
+\newOptexpDipole{axicon}
+\newOptexpDipole{optwedge}
\newOptexpTripole{mirror}
\newOptexpTripole[ref@angle=45]{beamsplitter}
\newOptexpTripole{optgrating}
@@ -4489,6 +4574,65 @@
\addto@pscode{closepath 1 setlinejoin end }%
\end@ClosedObj
\ignorespaces}%
+\def\asphericlens@nodes{%
+ \def\POE@asphere##1{%
+ (##1)^2*(1/(\POE@key@asphereradiusleft*(1+sqrt(1-(1+\POE@key@asphereconstant)*(##1)^2/\POE@key@asphereradiusleft^2)))+%
+ (##1)^2*(\POE@key@asphereAfour %
+ + (##1)^2*(\POE@key@asphereAsix %
+ + ((##1)^2*(\POE@key@asphereAeight %
+ + \POE@key@asphereAten*(##1)^2)))))}%
+ \def\POE@arcright##1{%
+ (##1)^2/(\POE@key@asphereradiusright*sqrt(1-(##1)^2/\POE@key@asphereradiusright^2))}%
+ \POE@Verb{%
+ tx@Dict begin
+ /POEasphereleftx0 (\POE@asphere{0.5*\POE@key@asphereheight}) AlgParser cvx exec def
+ /POEasphererightx0
+ \ifdim\POE@key@asphereradiusright pt>0pt
+ (\POE@arcright{0.5*\POE@key@asphereheight}) AlgParser cvx exec
+ \else
+ 0
+ \fi
+ def
+ \POE@key@aspherewidth\space POEasphereleftx0 POEasphererightx0 add sub dup 0 gt {
+ POEasphererightx0 add /POEasphererightx0 exch def
+ } {
+ pop
+ } ifelse
+ end
+ }%
+ \pssavepath[linestyle=none, arrows=-,ArrowInside=-]{\oenode@Path{A}}{%
+ \psparametricplot[algebraic, plotstyle=cspline]%
+ {\POE@key@asphereheight\space -0.5 mul}%
+ {\POE@key@asphereheight\space 0.5 mul}%
+ {\POE@asphere{t}-POEasphereleftx0|t}}%
+ \ifdim\POE@key@asphereradiusright pt>0pt
+ \pssavepath[linestyle=none, arrows=-,ArrowInside=-]{\oenode@Path{B}}{%
+ \psparametricplot[algebraic, plotstyle=cspline]%
+ {\POE@key@asphereheight\space 0.5 mul}%
+ {\POE@key@asphereheight\space -0.5 mul}%
+ {-\POE@arcright{t}+POEasphererightx0|t}}%
+ \fi
+ \newOptexpComp{%
+ {POEasphereleftx0 neg 0} tx@IntersectDict /\PIT@name{\oenode@Path{A}} get 0 0 trans {PathIfc}
+ {POEasphererightx0 0}
+ \ifdim\POE@key@asphereradiusright pt>0pt
+ tx@IntersectDict /\PIT@name{\oenode@Path{B}} get 0 0 trans {PathIfc}
+ \else
+ {0 1} 0 0 trans {PlainIfc}
+ \fi
+ \POE@key@n }%
+}%
+\def\asphericlens@comp{%
+ \pscustom[arrows=-]{%
+ \pstracecurve{\oenode@Path{A}}%
+ \ifdim\POE@key@asphereradiusright pt>0pt
+ \pstracecurve{\oenode@Path{B}}
+ \else
+ \lineto(!POEasphererightx0 \POE@key@asphereheight\space 0.5 mul)
+ \lineto(!POEasphererightx0 \POE@key@asphereheight\space -0.5 mul)
+ \fi
+ \closepath}%
+}%
\def\pinhole@ref{%
\POE@setref{/@@y \POE@key@outerheight\space 0.5 mul def}%
\ignorespaces}%
@@ -5153,6 +5297,52 @@
\def\oapmirror@comp{%
\pstracecurve{\oenode@Path{A}}%
\ignorespaces}%
+\def\axicon@nodes{%
+ \POE@setref{%
+ /@@right \POE@key@axiconheight\space 0.5 mul \POE@key@axiconangle\space dup sin exch cos div mul def
+ @@right \POE@key@axiconwidth\space max 0.5 mul /@@x exch def
+ /@@y \POE@key@axiconheight\space 0.5 mul def
+ /@@right
+ }%
+ \pssavepath[linestyle=none, arrows=-,ArrowInside=-]{\oenode@Path{A}}{%
+ \psline(!\POE@dict{@@x @@right sub @@y})
+ (!\POE@dict{@@x 0})
+ (!\POE@dict{@@x @@right sub @@y neg})
+ }%
+ \newOptexpComp{%
+ {@@x neg 0} {0 1} @@y neg @@y trans {PlainIfc}
+ {@@x 0}
+ tx@IntersectDict /\PIT@name{\oenode@Path{A}} get 0 0 trans {PathIfc}
+ \POE@key@n }%
+}%
+\def\axicon@comp{%
+ \pspolygon[arrows=-]%
+ (!\POE@dict{@@x neg @@y})(!\POE@dict{@@x @@right sub @@y})
+ (!\POE@dict{@@x 0})(!\POE@dict{@@x @@right sub @@y neg})
+ (!\POE@dict{@@x neg @@y neg})
+ %(!\POE@key@axiconwidth\space neg \POE@key@axiconheight\space -0.5 mul)
+ %(!\POE@key@axiconwidth\space neg \POE@key@axiconheight\space 0.5 mul)
+ %(! 0 \POE@key@axiconheight\space 0.5 mul)
+ %(! \POE@key@axiconheight\space 0.5 mul \POE@key@axiconangle\space tan mul 0)
+ %(! 0 \POE@key@axiconheight\space -0.5 mul)
+}%
+\def\optwedge@nodes{%
+ \POE@Verb{%
+ /@@xl \POE@key@wedgeheight\space \POE@key@wedgeangleleft\space tan mul def
+ /@@xr \POE@key@wedgeheight\space \POE@key@wedgeangleright\space tan mul def
+ /@@xa \POE@key@wedgewidth\space @@xl @@xr add sub dup 0 gt {0.5 mul}{pop 0} ifelse def
+ }%
+ \newOptexpComp{%
+ {@@xl @@xa add -0.5 mul 0} {\POE@key@wedgeangleleft\space tan 1} 0 0 trans {PlainIfc}
+ {@@xr @@xa add 0.5 mul 0} {\POE@key@wedgeangleright\space tan -1} 0 0 trans {PlainIfc}
+ \POE@key@n }%
+}%
+\def\optwedge@comp{%
+ \pspolygon[arrows=-](!\POE@dict{@@xa} \POE@key@wedgeheight\space 0.5 mul)
+ (!\POE@dict{@@xa @@xr} add \POE@key@wedgeheight\space -0.5 mul)
+ (!\POE@dict{@@xa @@xl} add neg \POE@key@wedgeheight\space -0.5 mul)
+ (!\POE@dict{@@xa} neg \POE@key@wedgeheight\space 0.5 mul)
+}%
\def\optfiber@ref{%
\POE@setref{%
/@@x \POE@key@fiberloopsep\space\POE@key@fiberloops\space