Bård Skaflestad
14f2011baa
Add MEX auto-build support for function 'mex_generate_coarsegrid'.
2010-08-30 21:43:39 +00:00
Bård Skaflestad
e0c6e24ab7
Correct a number of small, but crucial, mistakes:
...
- Initialise new neighbours to INT_MIN rather than -1. The latter
is a valid block (the outside) and it is better to properly
distinguish unset values from boundary blocks.
- Ensure NULL-initialisation of a block's neighbour structure when
this structure has just been allocated.
- Adjust bin-search algorithm to support i==nneigh (target larger
than all existing neighbouring blocks).
- This means that if i==nneigh, then we must take precaution so as
not to reference any invalid table elements. However, an
explicit check for i<nneigh means that the semantics of the
memmove() statement becomes more transparent.
- Finally, we must properly assign the 'nblocks' and 'nfaces'
fields of the struct coarse_topology before returning to caller.
2010-08-30 21:42:52 +00:00
Bård Skaflestad
9cdeab3f04
For the pow2(n)'th time: MATLAB indices are one-based...
2010-08-30 21:32:49 +00:00
Bård Skaflestad
f7fe7325b8
Add MEX gateway to C subroutine for generating coarse-grid topologies.
2010-08-30 16:52:20 +00:00
Bård Skaflestad
9cd8f309c3
Announce and implement the public interface for deriving coarse-grid
...
topology from a fine-grid topology and a partition vector.
2010-08-30 16:51:25 +00:00
Bård Skaflestad
ecc86b8c06
Change name of independent makefile to something which does not break
...
dune-<mumble> builds.
2010-08-30 09:10:25 +00:00
Jostein R. Natvig
1d991e26e5
Add alternative interface and makefile that builds library.
2010-08-30 08:37:37 +00:00
Jostein R. Natvig
ad938d1bcb
Whitespace.
2010-08-30 08:36:51 +00:00
Bård Skaflestad
424e919a64
Correctly define the 'b' field of a new block-to-block coarse-scale
...
connection.
2010-08-29 22:00:03 +00:00
Bård Skaflestad
2391437b3b
Add first, untested, edition of code for creating and updating a
...
block-to-block coarse-scale connection with optional fine-scale
constituents.
2010-08-29 21:54:11 +00:00
Bård Skaflestad
3d316e6279
Insert summary comments.
2010-08-29 20:01:43 +00:00
Jostein R. Natvig
a2e14eb19d
Add emacs local variables.
2010-08-27 17:12:16 +00:00
Bård Skaflestad
1489e72bc4
Stop-gap implementation of coarse-to-fine connection topology.
...
Unfinished.
2010-08-27 12:35:13 +00:00
Bård Skaflestad
0c6a564cbb
Move hash.c to coarse_conn.c to reflect new responsibilities.
2010-08-27 08:52:00 +00:00
Bård Skaflestad
ae8742b692
Usurp public hash table interface into hash.c . The module is
...
created for a single purpose: A poor-man's replacement for a
hash-set used in deriving coarse-grid connections from fine-scale
connectivity.
2010-08-27 07:37:49 +00:00
Bård Skaflestad
ecb9f57632
Remove a file whose purpose was entirely unclear. Sorry about the churn.
2010-08-27 06:56:34 +00:00
Bård Skaflestad
60755c9f1e
Add initial infrastructure for deriving coarse grid connections from
...
a fine-scale neighbourship definition.
2010-08-26 16:58:21 +00:00
Bård Skaflestad
8dc4adbe51
Move solvers/common solvers/euler and solvers/mimetic to dune-porsol
2010-08-23 09:23:09 +00:00
Bård Skaflestad
c2411ab098
Add MEX auto-build support for function 'mex_partition_process'.
2010-08-20 21:45:30 +00:00
Bård Skaflestad
4b7a67de8e
Silence compiler by adding prototype for dfs() (i.e., #include
...
"dfs.h"). Also, don't require build(er|system) to always #define
the preprocessing symbol "TEST" (to a zero or non-zero value).
2010-08-20 21:44:49 +00:00
Bård Skaflestad
23eebb5d2c
Assert copyright for 2010.
2010-08-20 19:16:59 +00:00
Bård Skaflestad
ce6016c9b1
M-x delete-trailing-whitespace .
2010-08-20 19:05:27 +00:00
Bård Skaflestad
66369d49ff
Correct a supremely embarrassing typo: When counting the number of
...
cell-to-cell connections (i.e., when calling count_block_conns()),
inspect the pointer array (pc2c) rather than the cell array itself
(c2c). Clue-by-four supplied by gdb(1).
Move self connection handling to partition_create_c2c().
Adjust dfs() 'work' array size to comply with new requirements of
-r5088.
2010-08-20 17:24:26 +00:00
Bård Skaflestad
7645981d14
Adjust for M's 1-based indexing in the 'neighbours' connection
...
array [%]
Assign results to plhs[0] (and print diagnostic).
2010-08-20 17:19:37 +00:00
Jostein R. Natvig
87949a432e
Fix embarrasing error.
2010-08-20 14:18:22 +00:00
Bård Skaflestad
9ca7ff4191
Add files missing in -c5083.
...
Pointy hat: bska
2010-08-19 22:30:54 +00:00
Bård Skaflestad
58a79e9f4d
Install support for creating block-internal connection structures.
...
Not functional atm.
2010-08-19 22:30:10 +00:00
Bård Skaflestad
9ba8749ed8
The file 'partition.c' now depends on 'dfs.c'. Add to build system.
2010-08-19 22:29:12 +00:00
Bård Skaflestad
b160856ec3
Add stub implementation of algorithm for splitting blocks.
...
Currently lacks the construction of block-internal connections but
does at least build.
Not tested.
2010-08-19 16:33:13 +00:00
Jostein R. Natvig
bea6bcaccb
Four-space indentation.
2010-08-19 11:02:50 +00:00
Jostein R. Natvig
fe319fbbef
Add comment.
2010-08-19 10:52:10 +00:00
Jostein R. Natvig
4519ce2b7c
A depth-first graph traversal to find connected components of graph.
2010-08-19 10:46:58 +00:00
Bård Skaflestad
5b673a4960
Be more explicit on the significance of the start pointers for 1:nbin.
2010-08-18 19:16:14 +00:00
Bård Skaflestad
28e6e730db
Implicit int went the way of the dodo in 1999. Catch up to this fact.
2010-08-18 16:22:35 +00:00
Bård Skaflestad
a0f013e05f
Provide an H1 lines in closer proximity to reality.
2010-08-18 15:08:13 +00:00
Bård Skaflestad
d12bc05d86
Add MEX support for inverting cell-to-block mappings (i.e.,
...
partition vectors) to create block-to-cell mappings.
2010-08-18 15:04:33 +00:00
Bård Skaflestad
a98073072f
Update to new hybsys_* calling conventions.
2010-08-18 09:04:34 +00:00
Bård Skaflestad
be27b881e2
Remove unused variables.
2010-08-18 08:55:14 +00:00
Bård Skaflestad
4013dec710
Support empty grids.
2010-08-18 08:50:26 +00:00
Bård Skaflestad
1f8773b5e7
Solve the "No Type" problem more generally.
2010-08-18 08:46:56 +00:00
Bård Skaflestad
e7155b332a
Add documentation, support multiple grid components and '.type' field.
2010-08-18 08:37:40 +00:00
Bård Skaflestad
8df4a5f14b
Add rudimentary MEX support for computing non-symmetric (i.e.,
...
compressible) cell contributions.
2010-08-18 08:19:36 +00:00
Bård Skaflestad
47abc777e7
Aesthetics. Check malloc() status in same sequence as attempted
...
field allocations.
2010-08-18 07:07:07 +00:00
Bård Skaflestad
2e667bcfee
Remove EOL whitespace overlooked in r5056.
2010-08-17 15:48:15 +00:00
Bård Skaflestad
b1b6b18a4a
Add preliminary support for unsymmetric system contributions. This
...
is needed to implement compressible pressure solvers.
2010-08-17 15:37:06 +00:00
Jostein R. Natvig
991851bd9e
Add local variables and whitespace changes.
2010-08-17 07:20:12 +00:00
Bård Skaflestad
fed728d127
"matrix.h" is transitively available through <mex.h>, so there is no
...
need to explicitly #include this file.
2010-08-17 06:57:39 +00:00
Bård Skaflestad
8e6c3ca6a2
Generate optimised code now that the basic functionality is tested.
2010-08-16 13:18:31 +00:00
Bård Skaflestad
2e0af739fd
Remove unneeded header.
2010-08-16 09:28:15 +00:00
Bård Skaflestad
479e8cde82
Add MEX gateway forgotten in r5048.
...
Pointy hat: bska
2010-08-16 09:27:52 +00:00