File:Sphere with three handles.png
From Wikimedia Commons, the free media repository
Jump to navigation
Jump to search
Size of this preview: 781 × 599 pixels. Other resolutions: 313 × 240 pixels | 625 × 480 pixels | 1,001 × 768 pixels | 1,308 × 1,004 pixels.
Original file (1,308 × 1,004 pixels, file size: 389 KB, MIME type: image/png)
File information
Structured data
Captions
DescriptionSphere with three handles.png | Illustration of a sphere with three handles. |
Date | (UTC) |
Source | self-made using MATLAB |
Author | Oleg Alexandrov |
This diagram was created with MATLAB.
Public domainPublic domainfalsefalse |
I, the copyright holder of this work, release this work into the public domain. This applies worldwide. In some countries this may not be legally possible; if so: I grant anyone the right to use this work for any purpose, without any conditions, unless such conditions are required by law. |
Source code
[edit]% illustration of a sphere with three handles
N = 100; % make 100 or so for good picture
S = 6.0; % sphere radius
r = 1.2; % torus cross section radius
R = 2.8; % torus big radius
Shift = 6.0; % shift torus away from origin
L = max(S, 2*r+R+Shift);
L = max(Shift + 2*r+R, S);
X = linspace(-L, L, N);
Y = linspace(-L, L, N);
Z = linspace(-L, L, N);
theta = pi/2.2; % angle between handles, measured from sphere center
W = zeros(N, N, N) + 100;
Mat = [cos(theta) -sin(theta);
sin(theta) cos(theta)];
for i=1:N
i
for j=1:N
for k=1:N
x = X(i);
y = Y(j);
z = Z(k);
W(i, j, k) = x^2+y^2+z^2-S^2; % sphere
for q=0:2 % tori
V = Mat*([x, y]');
x = V(1); y = V(2);
W(i, j, k) = min(W(i, j, k), ...
(sqrt((x-Shift)^2+y^2)-R)^2 + z^2-r^2);
end
end
end
end
if 1==1
% smooth a bit the places where the tori meet
XM = -2:60/N:2;
sigma = 1.5;
SM = exp(-XM.^2/sigma^2);
SM = SM/sum(SM);
W = filter(SM, [1], W, [], 1);
W = filter(SM, [1], W, [], 2);
W = filter(SM, [1], W, [], 3);
end
figure(1); clf; hold on;
axis equal; axis off;
light_green=[184, 224, 98]/256; % light green
H = patch(isosurface(X, Y, Z, W, 0));
isonormals(X, Y, Z, W, H);
mycolor = light_green;
%set(H, 'FaceColor', light_green, 'EdgeColor','none', 'FaceAlpha', 1);
%set(H, 'SpecularColorReflectance', 0.9, 'DiffuseStrength', 0.8);
%set(H, 'FaceLighting', 'phong', 'AmbientStrength', 0.35);
%set(H, 'SpecularExponent', 8, 'SpecularStrength', 0.2);
set(H, 'FaceColor', mycolor, 'EdgeColor','none', 'FaceAlpha', 1);
set(H, 'SpecularColorReflectance', 0.1, 'DiffuseStrength', 0.8);
set(H, 'FaceLighting', 'phong', 'AmbientStrength', 0.3);
set(H, 'SpecularExponent', 108);
daspect([1 1 1]);
axis tight;
colormap(prism(28))
view(-50, -54);
camlight headlight;
lighting phong;
%
print('-dpng', '-zbuffer', '-r400', sprintf('Sphere_with_three_handles%d.png', N));
File history
Click on a date/time to view the file as it appeared at that time.
Date/Time | Thumbnail | Dimensions | User | Comment | |
---|---|---|---|---|---|
current | 04:28, 23 June 2008 | 1,308 × 1,004 (389 KB) | Oleg Alexandrov (talk | contribs) | Tweak | |
02:37, 23 June 2008 | 1,596 × 1,112 (454 KB) | Oleg Alexandrov (talk | contribs) | {{Information |Description={{en|1=Sphere with three handles}} |Source=Own work by uploader |Author=Oleg Alexandrov |Date= |Permission=PD-self |other_versions= }} {{ImageUpload|full}} |
You cannot overwrite this file.
File usage on Commons
The following page uses this file:
File usage on other wikis
The following other wikis use this file:
- Usage on cv.wikipedia.org
- Usage on de.wikipedia.org
- Usage on de.wikiversity.org
- Kurs:Algebraische Kurven (Osnabrück 2008)/Vorlesung 28
- Kurs:Mathematik (Osnabrück 2009-2011)/Teil III/Vorlesung 85
- Kurs:Mathematik (Osnabrück 2009-2011)/Teil III/Vorlesung 85/kontrolle
- Kurs:Algebraische Kurven (Osnabrück 2012)/Vorlesung 28
- Kurs:Analysis (Osnabrück 2013-2015)/Teil III/Vorlesung 84
- Kurs:Analysis (Osnabrück 2014-2016)/Teil III/Vorlesung 84
- Kurs:Analysis (Osnabrück 2014-2016)/Teil III/Vorlesung 84/kontrolle
- Kurs:Algebraische Kurven (Osnabrück 2017-2018)/Vorlesung 28
- Kurs:Algebraische Kurven (Osnabrück 2017-2018)/Vorlesung 28/kontrolle
- Glatte projektive Kurve/Geschlecht/Textabschnitt
- Kurs:Bündel, Garben und Kohomologie (Osnabrück 2019-2020)/Vorlesung 29
- Kurs:Bündel, Garben und Kohomologie (Osnabrück 2019-2020)/Vorlesung 29/kontrolle
- Kurs:Elliptische Kurven (Osnabrück 2021-2022)/Vorlesung 17
- Kurs:Elliptische Kurven (Osnabrück 2021-2022)/Vorlesung 17/kontrolle
- Riemannsche Fläche/Kompakt/Topologisches Geschlecht/Triangulierung/Übersicht/Textabschnitt
- Kurs:Riemannsche Flächen (Osnabrück 2022)/Vorlesung 32
- Kurs:Riemannsche Flächen (Osnabrück 2022)/Vorlesung 32/kontrolle
- Kurs:Differentialgeometrie (Osnabrück 2023)/Vorlesung 16
- Kurs:Differentialgeometrie (Osnabrück 2023)/Vorlesung 16/kontrolle
- Kurs:Analysis (Osnabrück 2013-2015)/Teil III/Vorlesung 84/kontrolle
- Usage on el.wikipedia.org
- Usage on en.wikipedia.org
- Usage on es.wikipedia.org
- Usage on fr.wikipedia.org
- Usage on it.wikipedia.org
- Usage on ja.wikipedia.org
- Usage on nl.wikipedia.org
- Usage on no.wikipedia.org
- Usage on ru.wikipedia.org
- Usage on uk.wikipedia.org
- Usage on zh.wikipedia.org