フィルターのクリア

Unable to suppress columns of plot

1 回表示 (過去 30 日間)
Marco Bakker
Marco Bakker 2016 年 10 月 27 日
回答済み: Walter Roberson 2016 年 10 月 27 日
idx = find(pos<0.00000001,1);
endTime = t(idx);
plot(t,pos,'--','DisplayName','Verlet solution');
legend('show')
xlim([0 endTime])
ylim([0 height])
Whats wrong with my code that makes all the columns of the plot print? It's driving me crazy, and overheating my CPU!

回答 (1 件)

Walter Roberson
Walter Roberson 2016 年 10 月 27 日
idx = find(pos < 1E-8, 1, 'first');
endTime = t(idx);
plot(t(1:idx), pos(1:idx), '--','DisplayName','Verlet solution');
legend('show')
xlim([0 endTime])
ylim([0 height])

カテゴリ

Help Center および File ExchangeGraphics Objects についてさらに検索

タグ

製品

Community Treasure Hunt

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

Start Hunting!

Translated by