Dear Nicolò,

These error are coming from the linker. May be you forgot to ling the Getfem library with your program.

Best regards,

Yves




Le 25/11/2019 à 12:21, Nicolò Cambiaso a écrit :
Dear Yves,

Yes, that was the problem, thank you.

Now I'm still looking at the tutorial about Thermo-elastic and electrical coupling (with MatLab it helped a lot and it was very clear) and adding the code the single line

>> getfem::mesh mesh;

gives me theese errors:

C:\Users\cambi\AppData\Local\Temp\ccsXaSdU.o prova1.cpp:(.text+0x285): undefined reference to `getfem::mesh::mesh(std::string)'

C:\Users\cambi\AppData\Local\Temp\ccsXaSdU.o prova1.cpp:(.text$_ZN5bgeot15block_allocator7dec_refEj[_ZN5bgeot15block_allocator7dec_refEj]+0x62): undefined reference to `bgeot::block_allocator::deallocate(unsigned int)'undefined reference to `getfem::mesh::mesh(std::string)'

C:\Users\cambi\AppData\Local\Temp\ccsXaSdU.o prova1.cpp:(.text$_ZN6getfem4meshD1Ev[_ZN6getfem4meshD1Ev]+0xbe): undefined reference to `getfem::context_dependencies::~context_dependencies()'

C:\Users\cambi\AppData\Local\Temp\ccsXaSdU.o prova1.cpp:(.rdata$.refptr._ZTVN6getfem4meshE[.refptr._ZTVN6getfem4meshE]+0x0): undefined reference to `vtable for getfem::mesh'

C:\Users\cambi\AppData\Local\Temp\ccsXaSdU.o prova1.cpp:(.rdata$.refptr._ZN5bgeot22static_block_allocator6pallocE[.refptr._ZN5bgeot22static_block_allocator6pallocE]+0x0): undefined reference to `bgeot::static_block_allocator::palloc'.

I have to say I'm pretty new to C++, so I'm very confused: shouldn't this line just define the existence of the mesh? Thank you very much for your help and your time, it's much appreciated.

Best Regards,
Nicolò Cambiaso



Il giorno mer 20 nov 2019 alle ore 14:26 Yves Renard <[email protected] <mailto:[email protected]>> ha scritto:


    Dear Nicolò,

    If you already compiled GetFEM with its matlab interface and Mumps
    this
    a priori means that mumps is installed on your system (on MinGW64
    is I
    understand well). May be Devc++ just needs the path for the mumps
    includes ?

    Best regards,

    Le 20/11/2019 à 10:27, Nicolò Cambiaso a écrit :
    > Dear GetFem++ Users,
    >
    > Until now I've always used GetFemm++ with MatLab interface, and
    > everything worked.
    > Now I'm trying to use the C++ (Devc++ in particular) interface,
    but I
    > get error message about MUMPs package like
    > " C:\Program Files
    > (x86)\Dev-Cpp\MinGW64\include\gmm\gmm_MUMPS_interface.h [Error]
    > smumps_c.h: No such file or directory"
    > after trying to compile this code:
    >
    > "#include "getfem_model_solvers.h"
    > #include "getfem_export.h"
    > #include "gmm.h"
    > #include "getfem_mesher.h"
    > #include "getfem_generic_assembly.h"
    >
    > using bgeot::size_type;
    > using bgeot::base_node;
    > using bgeot::base_small_vector;
    > typedef getfem::model_real_plain_vector plain_vector;
    >
    > int main(void) {
    >
    > bgeot::dim_type elements_degree = 2; // Degree of the finite
    element
    > methods
    >
    > }"
    > I don't understand what's happening, because I've tried command
    like
    > "gf_linsolve('mumps', spmat M, vec b)"  in the MatLab interface
    and it
    > worked.
    > Thank you for your time and help
    >
    > Best Regards,
    >
    > Nicolò Cambiaso


--
       Yves Renard ([email protected]
    <mailto:[email protected]>)      tel : (33) 04.72.43.87.08
       INSA-Lyon
       20, rue Albert Einstein
       69621 Villeurbanne Cedex, FRANCE
    http://math.univ-lyon1.fr/~renard

    ---------


--

  Yves Renard ([email protected])       tel : (33) 04.72.43.87.08
  INSA-Lyon
  20, rue Albert Einstein
  69621 Villeurbanne Cedex, FRANCE
  http://math.univ-lyon1.fr/~renard

---------

Reply via email to