diff --git a/Usecases/README.md b/Usecases/README.md index 284ebbbb2b21d0084d9c9f5892b8fa6f1428f901..41eabba408337b8be3a12489bdf7ae40a66ef85e 100644 --- a/Usecases/README.md +++ b/Usecases/README.md @@ -31,4 +31,27 @@ and update that copy with information in the obsolete scripts. In order to create a new usecase, either modify one of the existing ones, or copy one of the existing cases into a new file and start working on your own. To understand how usecases are set up, let's have a look at the file -[TP-R-2-patch-test.py](./Two-Phase-Richards/two-patch/TP-R-two-patch-test-case). +`TP-R-2-patch-test.py` in +[Two-Phase-Richards/two-patch/TP-R-two-patch-test-case/](./Two-Phase-Richards/two-patch/TP-R-two-patch-test-case/). +Each script is broken into certain parts, which we explain in what follows. + +### PREREQUISITS +~~~python3 +# PREREQUISITS ############################################################### +# check if output directory "./output" exists. This will be used in +# the generation of the output string. +if not os.path.exists('./output'): + os.mkdir('./output') + print("Directory ", './output', " created ") +else: + print("Directory ", './output', " already exists. Will use as output \ + directory") + +date = datetime.datetime.now() +datestr = date.strftime("%Y-%m-%d") + +# Name of the usecase that will be printed during simulation. +use_case = "TPR-2-patch-realistic-testrun" +# The name of this very file. Needed for creating log output. +thisfile = "TP-R-2-patch-test.py" +~~~