Anar al contingut

Archiu:Helmholtz solution.png

De L'Enciclopèdia, la wikipedia en valencià
Resolució completa. ((975 × 1957 pixels, tamany de l'archiu: 23 kB, MIME tipo: image/png))

Est archiu és de Wikimedia Commons i pot usar-se en atres proyectes. La descripció en la seua pàgina de descripció de l'archiu es mostra més avall.

Description Illustration of en:Helmholtz equation.
Date (UTC)
Source self-made with en:Matlab. See the source code below.
Author Oleg Alexandrov
 This diagram was created with MATLAB.
Public domain 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 (MATLAB)

 

% Plot the solution to the Helmholtz equation with a given source
clear all;

Box_x = 3;
Scale = 0.5;
Box_y = Box_x/Scale;

Nx = 200;
Ny = Nx/Scale;

wavenumber = 10;

XX = linspace(-Box_x, Box_x, Nx);
YY = linspace(-Box_y, Box_y, Ny);
hx = XX(2) - XX(1);
hy = YY(2) - YY(1);
[X, Y] = meshgrid(XX, YY);

Source_size  = 0.5;
Source_shift = 2;
Source =  max(Source_size^2 - X.^2-(Y-Source_shift).^2, 0) + max(Source_size^2 - X.^2-(Y+Source_shift).^2, 0) ;

% plot the source
figure(1); clf; hold on; axis equal; axis off;
imagesc(Source);


% plot the solution to the Helmholtz equation
I = sqrt(-1);
Field = 0*X;

[m, n] = size(Source);
for i=1:m
   i
   for j=1:n

      if Source(i, j) ~= 0

	 x0 = X(i, j);
	 y0 = Y(i, j);

	 % add the contribution from the current source
	 Field = Field + (I/4)*besselh(0, 1, wavenumber*sqrt((X-x0).^2+(Y-y0).^2) + eps)*Source(i, j)*hx*hy;
      end
      
   end
end


figure(2); clf; hold on; axis equal; axis off;
imagesc(real(Field));

% Save to disk and convert to png right away
figure(1); 
saveas(gcf, 'Helmholtz_source.eps', 'psc2');
%! convert -density 200 Helmholtz_source.eps Helmholtz_source.png

figure(2); 
saveas(gcf, 'Helmholtz_solution.eps', 'psc2');
%! convert -density 200 Helmholtz_solution.eps Helmholtz_solution.png
This math image could be re-created using vector graphics as a SVG file. This has several advantages; see Commons:Media for cleanup for more information. If a SVG form of this image is available, please upload it and afterwards replace this template with {{vector version available|new image name}}.
It is recommended to name the SVG file “Helmholtz solution.svg”—then the template Vector version available (or Vva) does not need the new image name parameter.

Captions

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts English

creator English

Some value without a Wikidata item

inception English

7 July 2007

data size English

23,831 byte

height English

1,957 pixel

width English

975 pixel

media type English

image/png

checksum English

1f767594bd7d15fc5cd699d5153f8103fd3e6f6f

Historial de l'image

Puncha en la data/hora per a vore l'image tal i com es mostrava en eixe moment.

Data/HoraMiniaturaDimensionsUsuariDescripció
actual19:50 7 jul 2007Miniatura de la versió de 19:50 7 jul 2007975 × 1957 (23 kB)wikimediacommons>Oleg AlexandrovTweak

Les següents pàgines enllacen ad esta image: