aboutsummaryrefslogtreecommitdiffstats
path: root/vorlesungen/slides/7/images
diff options
context:
space:
mode:
authorAndreas Müller <andreas.mueller@ost.ch>2021-05-06 17:57:06 +0200
committerAndreas Müller <andreas.mueller@ost.ch>2021-05-06 17:57:06 +0200
commita90d54e578b7d309ba680d5fd5f6c8721b082096 (patch)
tree49bd3c1f686aa7035cc513d56aad7733efb3c111 /vorlesungen/slides/7/images
parentadd slide (diff)
downloadSeminarMatrizen-a90d54e578b7d309ba680d5fd5f6c8721b082096.tar.gz
SeminarMatrizen-a90d54e578b7d309ba680d5fd5f6c8721b082096.zip
new slide
Diffstat (limited to '')
-rw-r--r--vorlesungen/slides/7/images/Makefile12
-rw-r--r--vorlesungen/slides/7/images/interpolation.ini8
-rw-r--r--vorlesungen/slides/7/images/interpolation.m54
-rw-r--r--vorlesungen/slides/7/images/interpolation.pov10
-rw-r--r--vorlesungen/slides/7/images/test.pov7
5 files changed, 90 insertions, 1 deletions
diff --git a/vorlesungen/slides/7/images/Makefile b/vorlesungen/slides/7/images/Makefile
index cc67c8a..6f99bc3 100644
--- a/vorlesungen/slides/7/images/Makefile
+++ b/vorlesungen/slides/7/images/Makefile
@@ -3,7 +3,7 @@
#
# (c) 2021 Prof Dr Andreas Müller, OST Ostschweizer Fachhochschule
-all: rodriguez.jpg
+all: rodriguez.jpg test.png
rodriguez.png: rodriguez.pov
povray +A0.1 -W1920 -H1080 -Orodriguez.png rodriguez.pov
@@ -16,4 +16,14 @@ commutator: commutator.ini commutator.pov common.inc
jpg:
for f in c/c*.png; do convert $${f} c/`basename $${f} .png`.jpg; done
+dreibein/timestamp: interpolation.m
+ octave interpolation.m
+ touch dreibein/timestamp
+test.png: test.pov drehung.inc dreibein/d025.inc dreibein/timestamp
+ povray +A0.1 -W1080 -H1080 -Otest.png test.pov
+
+dreibein/d025.inc: dreibein/timestamp
+
+animation:
+ povray +A0.1 -W1080 -H1080 -Ointerpolation/i.png interpolation.ini
diff --git a/vorlesungen/slides/7/images/interpolation.ini b/vorlesungen/slides/7/images/interpolation.ini
new file mode 100644
index 0000000..f07c079
--- /dev/null
+++ b/vorlesungen/slides/7/images/interpolation.ini
@@ -0,0 +1,8 @@
+Input_File_Name=interpolation.pov
+Initial_Frame=0
+Final_Frame=50
+Initial_Clock=0
+Final_Clock=50
+Cyclic_Animation=off
+Pause_when_Done=off
+
diff --git a/vorlesungen/slides/7/images/interpolation.m b/vorlesungen/slides/7/images/interpolation.m
new file mode 100644
index 0000000..31554e8
--- /dev/null
+++ b/vorlesungen/slides/7/images/interpolation.m
@@ -0,0 +1,54 @@
+#
+# interpolation.m
+#
+# (c) 2021 Prof Dr Andreas Müller, OST Ostschweizer Fachhochschule
+#
+global N;
+N = 50;
+global A;
+global B;
+
+A = (pi / 2) * [
+ 0, 0, 0;
+ 0, 0, -1;
+ 0, 1, 0
+];
+g0 = expm(A)
+
+B = (pi / 2) * [
+ 0, 0, 1;
+ 0, 0, 0;
+ -1, 0, 0
+];
+g1 = expm(B)
+
+function retval = g(t)
+ global A;
+ global B;
+ retval = expm((1-t)*A+t*B);
+endfunction
+
+function dreibein(fn, M, funktion)
+ fprintf(fn, "%s(<%.4f,%.4f,%.4f>, <%.4f,%.4f,%.4f>, <%.4f,%.4f,%.4f>)\n",
+ funktion,
+ M(1,1), M(3,1), M(2,1),
+ M(1,2), M(3,2), M(2,2),
+ M(1,3), M(3,3), M(2,3));
+endfunction
+
+G = g1 * inverse(g0);
+[V, lambda] = eig(G);
+H = real(V(:,3));
+
+D = logm(g1*inverse(g0));
+
+for i = (0:N)
+ filename = sprintf("dreibein/d%03d.inc", i);
+ fn = fopen(filename, "w");
+ t = i/N;
+ dreibein(fn, g(t), "quadrant");
+ dreibein(fn, expm(t*D)*g0, "drehung");
+ fprintf(fn, "achse(<%.4f,%.4f,%.4f>)\n", H(1,1), H(3,1), H(2,1));
+ fclose(fn);
+endfor
+
diff --git a/vorlesungen/slides/7/images/interpolation.pov b/vorlesungen/slides/7/images/interpolation.pov
new file mode 100644
index 0000000..71e0257
--- /dev/null
+++ b/vorlesungen/slides/7/images/interpolation.pov
@@ -0,0 +1,10 @@
+//
+// commutator.pov
+//
+// (c) 2021 Prof Dr Andreas Müller, OST Ostschweizer Fachhochschule
+//
+#include "drehung.inc"
+
+#declare filename = concat("dreibein/d", str(clock, -3, 0), ".inc");
+#include filename
+
diff --git a/vorlesungen/slides/7/images/test.pov b/vorlesungen/slides/7/images/test.pov
new file mode 100644
index 0000000..5707be1
--- /dev/null
+++ b/vorlesungen/slides/7/images/test.pov
@@ -0,0 +1,7 @@
+//
+// test.pov
+//
+// (c) 2021 Prof Dr Andreas Müller, OST Ostschweizer Fachhochschule
+//
+#include "drehung.inc"
+#include "dreibein/d025.inc"