~asc/fluidity/iceshelfcavity

« back to all changes in this revision

Viewing changes to legacy_reservoir_prototype/README

  • Committer: Adam Candy
  • Date: 2011-10-12 20:39:04 UTC
  • Revision ID: adam.candy@imperial.ac.uk-20111012203904-9gwqzs4z798zcw0l
Automatic sync to launchpad

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
###################
2
 
#
3
 
# THIS CODE IS EXPERIMENTAL AND NOT PART OF THE MAIN FLUIDITY/ICOM DEVELOPMENT PROJECT
4
 
#
5
 
###################
6
 
 
7
 
 
8
 
Multiphase Prototype Brief Description
9
 
 
10
 
Within this directory there is:
11
 
 
12
 
     main.cpp
13
 
     Makefile.in
14
 
     src/
15
 
     tests/
16
 
     tools/
17
 
 
18
 
the src/ directory has the source code files that were needed in the
19
 
Makefile (note this is less than that previously as some code wasnt
20
 
actually being compiled)
21
 
 
22
 
the tools/ contains the python scripts
23
 
 
24
 
     MultiphasePrototype_Tools.py
25
 
     regressiontest.py
26
 
     testharness_MultiphasePrototype.py
27
 
 
28
 
the first one came from FETCH and the second two are
29
 
copies from the latest fluidity trunk in svn (as of 24th Nov 2010) - these are needed
30
 
to run a testharness. They contain a small change to the name of the
31
 
binary from fluidity to MultiphasePrototype.bin
32
 
 
33
 
the tests/ directory containstest cases such as:
34
 
 
35
 
     BL_test_10elements_1d/
36
 
 
37
 
which is the BL test which has been discussed in many of the MP meetings
38
 
 
39
 
tests/ also has a Makefile so that one can clean the tests/ directory of
40
 
all output (ie. from tests/ typing "make clean" will clean all test directories and
41
 
tests/). This requires the test name to be added to this makefile for this to work.
42
 
 
43
 
in each test directory (eg. BL_test_10elements_1d) there is
44
 
 
45
 
     Makefile
46
 
     BL_test_10elements_1d.xml
47
 
     other input files (ie. lots of .f90 functions and input.dat)
48
 
     perhaps a reference answer
49
 
 
50
 
the makefile prepares the input and will clean the directory. The .xml
51
 
will run the problem and do the pass/fail tests. To do these pass/fail
52
 
tests the xml will load the .py module in
53
 
 
54
 
     tools/MultiphasePrototype_Tools.py
55
 
 
56
 
to run all tests, from legacy_reservoir_prototype/ do:
57
 
 
58
 
     make test
59
 
 
60
 
this runs all tests and reports the outcome
61
 
 
62
 
these make commands are in the main Makefile. The command make test
63
 
calls the .py script
64
 
 
65
 
     tools/testharness_MultiphasePrototype.py
66
 
 
67
 
this uses the other script regressiontest.py and then goes to tests/ and
68
 
runs all appropriate tagged tests (deduced from inspecting the .xml
69
 
files in each test directory)
70
 
 
71
 
currently the BL test above is testing against a previously run answer
72
 
for the water saturation of each spatial dump (a regression test with a
73
 
very small tolerance)
74
 
 
75
 
thid is an example of how further test cases should be set up. Also to
76
 
run one test case (as a test), from Reservoir/multiphase_prototype/tests/
77
 
do:
78
 
 
79
 
     ../tools/testharness_MultiphasePrototype.py -f BL_test_10elements_1d.xml
80
 
 
81
 
Note that the testharness_MultiphasePrototype.py input name
82
 
is the .xml file within the test case directory not the actual test case directory name
83
 
 
84
 
Therefore to do a clean make and run all that should be working tests do:
85
 
 
86
 
     make superclean
87
 
     make
88
 
     make test
89
 
 
90
 
Or the command to do the above three sequential is possible through
91
 
 
92
 
     make all
93
 
     
94
 
make sure test cases pass first before svn committing changes
95
 
 
96
 
if one wants to commit a test case that is not fully working yet then in the .xml file change the 
97
 
 
98
 
     <problem_definition length="short" nprocs="1">
99
 
  
100
 
to
101
 
 
102
 
     <problem_definition length="special" nprocs="1">
103
 
  
104
 
"short" is a keyword the testharness will pick up, special means the test case is ignored. When the test case
105
 
is fully working make sure that "short" is included back such that the new test case will run with 
106
 
 
107
 
     make test
108
 
 
109
 
 
110
 
********************************
111
 
 
112
 
TO CREATE THE Makefile from Makefile.in (Makefile is no longer in the repository)
113
 
cd .. (to the fluidity trunk directory)
114
 
./configure
115
 
 
116
 
TO COMPILE THE CODE, including the fluidity library on which this code now depends
117
 
make mp (from the fluidity trunk directory)