summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/schulmathematik/schulma-physik.sty
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/schulmathematik/schulma-physik.sty')
-rw-r--r--macros/latex/contrib/schulmathematik/schulma-physik.sty172
1 files changed, 172 insertions, 0 deletions
diff --git a/macros/latex/contrib/schulmathematik/schulma-physik.sty b/macros/latex/contrib/schulmathematik/schulma-physik.sty
new file mode 100644
index 0000000000..4191a48084
--- /dev/null
+++ b/macros/latex/contrib/schulmathematik/schulma-physik.sty
@@ -0,0 +1,172 @@
+% schulmathematik bundle: package schulma-physik
+% Version 1.0
+% 16. Februar 2020
+\RequirePackage{xparse}
+\ProvidesExplPackage {schulma-physik} {2020-02-16} {1.0} {Befehle für die Schulphysik}
+
+\RequirePackage [locale=DE] {siunitx}
+\RequirePackage {tikz}
+
+\NewDocumentCommand \Massstab {m m m m}
+ {
+ \ensuremath
+ {
+ \SI {#1} {#2}
+ \; \widehat {=} \;
+ \SI {#3} {#4}
+ }
+ }
+
+\NewDocumentCommand \tSI {m m}
+ {
+ \ensuremath
+ {
+ \group_begin:
+ \textstyle
+ \SI [ per-mode = fraction ] {#1} {#2}
+ \group_end:
+ }
+ }
+
+\NewDocumentCommand \tsi {m}
+ {
+ \ensuremath
+ {
+ \group_begin:
+ \textstyle
+ \si [ per-mode = fraction ] {#1}
+ \group_end:
+ }
+ }
+
+\NewDocumentCommand \Beschl {m}
+ {
+ \tSI{#1}{\m\per\square\s}
+ }
+
+\NewDocumentCommand \Erdb { }
+ {
+ \tSI{9,81}{\m\per\square\s}
+ }
+
+\NewDocumentCommand \Ortsf { }
+ {
+ \tSI{9,81}{\N\per\kg}
+ }
+
+\NewDocumentCommand \Elem { }
+ {
+ \SI{1,60e-19}{\coulomb}
+ }
+
+\NewDocumentCommand \Elekm { }
+ {
+ \SI{9,11e-31}{\kg}
+ }
+
+\NewDocumentCommand \Lichtg { }
+ {
+ \SI{3,00e8}{\m\per\s}
+ }
+
+\NewDocumentCommand \Planck { }
+ {
+ \SI{6,63e-34}{\J.\s}
+ }
+
+\ExplSyntaxOff
+
+\usetikzlibrary{circuits.ee.IEC}
+
+\pgfdeclareshape{doppelbuchse}
+ {%
+ \inheritsavedanchors[from=rectangle ee]%
+ \inheritanchor[from=rectangle ee]{center}%
+ \inheritanchor[from=rectangle ee]{north}%
+ \inheritanchor[from=rectangle ee]{south}%
+ \inheritanchor[from=rectangle ee]{east}%
+ \inheritanchor[from=rectangle ee]{west}%
+ \inheritanchor[from=rectangle ee]{north east}%
+ \inheritanchor[from=rectangle ee]{north west}%
+ \inheritanchor[from=rectangle ee]{south east}%
+ \inheritanchor[from=rectangle ee]{south west}%
+ \inheritanchor[from=rectangle ee]{input}%
+ \inheritanchor[from=rectangle ee]{output}%
+ \inheritanchorborder[from=rectangle ee]%
+ \backgroundpath{
+ \pgf@process{\pgfpointadd{\southwest}{\pgfpoint{\pgfkeysvalueof{/pgf/outer xsep}}{\pgfkeysvalueof{/pgf/outer ysep}}}}%
+ \pgf@xa=\pgf@x \pgf@ya=\pgf@y
+ \pgf@process{\pgfpointadd{\northeast}{\pgfpointscale{-1}{\pgfpoint{\pgfkeysvalueof{/pgf/outer xsep}}{\pgfkeysvalueof{/pgf/outer ysep}}}}}%
+ \pgf@xb=\pgf@x \pgf@yb=\pgf@y
+ \pgfutil@tempdima=\pgf@yb%
+ \advance\pgfutil@tempdima by -\pgf@ya%
+ \pgfutil@tempdima=0.5\pgfutil@tempdima%
+ \advance\pgf@xa by \pgfutil@tempdima%
+ \advance\pgf@xb by -\pgfutil@tempdima%
+ {\pgfpathcircle{\pgfqpoint{\pgf@xa}{0pt}}{\pgfutil@tempdima}}
+ {\pgfpathcircle{\pgfqpoint{\pgf@xb}{0pt}}{\pgfutil@tempdima}}
+ }%
+ }
+
+\tikzset
+ {
+ bulb IEC graphic/.style=
+ {
+ circuit symbol lines,
+ circuit symbol size=width 1.9 height 1.9,
+ shape=generic circle IEC,
+ /pgf/generic circle IEC/before background=
+ {
+ \pgfpathmoveto{\pgfpointpolar{-135}{1pt}}
+ \pgfpathlineto{\pgfpointpolar{45}{1pt}}
+ \pgfpathmoveto{\pgfpointpolar{-45}{1pt}}
+ \pgfpathlineto{\pgfpointpolar{135}{1pt}}
+ \pgfusepathqstroke
+ },
+ transform shape,
+ },
+ capacitor IEC graphic/.style=
+ {
+ circuit symbol lines,
+ circuit symbol size=width 0.8 height 2.4,
+ transform shape,
+ shape=capacitor IEC,
+ },
+ amperemeter graphic/.style=
+ {
+ circuit symbol open,
+ circuit symbol size=width 2 height 2,
+ transform shape,
+ shape=generic circle IEC,
+ info=center:{\sffamily A}
+ },
+ voltmeter graphic/.style=
+ {
+ circuit symbol open,
+ circuit symbol size=width 2 height 2,
+ transform shape,
+ shape=generic circle IEC,
+ info=center:{\sffamily V}
+ },
+ circuit declare symbol=messgeraet,
+ set messgeraet graphic=
+ {
+ circuit symbol open,
+ circuit symbol size=width 2 height 2,
+ transform shape,
+ shape=generic circle IEC,
+ /pgf/generic circle IEC/before background=
+ {
+ \draw[annotation arrow,->] (0.58pt,-0.58pt)--(-0.58pt,0.58pt);
+ }
+ },
+ circuit declare symbol=spannungsquelle,
+ set spannungsquelle graphic=
+ {
+ circuit symbol open,
+ circuit symbol size=width 2.4 height 0.5,
+ transform shape,
+ shape=doppelbuchse,
+ outer sep=0pt
+ },
+ }