← Back to team overview

dolfin team mailing list archive

Re: meshfuntion demo error

 

On Tue, May 08, 2007 at 09:21:29PM +0200, Ola Skavhaug wrote:
> When running src/demo/meshfunction/dolfin-meshfunction, I get the following
> (wrong) error message:
> 
> Reading mesh from file mesh2D.xml.gz.
> Reading real-valued mesh function from file meshfunction.xml.
> Reading mesh from file meshfunction.xml.
> *** Error: Size of mesh function (9) does not match size of mesh (1 entities
> of dimension 16) [XMLMeshFunction.cpp:162: readMeshFunction()]
> 
> 
> The meshfunction.xml file _is_ wrong, containing 9 entities of dimension 1,
> whereas there should be 16. The error message is, however, quite misleading.
> 
> The fixes should be trivial.
> 
> Ola

ok, I've fixed the meshfunction.xml file in the demo so it's defined
on cells (there are 8 cells). Running plot.py now gives

  File "/usr/lib/python2.5/site-packages/viper/viper_dolfin.py", line
  86, in plot_meshfunction
    raise RuntimeError, "Only vertex valued meshfunctions can be
    plotted"
RuntimeError: Only vertex valued meshfunctions can be plotted

Will fix the error message.

/Anders


Follow ups

References