[32a023]: obsolete / fem_init_env.cc Maximize Restore History

Download this file

fem_init_env.cc    57 lines (49 with data), 1.8 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
/*
Copyright (C) 2013 Marco Vassallo
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Foundation; either version 2 of the License, or (at your option) any later
version.
This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
this program; if not, see <http://www.gnu.org/licenses/>.
*/
#include "mesh.h"
#include "functionspace.h"
#include "boundarycondition.h"
#include "coefficient.h"
#include "function.h"
DEFUN_DLD (fem_init_env, args, , "-*- texinfo -*-\n\
@deftypefn {Function File} {[]} = \
fem_init_env ( ) \n\
Initialize the environment for fem-fenics\n\
@end deftypefn")
{
int nargin = args.length ();
octave_value retval;
if (nargin < 0 || nargin > 0)
print_usage ();
else
{
mesh::register_type ();
mesh_type_loaded = true;
std::cout << "mesh_type_loaded" << std::endl;
functionspace::register_type ();
functionspace_type_loaded = true;
std::cout << "functionspace_type_loaded" << std::endl;
boundarycondition::register_type ();
boundarycondition_type_loaded = true;
std::cout << "boundarycondition_type_loaded" << std::endl;
coefficient::register_type ();
coefficient_type_loaded = true;
std::cout << "coefficient_type_loaded" << std::endl;
function::register_type ();
function_type_loaded = true;
std::cout << "function_type_loaded" << std::endl;
mlock ();
}
return retval;
}