Ficheiro:Level grad.png

De testwiki
Ir para a navegação Ir para a procura
    Ficheiro original (358 × 336 píxeis, tamanho: 70 kB, tipo MIME: image/png)

    Este ficheiro vem da wiki na wiki Wikimedia Commons e pode ser usado por outros projetos. A descrição na página original de descrição do ficheiro é mostrada abaixo.

    Transferido de en.wikipedia para a wiki Commons por Maksim.

    A página de descrição original está aqui. Todos os nomes de utilizador a seguir referem-se a en.wikipedia.

    Done with Matlab.

    Public domain Eu, titular dos direitos de autor desta obra, dedico-a ao domínio público, com aplicação em todo o mundo.
    Nalguns países isto pode não ser legalmente possível; se assim for:
    Concedo a todos o direito de usar esta obra para qualquer fim, sem quaisquer condições, a menos que tais condições sejam impostas por lei.
    File:Level grad.svg é uma versão vetorial deste ficheiro. Ela deve ser usada em vez desta imagem em formato raster, se não for de qualidade inferior.

    File:Level grad.png → File:Level grad.svg

    Para mais informações, consulte Ajuda:SVG.

    Em outras línguas
    Alemannisch ∙ العربية ∙ беларуская (тарашкевіца) ∙ български ∙ বাংলা ∙ català ∙ нохчийн ∙ čeština ∙ dansk ∙ Deutsch ∙ Ελληνικά ∙ English ∙ British English ∙ Esperanto ∙ español ∙ eesti ∙ euskara ∙ فارسی ∙ suomi ∙ français ∙ Frysk ∙ galego ∙ Alemannisch ∙ עברית ∙ हिन्दी ∙ hrvatski ∙ magyar ∙ հայերեն ∙ Bahasa Indonesia ∙ Ido ∙ italiano ∙ 日本語 ∙ ქართული ∙ 한국어 ∙ lietuvių ∙ македонски ∙ മലയാളം ∙ Bahasa Melayu ∙ မြန်မာဘာသာ ∙ norsk bokmål ∙ Plattdüütsch ∙ Nederlands ∙ norsk nynorsk ∙ norsk ∙ occitan ∙ polski ∙ prūsiskan ∙ português ∙ português do Brasil ∙ română ∙ русский ∙ sicilianu ∙ Scots ∙ slovenčina ∙ slovenščina ∙ српски / srpski ∙ svenska ∙ தமிழ் ∙ ไทย ∙ Türkçe ∙ татарча / tatarça ∙ українська ∙ vèneto ∙ Tiếng Việt ∙ 中文 ∙ 中文(中国大陆) ∙ 中文(简体) ∙ 中文(繁體) ∙ 中文(马来西亚) ∙ 中文(新加坡) ∙ 中文(臺灣) ∙ +/−
    Nova imagem SVG

    .

    Source code:

    Lx1=-1.7; Lx2=2.3; Ly1=-2; Ly2=2;  % box dimensions
    N=60; % split the box into N x N grid
    [X, Y]=meshgrid(Lx1:1/N:Lx2, Ly1:1/N:Ly2); % the grid
    
    f=inline('-((y+1).^4/25+(x-1).^4/10+x.^2+y.^2-1)');   % draw the level sets of f
    fx=inline('-2/5*(x-1).^3-2*x'); fy=inline('-4/25*(y+1).^3-2*y'); % partial deriv  
    Z=f(X, Y); % the function value
    
    figure(1); clf; hold on; axis equal; axis off; % pop up a figure
    h=0.5; % spacing between heights
    v=[-20:h:0.8 0.85]; % the heights
    [c,h] = contour(X, Y, Z, v, 'b'); % the level sets at those heights
    
    x0=0.1333; y0=-0.0666; % coordinates of the top of the hill
    delta=0.01; % descend from the top of the hill with this step size
    Angles=linspace(0, 2*pi, 20); % will draw 19 descent curves with Angles(i)
    
    for i=1:length(Angles)
       x=x0+0.1*cos(Angles(i)); y=y0+0.1*sin(Angles(i)); % starting point
       Curve_x=[x]; Curve_y=[y]; % will hold a descent curve following the gradient
    
       % descend from the hill 
       for j=1:500
          x=x-delta*fx(x);
          y=y-delta*fy(y);
          Curve_x=[Curve_x x]; Curve_y=[Curve_y y]; % append the updated values
    
          if max(abs(x), abs(y)) > 5 % stop when going beyond the picture frame
    	 break;
          end
       end
       plot(Curve_x, Curve_y, 'r') % plot the curve of steepest descent
    end
    
    axis([Lx1 Lx2 Ly1 Ly2]); % the picture frame
    
    saveas(gcf, 'level_grad.eps', 'psc2') % save as color postscript. Use gimp to convert
    % to png. Does anybody know how to reduce aliasing (gimp helps, but only a bit)?
    date/time username edit summary
    19:47, 30 January 2006 en:User:Varuna (get rid of ugly tag warning)
    18:54, 23 December 2004 en:User:Oleg Alexandrov (added source code)
    18:41, 23 December 2004 en:User:Oleg Alexandrov (I made this. {{PD}})

    Registo de carregamento original

    Legend: (cur) = this is the current file, (del) = delete this old version, (rev) = revert to this old version.

    Click on date to download the file or see the image uploaded on that date.

    Legendas

    Adicione uma explicação de uma linha do que este ficheiro representa

    Elementos retratados neste ficheiro

    retrata

    Histórico do ficheiro

    Clique uma data e hora para ver o ficheiro tal como ele se encontrava nessa altura.

    Data/horaMiniaturaDimensõesUtilizadorComentário
    atual16h31min de 19 de março de 2006Miniatura da versão das 16h31min de 19 de março de 2006358 × 336 (70 kB)wikimediacommons>MaksimLa bildo estas kopiita de wikipedia:en. La originala priskribo estas: Done with Matlab. {{PD-self}} Source code: <pre> Lx1=-1.7; Lx2=2.3; Ly1=-2; Ly2=2; % box dimensions N=60; % split the box into N x N grid [X, Y]=meshgrid(Lx1:1/N:Lx2, Ly1:1/N:Ly2); %

    Não há nenhuma página que use este ficheiro.