Fenics Expression error: "PETSc was configured with MPICH but now appears to be compiling using a non-MPICH mpi.h"


161
views
0
3 months ago by
Hello!

I currently working with the following simply code:

1)    from fenics import *
2)    a = Expression('1 + x[0]*x[0] + 2*x[1]*x[1]', degree=2)
3)    b = Expression('1.0 + x[0]*x[1]*(1.0-x[0])*(1.0-x[1])', degree=2)

The results turned out to be:
a is constructed successfully, with a.__class_ = <class 'dolfin.functions.expression.CompiledExpression'>
BUT, b failed. The error mesg is as follows:

==> RuntimeError: In instant.recompile: The module did not compile with command 'make VERBOSE=1', see compile.log file.

==> compile.log file:

everything is fine until :

/workspace/Library/miniconda2/envs/fenics/include/petscsys.h(144): error: #error directive: "PETSc was configured with MPICH but now appears to be compiling using a non-MPICH mpi.h"
# error "PETSc was configured with MPICH but now appears to be compiling using a non-MPICH mpi.h"
^

compilation aborted for /tmp/tmpiOIB_n2017-8-30-21-18_instant_a272d385da574cee320c5f6f9223b283aa125e25/dolfin_2db9bc0e821ad408838ae5af6db3fb7b72ef61b3/dolfin_2db9bc0e821ad408838ae5af6db3fb7b72ef61b3PYTHON_wrap.cxx (code 2)

I tried reinstall fenics in this way:
conda install -c conda-forge fenics

This will give a fenics version of 2017.1.0. But it doesn't work.  Anyone knows what happened? I don't understand why "a" works but not "b".




Many thanks!
Community: FEniCS Project
Try instant-clean first, then see what is going on, probably both expression will fail then
written 3 months ago by Yuxiang Lin  
Please login to add an answer/comment or follow this question.

Similar posts:
Search »