Skip to content

Commit 08fbba3

Browse files
committed
add P1ncS and add too in CHANGELOG.md, and update plugin/seq/Makefile.am
1 parent 55389f7 commit 08fbba3

4 files changed

Lines changed: 30 additions & 12 deletions

File tree

AutoGeneratedFile.tar.gz

14 Bytes
Binary file not shown.

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ All notable changes to this project will be documented in this file.
2626

2727
### Added
2828

29-
- Element P1nc3d (crouzeix Raviart) in plugin Element_P1nc_3d
29+
- Element P1nc3d (crouzeix Raviart) in plugin Element_P1nc_3d in 3d and in Surface (meshS)
3030
and the test is testFE-P1nc3d.edp
3131

3232
### Changed

examples/plugin/testFE-P1nc3d.edp

Lines changed: 26 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,13 @@
11
load "Element_P1nc_3d"
2+
{ // 3d
23
mesh3 Th=cube(10,10,10);
34
macro grad(u) [dx(u),dy(u),dz(u)]//
4-
5+
func f = x+2*y+3*z;
56
fespace Vh(Th,P1nc3d);
67
fespace Wh(Th,P0face3d);
78
cout << " Vh ndof "<< Vh.ndof << " == " << Wh.ndof << endl;
89
Vh u,v;
9-
Vh X,Y,Z;
10-
/*X = x;
11-
Y = y;
12-
Z = z;
13-
cout << X << endl;
14-
cout << Y << endl;
15-
cout << Z << endl; */
16-
func f = x+2*y+3*z;
10+
1711

1812
u = f;
1913
cout << " err L1 : " << int3d(Th)( abs(f-u)) << endl;
@@ -23,4 +17,26 @@ plot(u,wait=1);
2317
int[int] labs = labels(Th);
2418
solve Pb(u,v)= int3d(Th)(grad(u)'*grad(v))- int3d(Th)(v)+ on(labs,u=0);
2519
plot(u,wait=1);
26-
cout << " u max "<< u[] .max << endl;
20+
cout << " u max "<< u[] .max << endl;
21+
}
22+
23+
{ // Surf.
24+
meshS Th=square3(10,10);
25+
macro grad(u) [dx(u),dy(u),dz(u)]//
26+
func f = x+ 2*y;
27+
fespace Vh(Th,P1ncS);
28+
fespace Wh(Th,P0edgeS);
29+
cout << " Vh ndof "<< Vh.ndof << " == " << Wh.ndof << endl;
30+
Vh u,v;
31+
32+
33+
u = f;
34+
cout << "2Surf err L1 : " << int2d(Th)( abs(f-u)) << endl;
35+
plot(u,wait=1);
36+
37+
38+
int[int] labs = labels(Th);
39+
solve Pb(u,v)= int2d(Th)(grad(u)'*grad(v))- int2d(Th)(v)+ on(labs,u=0);
40+
plot(u,wait=1);
41+
cout << " u max "<< u[].max << endl;
42+
}

plugin/seq/Makefile.am

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ LIST_COMPILE=myfunction.$(DYLIB_SUFFIX) BernardiRaugel.$(DYLIB_SUFFIX) \
5252
geophysics.$(DYLIB_SUFFIX) CircumCenter.$(DYLIB_SUFFIX) MatD-VFP0.$(DYLIB_SUFFIX) \
5353
meshtools.$(DYLIB_SUFFIX) Helmholtz_FD.$(DYLIB_SUFFIX) Element_P3pnc.$(DYLIB_SUFFIX) \
5454
vortextools.$(DYLIB_SUFFIX) MatrixMarket.$(DYLIB_SUFFIX) Element_P3nc.$(DYLIB_SUFFIX) \
55-
plotPDF.$(DYLIB_SUFFIX) Element_P2pnc_3d.$(DYLIB_SUFFIX) Element_P3pnc_3d.$(DYLIB_SUFFIX)
55+
plotPDF.$(DYLIB_SUFFIX) Element_P2pnc_3d.$(DYLIB_SUFFIX) Element_P3pnc_3d.$(DYLIB_SUFFIX) \
56+
Element_P1nc_3d.$(DYLIB_SUFFIX)
57+
5658

5759
# FFCS - some libraries are skipped because the corresponding tool is deactivated.
5860

0 commit comments

Comments
 (0)