File:Ondes compression 2d 20.gif

Ondes_compression_2d_20.gif(610 × 461 pixels, file size: 432 KB, MIME type: image/gif, looped, 89 frames, 8.9 s)

This is a file from the Wikimedia Commons. The description on its description page there is shown below.

Commons is a freely licensed media file repository. You can help.

Summary

Description
English: Compressional wave (longitudinal wave: seismic P-wave, sound etc.): 2d representation on a 20×20 grid, with an empirical shape (derivative from a gaussian profile, small attenuation with distance); made with Scilab
Français : Onde de compression (onde longitudinale : onde sismique P, son…) : représentation 2d sur une grille 20×20 grid, avec un profil empirique (derivée d'un profil gaussien, faible d'attenuation avec la distance) ; réalisé avec Scilab
Date
Source Own work
Author Christophe Dang Ngoc Chan (cdang)
Permission
(Reusing this file)
GFDL
Other versions smaller size: Image:Ondes compression 2d 20 petit.gif; plane version: Image:Onde compression impulsion 1d 30.gif; other type of body wave: Image:Ondes cisaillement 2d 20.gif

Source code (scilab)

 clear;
 
 N = 25; // taille de la grille (noeuds)
 Naff = 20; // taille affichee
 centre = N/2; // centre de la grille
 L = 2; // largeur de la perturbation (loi empirique)
 
 points_initiaux_x = zeros(N, N); // initialisation des
 points_initiaux_y = zeros(N, N); // coordonnées
 for i = 1:N
    for j = 1:N
       points_initiaux_x(i, j) = i - centre;
       points_initiaux_y(i, j) = j - centre;
    end
 end
 points_finaux_x = points_initiaux_x;
 points_finaux_y = points_initiaux_y;
 for i = 1:N
    for j = 1:N
       d = sqrt(points_initiaux_x(i, j)^2 + points_initiaux_y(i, j)^2);
       distance(i, j) = d; // distance au centre
       if d == 0 then
          direction_x(i, j) = 0 ; direction_y(i, j) = 0 ;
       else
          direction_x(i,j) = points_initiaux_x(i, j)/d; // vecteur unitaire
          direction_y(i,j) = points_initiaux_y(i, j)/d;
       end
    end
 end
 
 // fonction
 
 deff('[e] = profil(r)','e = r*exp(-(r/L)^2)'); // profil empirique
 
 // programme principal
 
 unite = 0; dizaine = 0; // pour le nom de fichier
 for r = 0.1:0.2:centre*1.42 // rayon du front d'onde
    intensite = r^(-1/3); // variation avec la distance
    for i = 1:N
       for j = 1:N
          // e = deplacement du point
          e = intensite*profil(distance(i,j)-r);
          points_finaux_x(i, j) = points_initiaux_x(i, j) + e*direction_x(i, j);
          points_finaux_y(i, j) = points_initiaux_y(i, j) + e*direction_y(i, j);
       end
    end
    // dessin
    clf;
    plot2d(0, 0 , -1, "010", " ", [-Naff/2, -Naff/2, Naff/2, Naff/2]) 
    for i = 1:N
       xpoly(points_finaux_x(i, :), points_finaux_y(i, :));
       xpoly(points_finaux_x(:, i), points_finaux_y(:, i));
    end
    nom = "test\test" + code2str(dizaine) + code2str(unite) + ".gif";
    xs2gif(0, nom, 1);
    unite = unite + 1;
    if unite == 10 then
       dizaine = dizaine + 1;
       unite = 0 ;
    end
 end

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
GNU head Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled GNU Free Documentation License.
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported 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.
This licensing tag was added to this file as part of the GFDL licensing update.

Captions

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts

17 November 2006

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current15:02, 17 November 2006Thumbnail for version as of 15:02, 17 November 2006610 × 461 (432 KB)Cdangmore GIF compression, smaller file size
14:47, 17 November 2006Thumbnail for version as of 14:47, 17 November 2006610 × 461 (496 KB)Cdang{{Information |Description={{en|Compressional wave (longitudinal wave: seismic P-wave, sound etc.): 2d representation on a 20×20 grid, with an empirical shape (derivative from a gaussian profile, no attenuation with distance); made with [http://www.

The following page uses this file:

Global file usage

The following other wikis use this file: