« Return to Thread: fpl and msh
On 17 Jun 2009, at 20:02, Thomas L. Scofield wrote:I will be teaching introductory pdes in the fall at my institution (Calvin College). I have done so before, about 3 years ago, and used Octave as the software package for the course. At that time, there was a "package" (don't recall if it was available through the octave-forge site, but think probably not) which, though out of date at the time and requiring a separate executable to generate the mesh, was adequate for teaching rudimentary finite element methods.I was excited to see that there are packages, namely fpl and msh, now available through octave-forge, which may be more up-to-date and easier to use.You might also want to have a look at "bim" which can be used to solve simple elliptic equatioons in 1, 2 and 3d with piece-wise linear continuous finite elementsI installed both by first downloading the zipped tarballs and then running> pkg install ...I had not first noted the dependence upon gmsh. Anyway, the "pkg install" command above produced no errors for either package, so I thought everything was fine. Even with the dependence upon gmsh, I am unsure why things like> help MSH3Mgmshproduce the messagehelp: `MSH3Mgmsh' not foundTo avoid crowding up Octave's name space some packages are configured to not be loaded automatically at startup, 'msh' 'fpl' and 'bim' are among those.Before you can use the functions from msh you need to dopkg load mshI have since gone and got gmsh. Since I am working on a Mac, the best way seemed via a disk image (.dmg) file which, when mounted, gave me Gmsh.app, which I could drag into my applications folder. Now I can run Gmsh. What I do not have, however, is the ability to run gmsh from a terminal (could probably set that up with an alias), if that matters.Yes, it does matter the command 'gmsh' must be in the path for Octave to be able to use it.If you have installed version 2.3.1 of Gmsh.app in /Applications you can achieve this by adding the line:PATH="${PATH}:/Applications/gmsh-2.3.1/Gmsh.app/Contents/MacOS/"to the file .bash_login (or .bashrc) in your home directoryIs there some "switch", amounting to "which gmsh", that is checked at the time these packages are installed and, when it fails, keeps the package from being installed? That would seem quite strange in light of the fact thatNo, if gmsh is not available msh can still be used for other things, e.g. to create structured meshes and to apply some simple mesh transformations, try for exampledemo MSH2Mjigglemeshtherefore msh does not refuse to install or run if gmsh is not available.> pkg listlists both fpl and msh as 'installed'.as I said before these packages need not only be installed but also loaded,when they are loaded they will show a '*' beside their name:>> pkg listPackage Name | Version | Installation directory--------------+---------+-----------------------bim | 0.1.1 | /Users/carlo/octave/bim-0.1.1fpl | 0.1.6 | /Users/carlo/octave/fpl-0.1.6integration | 1.0.7 | /Users/carlo/octave/integration-1.0.7msh | 0.1.1 | /Users/carlo/octave/msh-0.1.1nurbs | 1.0.1 | /Users/carlo/octave/nurbs-1.0.1splines | 1.0.7 | /Users/carlo/octave/splines-1.0.7>> pkg load msh>> pkg listPackage Name | Version | Installation directory--------------+---------+-----------------------bim | 0.1.1 | /Users/carlo/octave/bim-0.1.1fpl | 0.1.6 | /Users/carlo/octave/fpl-0.1.6integration | 1.0.7 | /Users/carlo/octave/integration-1.0.7msh *| 0.1.1 | /Users/carlo/octave/msh-0.1.1nurbs | 1.0.1 | /Users/carlo/octave/nurbs-1.0.1splines *| 1.0.7 | /Users/carlo/octave/splines-1.0.7>>Thomas L. ScofieldHTH,c.
« Return to Thread: fpl and msh
| Free embeddable forum powered by Nabble | Forum Help |