how to compare two iteration methods by plotting graph?

3 vues (au cours des 30 derniers jours)
sai krishna pervala
sai krishna pervala le 31 Mar 2018
Réponse apportée : KSSV le 3 Avr 2018
Index exceeds array bounds.
Error in gauss2 (line 65) plot(1:5:GaussItr,plotGauss(1:5:GaussItr),'LineWidth',2)
  1 commentaire
Manan Mishra
Manan Mishra le 3 Avr 2018
It would be very difficult to comment on the issue with the information presented.
Can you please share more information about the query which would help in understanding and reproducing the issue?
Please share the code/data you are using along with the workflow you are following.

Connectez-vous pour commenter.

Réponses (1)

KSSV
KSSV le 3 Avr 2018
% figure
f1 = figure;
f11 = subplot(1,2,1) ; h11 = plot(rand(3,1));
f12 = subplot(1,2,2) ;h12 = plot(rand(3,1));
% apply a y limit, used only to enhance the plots
set(f11,'ylim',[-3 3])
set(f12,'ylim',[-3 3])
for n = 1:10
x1 = rand(3,1) ; y1 = rand(3,1) ;
x2 = rand(3,1) ; y2 = rand(3,1) ;
set(h11, 'XData', x1, 'YData', y1);
set(h12, 'YData', x2, 'YData', y2);
pause(1)
end

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by