initial upload

This commit is contained in:
2025-12-17 11:00:57 +08:00
parent 2bc7b24a71
commit a09a73537f
4614 changed files with 3478433 additions and 2 deletions

View File

@@ -0,0 +1,178 @@
# LaGriT Test 2D smooth and massage
# read the line polygon and triangulate
# mesh object must be planar
# uncomment dump/avs for further evaluations
read avs input_polygon.inp moin
cmo / printatt/ moin / -xyz- / minmax
cmo create cmotri///triplane
copypts cmotri moin
cmo /delete/ moin
cmo select cmotri
# RUN 00 triangulate
# triangulate inside the polygon
triangulate/clockwise
cmo setatt cmotri imt 1
cmo setatt cmotri itetclr 1
resetpts/ itp
# CHECK 00 coarse triangulation
quality
quality edge_max y
# dump avs out_tri00.inp cmotri
# RUN 01 refine edge 1000
# break into triangles of nicer sizes
define EDGELEN 1000.
refine rivara///edge/1,0,0/EDGELEN///inclusive
# CHECK 01 refine edge 1000
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# dump avs out_tri01a.inp cmotri
# RUN 01b smooth
# smooth to make nice distribution
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
filter/1,0,0
rmpoint compress
resetpts / itp
# dump avs out_tri01b.inp cmotri
# CHECK 01b smooth esug
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# RUN 02 massage 200
define MAXEDGE 300.
define MINEDGE 100.
define DAMAGE .01
massage/MAXEDGE MINEDGE DAMAGE /1,0,0/
rmpoint compress
# CHECK 02 massage 200
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# dump avs out_tri02a.inp cmotri
# RUN 02b smooth 200
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
# CHECK 02b smooth after massage
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# dump avs out_tri02b.inp cmotri
rmpoint compress
resetpts itp
pset/pedge/attribute itp/1,0,0/ ge 10
cmo create cmotmp; copypts/cmotmp/cmotri/0 0/pset,get,pedge
compute/distance_field/cmotri/ cmotmp/ dfield
cmo / delete/ cmotmp
cmo select cmotri
# RUN 03 massage de-refine 600
# select nodes inside mesh to massage
define MAXEDGE 1200.
define MINEDGE 600.
define DAMAGE .01
pset/pmass/attribute dfield/1,0,0/ gt 800.
massage /MAXEDGE MINEDGE DAMAGE /pset,get,pmass/ nosmooth
rmpoint compress
# CHECK 03 massage de-refine
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# dump avs out_tri03a.inp cmotri
# RUN 03b smooth after de-refine
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
# CHECK 03b smooth after de-refine
quality
quality edge_max y
quality aspect y
cmo/addatt/ cmotri / ang_mind / ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
# dump avs out_tri03b.inp cmotri
# RUN 04 massage merge small edges
define MAXEDGE 1.e+20
define MINEDGE .1
define DAMAGE .1
massage /MAXEDGE MINEDGE DAMAGE /1,0,0/
rmpoint compress
resetpts itp
# CHECK 04 massage merge small edges
quality
quality edge_max y
quality aspect y
cmo/addatt/ cmotri / ang_mind / ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
# dump avs out_tri04a.inp cmotri
# RUN 04b smooth after massage merge
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
filter/1,0,0
rmpoint compress
resetpts / itp
# CHECK 04b smooth after massage merge
quality
quality edge_max y
quality aspect y
cmo/addatt/ cmotri / ang_mind / ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
cmo printatt cmotri edgemax minmax
# dump avs out_tri04b.inp cmotri
# RUN FINAL reconnect delaunay
recon/ 1 /
# CHECK FINAL triangulation
quality
quality edge_max y
quality aspect y
cmo/addatt/ cmotri / ang_mind / ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
dump avs out_final.inp cmotri
cmo printatt cmotri -all- minmax
finish

View File

@@ -0,0 +1,15 @@
7 7 0 0
1 10000. 10000. 0.
2 15000. 5000. 0.
3 20000. 5000. 0.
4 20000. 0. 0.
5 0. 0. 0.
6 0. 5000. 0.
7 5000. 5000. 0.
1 1 line 1 2
2 1 line 2 3
3 1 line 3 4
4 1 line 4 5
5 1 line 5 6
6 1 line 6 7
7 1 line 7 1

View File

@@ -0,0 +1,178 @@
# LaGriT Test 2D smooth and massage
# read the line polygon and triangulate
# mesh object must be planar
# uncomment dump/avs for further evaluations
read avs input_polygon.inp moin
cmo / printatt/ moin / -xyz- / minmax
cmo create cmotri///triplane
copypts cmotri moin
cmo /delete/ moin
cmo select cmotri
# RUN 00 triangulate
# triangulate inside the polygon
triangulate/clockwise
cmo setatt cmotri imt 1
cmo setatt cmotri itetclr 1
resetpts/ itp
# CHECK 00 coarse triangulation
quality
quality edge_max y
# dump avs out_tri00.inp cmotri
# RUN 01 refine edge 1000
# break into triangles of nicer sizes
define EDGELEN 1000.
refine rivara///edge/1,0,0/EDGELEN///inclusive
# CHECK 01 refine edge 1000
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# dump avs out_tri01a.inp cmotri
# RUN 01b smooth
# smooth to make nice distribution
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
filter/1,0,0
rmpoint compress
resetpts / itp
# dump avs out_tri01b.inp cmotri
# CHECK 01b smooth esug
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# RUN 02 massage 200
define MAXEDGE 300.
define MINEDGE 100.
define DAMAGE .01
massage/MAXEDGE MINEDGE DAMAGE /1,0,0/
rmpoint compress
# CHECK 02 massage 200
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# dump avs out_tri02a.inp cmotri
# RUN 02b smooth 200
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
# CHECK 02b smooth after massage
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# dump avs out_tri02b.inp cmotri
rmpoint compress
resetpts itp
pset/pedge/attribute itp/1,0,0/ ge 10
cmo create cmotmp; copypts/cmotmp/cmotri/0 0/pset,get,pedge
compute/distance_field/cmotri/ cmotmp/ dfield
cmo / delete/ cmotmp
cmo select cmotri
# RUN 03 massage de-refine 600
# select nodes inside mesh to massage
define MAXEDGE 1200.
define MINEDGE 600.
define DAMAGE .01
pset/pmass/attribute dfield/1,0,0/ gt 800.
massage /MAXEDGE MINEDGE DAMAGE /pset,get,pmass/ nosmooth
rmpoint compress
# CHECK 03 massage de-refine
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
# dump avs out_tri03a.inp cmotri
# RUN 03b smooth after de-refine
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
# CHECK 03b smooth after de-refine
quality
quality edge_max y
quality aspect y
cmo/addatt/ cmotri / ang_mind / ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
# dump avs out_tri03b.inp cmotri
# RUN 04 massage merge small edges
define MAXEDGE 1.e+20
define MINEDGE .1
define DAMAGE .1
massage /MAXEDGE MINEDGE DAMAGE /1,0,0/
rmpoint compress
resetpts itp
# CHECK 04 massage merge small edges
quality
quality edge_max y
quality aspect y
cmo/addatt/ cmotri / ang_mind / ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
# dump avs out_tri04a.inp cmotri
# RUN 04b smooth after massage merge
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
filter/1,0,0
rmpoint compress
resetpts / itp
# CHECK 04b smooth after massage merge
quality
quality edge_max y
quality aspect y
cmo/addatt/ cmotri / ang_mind / ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
cmo printatt cmotri edgemax minmax
# dump avs out_tri04b.inp cmotri
# RUN FINAL reconnect delaunay
recon/ 1 /
# CHECK FINAL triangulation
quality
quality edge_max y
quality aspect y
cmo/addatt/ cmotri / ang_mind / ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
dump avs out_final.inp cmotri
cmo printatt cmotri -all- minmax
finish

View File

@@ -0,0 +1,15 @@
7 7 0 0
1 10000. 10000. 0.
2 15000. 5000. 0.
3 20000. 5000. 0.
4 20000. 0. 0.
5 0. 0. 0.
6 0. 5000. 0.
7 5000. 5000. 0.
1 1 line 1 2
2 1 line 2 3
3 1 line 3 4
4 1 line 4 5
5 1 line 5 6
6 1 line 6 7
7 1 line 7 1

View File

@@ -0,0 +1,116 @@
read avs input_polygon.inp moin
cmo/printatt/moin/-xyz-/minmax
cmo create cmotri///triplane
copypts cmotri moin
cmo/delete/moin
cmo select cmotri
triangulate/clockwise
cmo setatt cmotri imt 1
cmo setatt cmotri itetclr 1
resetpts/itp
quality
quality edge_max y
define EDGELEN 1000.
refine rivara///edge/1,0,0/EDGELEN///inclusive
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
filter/1,0,0
rmpoint compress
resetpts/itp
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
define MAXEDGE 300.
define MINEDGE 100.
define DAMAGE .01
massage/MAXEDGE MINEDGE DAMAGE/1,0,0/
rmpoint compress
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
rmpoint compress
resetpts itp
pset/pedge/attribute itp/1,0,0/ge 10
cmo create cmotmp
copypts/cmotmp/cmotri/0 0/pset,get,pedge
compute/distance_field/cmotri/cmotmp/dfield
cmo/delete/cmotmp
cmo select cmotri
define MAXEDGE 1200.
define MINEDGE 600.
define DAMAGE .01
pset/pmass/attribute dfield/1,0,0/gt 800.
massage/MAXEDGE MINEDGE DAMAGE/pset,get,pmass/nosmooth
rmpoint compress
quality
quality edge_max y
cmo printatt cmotri edgemax minmax
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
quality
quality edge_max y
quality aspect y
cmo/addatt/cmotri/ang_mind/ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
define MAXEDGE 1.e+20
define MINEDGE .1
define DAMAGE .1
massage/MAXEDGE MINEDGE DAMAGE/1,0,0/
rmpoint compress
resetpts itp
quality
quality edge_max y
quality aspect y
cmo/addatt/cmotri/ang_mind/ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
cmo select cmotri
smooth/position/esug/1 0 0
recon 0
smooth/position/esug/1 0 0
recon 0
filter/1,0,0
rmpoint compress
resetpts/itp
quality
quality edge_max y
quality aspect y
cmo/addatt/cmotri/ang_mind/ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
cmo printatt cmotri edgemax minmax
recon/1/
quality
quality edge_max y
quality aspect y
cmo/addatt/cmotri/ang_mind/ang_mind
cmo printatt cmotri edgemax minmax
cmo printatt cmotri aratio minmax
cmo printatt cmotri ang_mind minmax
dump avs out_final.inp cmotri
cmo printatt cmotri -all- minmax
finish

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,32 @@
7 5 4 1 0
001 1.000000000000E+04 1.000000000000E+04 0.000000000000E+00
002 1.500000000000E+04 5.000000000000E+03 0.000000000000E+00
003 2.000000000000E+04 5.000000000000E+03 0.000000000000E+00
004 2.000000000000E+04 0.000000000000E+00 0.000000000000E+00
005 0.000000000000E+00 0.000000000000E+00 0.000000000000E+00
006 0.000000000000E+00 5.000000000000E+03 0.000000000000E+00
007 5.000000000000E+03 5.000000000000E+03 0.000000000000E+00
001 1 tri 2 3 4
002 1 tri 4 5 6
003 1 tri 4 6 7
004 1 tri 2 4 7
005 1 tri 1 2 7
00004 1 1 1 1
imt1, integer
itp1, integer
icr1, integer
isn1, integer
1 1 10 0 0
2 1 10 0 0
3 1 10 0 0
4 1 10 0 0
5 1 10 0 0
6 1 10 0 0
7 1 10 0 0
00001 1
edgemax, real
1 0.707106781187E+04
2 0.206155281281E+05
3 0.206155281281E+05
4 0.158113883008E+05
5 0.100000000000E+05

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 457 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 452 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 470 KiB