我用自制软件在我的mac上安装了ngspice。
brew install ngspice --with-x当我运行一个简单的RC电路仿真时,
*First Circuit
r1 1 2 1k
c1 2 0 1n
v1 1 0 10
.control
tran 1n 10u
plot v(2)
.endc
.end我在我的终端上得到了这个
******
** ngspice-26 : Circuit level simulation program
** The U. C. Berkeley CAD Group
** Copyright 1985-1994, Regents of the University of California.
** Please get your ngspice manual from http://ngspice.sourceforge.net/docs.html
** Please file your bug-reports at http://ngspice.sourceforge.net/bugrep.html
** Creation Date: Mon Jul 27 21:51:01 IST 2015
******
ngspice 2 ->
ngspice 2 -> source Ex1.txt
Circuit: *first circuit
Doing analysis at TEMP = 27.000000 and TNOM = 27.000000
Initial Transient Solution
--------------------------
Node Voltage
---- -------
1 10
2 10
v1#branch 0
No. of Data Rows : 10008
Warning: Unable to load any usable fontset这是在我的X11屏幕上,(不幸的是,我现在还不能发布图片。我的X11图只是一条平坦的线,而不是指数)。
我不能理解如何摆脱这个‘警告:无法加载任何可用的字体集’的错误。我很确定这与X11有关,而不是ngspice。
另外,当我直接使用'Cmd + W‘关闭我的X11屏幕时,我在我的终端上得到了这个错误,
XIO: fatal IO error 35 (Resource temporarily unavailable) on X server "/private/tmp/com.apple.launchd.pkrxPE5Sf7/org.macosforge.xquartz:0"
after 493 requests (493 known processed) with 0 events remaining.ngspice放弃了。
请帮帮忙。谢谢。
发布于 2015-12-29 17:04:43
它与瞬态模拟的启动条件有关。正如ngspice在您的案例中所说:节点1和2上的初始瞬态解决方案是10V,因此V(2)将永远留在那里。如果你想有一个不同的初始条件,根据手册章节。15.2.2,在输入文件中添加一个带有.ic的行,并将uic参数(使用初始条件)添加到事务行。
霍尔格
*First Circuit
r1 1 2 1k
c1 2 0 1n
v1 1 0 10
.ic v(2) = 0
.control
tran 1n 10u uic
plot v(2)
.endc
.endhttps://stackoverflow.com/questions/31771295
复制相似问题