File:Voisinage tubulaire.svg
![File:Voisinage tubulaire.svg](https://upload.wikimedia.org/wikipedia/commons/thumb/4/4b/Voisinage_tubulaire.svg/705px-Voisinage_tubulaire.svg.png?20151015191239)
Size of this PNG preview of this SVG file: 705 × 286 pixels. Other resolutions: 320 × 130 pixels | 640 × 260 pixels | 1,024 × 415 pixels | 1,280 × 519 pixels | 2,560 × 1,039 pixels.
Original file (SVG file, nominally 705 × 286 pixels, file size: 10 KB)
File information
Structured data
Captions
Captions
Add a one-line explanation of what this file represents
Summary
editDescriptionVoisinage tubulaire.svg |
Français : Voisinage tubulaire de la courbe y=sin(x)
def main():
f = sin(x)
a = 0
b = 2 * pi
N = 1000
# consider N points in the interval [a, b]
X = [a + (b - a) / N * k for k in range(N + 1)]
Y = [f(x=u) for u in X]
ll = 3
# length of lines perpendicular to the curve
lls = 0.3
# smaller subsegments
thin_line = 2
thick_line = 4
# will draw lines perpendicular to the graph of Y=f(X) at
# points separted by length of 'spacing'
spacing = 0.015
M = floor(spacing * N)
# colors
red = [0.867, 0.06, 0.14]
blue = list(vector([0, 129, 205]) / QQ(256))
green = list(vector([0, 200, 70]) / QQ(256))
G = Graphics()
# plot the lines
for k in range(1, N + 1):
p = (k - 1) * M + 2
if p >= N:
break
# the normal to the curve at (X(p), Y(p))
Normal = vector([-(Y[p + 1] - Y[p - 1]), X[p + 1] - X[p - 1]])
Normal = Normal / norm(Normal)
G += line([(X[p] - lls * Normal[0], Y[p] - lls * Normal[1]),
(X[p] + lls * Normal[0], Y[p] + lls * Normal[1])],
color=red,
thickness=0.7 * thick_line)
# plot the curve
G += line2d(zip(X, Y), thickness=thick_line, color=blue)
G.axes(False)
G.set_aspect_ratio(1)
return G
|
Date | |
Source | Own work |
Author | Kilom691 |
Licensing
editI, the copyright holder of this work, hereby publish it under the following license:
![w:en:Creative Commons](https://upload.wikimedia.org/wikipedia/commons/thumb/7/79/CC_some_rights_reserved.svg/90px-CC_some_rights_reserved.svg.png)
![attribution](https://upload.wikimedia.org/wikipedia/commons/thumb/1/11/Cc-by_new_white.svg/24px-Cc-by_new_white.svg.png)
![share alike](https://upload.wikimedia.org/wikipedia/commons/thumb/d/df/Cc-sa_white.svg/24px-Cc-sa_white.svg.png)
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
- You are free:
- to share – to copy, distribute and transmit the work
- to remix – to adapt the work
- Under the following conditions:
- attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
- share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
File history
Click on a date/time to view the file as it appeared at that time.
Date/Time | Thumbnail | Dimensions | User | Comment | |
---|---|---|---|---|---|
current | 19:12, 15 October 2015 | ![]() | 705 × 286 (10 KB) | Kilom691 (talk | contribs) | User created page with UploadWizard |
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 de.wikipedia.org
- Usage on en.wikipedia.org
- Usage on fr.wikipedia.org
- Usage on ru.wikipedia.org
- Usage on uk.wikipedia.org
- Usage on zh.wikipedia.org
Metadata
This file contains additional information such as Exif metadata which may have been added by the digital camera, scanner, or software program used to create or digitize it. If the file has been modified from its original state, some details such as the timestamp may not fully reflect those of the original file. The timestamp is only as accurate as the clock in the camera, and it may be completely wrong.
Width | 564pt |
---|---|
Height | 229pt |