errors running the first example (d1_p2D.py) in tutorial
After running the first python example "d1_p2D.py" in the directory : examples-
"
*** Warning: UnitSquare has been deprecated in DOLFIN version 1.1.0.
*** The class UnitSquare has been replaced by UnitSquareMesh.
...."
So then I changed "UnitSquare" to "UnitSquareMesh" in the code and it gave me this error message:
"
File "d1_p2D.py", line 15, in <module>
V = FunctionSpace(mesh, 'Lagrange', 1)
File "/Applications/
FunctionSpa
File "/Applications/
ufc_element, ufc_dofmap = jit(self.
File "/Applications/
return local_jit(*args, **kwargs)
File "/Applications/
raise OSError, "Could not find swig installation. Pass an existing "\
OSError: Could not find swig installation. Pass an existing swig binary or install SWIG version 2.0 or higher. "
Can someone help me with this?
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- DOLFIN Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Johannes Ring
- Solved:
- 2013-02-27
- Last query:
- 2013-02-27
- Last reply:
- 2013-02-27
Johannes Ring (johannr) said : | #1 |
What do you get when you type in these two commands:
which swig
swig -version
Are you using the 1.1.0 dmg bundle or a nightly snapshot?
Panu Sam-ang (panu1201) said : | #2 |
Thank you very much for helping.
I use Mac OS X 10.8.2
This is what I got after I typed which swig:
"/Applications/
And this is what I got after typing swig -version:
"SWIG Version 2.0.8
Compiled with /usr/bin/g++ [i386-apple-
Configured options: +pcre
Please see http://
I am using 1.1.0 dmg bundle here http://
Panu Sam-ang (panu1201) said : | #3 |
Can someone help me with this? I really want this to get working.
Panu Sam-ang (panu1201) said : | #4 |
I removed this file " “dolfin_
Can someone explain why removing the file "dolfin_
Johannes Ring (johannr) said : | #6 |
Perhaps 'swig_binary' was set in 'dolfin_
Panu Sam-ang (panu1201) said : | #7 |
This is what I have in 'dolfin_
"
<parameter key="swig_binary" type="string" value="swig2.0" />
<parameter key="swig_path" type="string" value="" /> ".
Should I change something here?
Johannes Ring (johannr) said : | #8 |
The problem is that "swig_binary" is set to "swig2.0". Where did you get that file?
Panu Sam-ang (panu1201) said : | #9 |
I got it from " a tarball with all programs referred to in this tutorial " on http://
|
#10 |
The dolfin_
Panu Sam-ang (panu1201) said : | #11 |
Thanks Johannes Ring, that solved my question.