1 / 5

Comentários da Lista1

Universidade Federal do Rio de Janeiro Núcleo de Computação Eletrônica. Comentários da Lista1. 2003/2. Prof. A. C. G. Thomé, PhD – thome@nce.ufrj.br Airam C. P. B. Marques – airamcpbm@posgrad.nce.ufrj.br. Lista 1. 1 a questão 100:-5:-100 linspace(100,-100,41) 2 a questão (1:100) .^ 2.

lynnea
Download Presentation

Comentários da Lista1

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Universidade Federal do Rio de Janeiro Núcleo de Computação Eletrônica Comentários da Lista1 2003/2 Prof. A. C. G. Thomé, PhD – thome@nce.ufrj.br Airam C. P. B. Marques – airamcpbm@posgrad.nce.ufrj.br

  2. Lista 1 1a questão • 100:-5:-100 • linspace(100,-100,41) 2a questão (1:100) .^ 2

  3. Lista 1 3a questão A = rand(8); B = fliplr(A); ou B = A(:,end:-1:1); C = flipud(fliplr(A)); ou B = A(end:-1:1,end:-1:1) 4a questão mean(A)

  4. Lista 1 5a questão • B = diag(A(:,1)); • C = diag(diag(A,1)); • D = reshape(A’,1,prod(size(A))); 6a questão repmat(1:N,N,1);

  5. Lista 1 7a questão (Se não usar a função hilb) ind = repmat(1:N,N,1); ind = ind + ind’ -1; h = 1 ./ ind; 10a questão p1 = (1 + sqrt(5)) / 2; p2 = (1 – sqrt(5))/2; fib = (p1 .^ n – p2 .^ n) / sqrt(5); fib = round(fib);

More Related