当MATLAB非常繁忙时,如何中断它? [英] How can I interrupt MATLAB when it gets really really busy?

查看:273
本文介绍了当MATLAB非常繁忙时,如何中断它?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 MATLAB 中进行了长时间的模拟,我意识到我需要停止然后重新运行.但是,MATLAB确实参与了此计算,并且已停止响应.如何在不终止MATLAB的情况下中断运行?

I'm running a long simulation in MATLAB that I've realized I need to stop and rerun. However, MATLAB is really into this calculation, and it's stopped responding. How can I interrupt this run without killing MATLAB?

(我意识到这在许多Windows程序中都是一个问题,但对于MATLAB来说确实很严重.)

(I realize this is a problem with many Windows programs, but it's really acute with MATLAB.)

推荐答案

转到命令窗口,然后按Ctrl-C很多.根据我的经验,在单核计算机上您没有机会,除非您进行大量输出.在多核或多处理器计算机上,您最终可能会停止它,但是这需要时间.

Go to the command window, and hit Ctrl-C a lot. From my experience, on a single-core machine you do not have a chance, unless you do lots of output. On a multi-core or multi-processor machine, you'll probably stop it eventually, but it takes time.

另请参见 http://www.mathworks. com/support/solutions/en/data/1-188VX/index.html

已添加 :( 1)在长时间运行任何内容之前保存工作区快照是一个好习惯,(2)在很长的计算时间内将一些变量写入文件有时,以便您可以在计算中断(例如由于电源故障)时恢复计算.

Added: it is a good practice to (1) save a snapshot of your workspace before running anything really long and (2) within a very long calculation, write some of the variables to a file from time to time, so that you can resume the calculation if it was interrupted (by power failure, e.g.).

这篇关于当MATLAB非常繁忙时,如何中断它?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆