ngspice没有在mac上工作

时间:2015-08-02 11:13:47

标签: macos terminal homebrew x11

我使用自制软件在我的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退出了。

请帮忙。谢谢。

1 个答案:

答案 0 :(得分:0)

它与瞬态模拟的起始条件有关。正如您所说的那样:节点1和2上的初始瞬态解决方案是10 V,因此V(2)将永远保留在那里。 如果你想拥有不同的初始条件,请按照手册进行操作。 15.2.2,在输入文件中添加一行.ic,在tran行中添加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
.end
相关问题