-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added new interfaces for inputs (#733)
* Removed 2> log for test files. * Re-organize input and output. Added patchVelocity * Added dF back for patchVelocity. * Enabled CD and CL based on AOA. * Enabled auto make mode. * Print info for DAInput and calcJac. * Changed designVar to solverInput and re-organized all partial calls.
- Loading branch information
Showing
40 changed files
with
970 additions
and
845 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,43 @@ | ||
#!/usr/bin/env bash | ||
|
||
# the script will exit if there is any error | ||
set -e | ||
|
||
if [ -z "$WM_PROJECT" ]; then | ||
echo "OpenFOAM environment not found, forgot to source the OpenFOAM bashrc?" | ||
exit 1 | ||
fi | ||
|
||
wmakeLnInclude src/adjoint | ||
cd src/adjoint && ./Allmake && cd - | ||
cd src/pyUnitTests && ./Allmake && cd - | ||
cd src/pyDASolvers && ./Allmake && cd - | ||
cd src/utilities/coloring && ./Allmake && cd - | ||
echo "******* DAFoam $WM_CODI_AD_LIB_POSTFIX compilation finished! *********" | ||
function makeDAFoam() | ||
{ | ||
# the script will exit if there is any error | ||
set -e | ||
wmakeLnInclude src/adjoint | ||
cd src/adjoint && ./Allmake && cd - | ||
cd src/pyUnitTests && ./Allmake && cd - | ||
cd src/pyDASolvers && ./Allmake && cd - | ||
cd src/utilities/coloring && ./Allmake && cd - | ||
# disable the -e flag | ||
set +e | ||
} | ||
|
||
# compile original mode | ||
echo "***************** Compiling original mode **************" | ||
. $DAFOAM_ROOT_PATH/loadDAFoam.sh | ||
makeDAFoam | ||
# compile ADR mode | ||
echo "***************** Compiling ADR mode **************" | ||
. $DAFOAM_ROOT_PATH/loadDAFoam.sh | ||
. $DAFOAM_ROOT_PATH/OpenFOAM/OpenFOAM-v1812-ADR/etc/bashrc | ||
makeDAFoam | ||
# if COMPILE_DAFOAM_ADF is set, compile ADF mode | ||
if [ -z "$COMPILE_DAFOAM_ADF" ]; then | ||
echo "COMPILE_DAFOAM_ADF is not set. skip the ADF mode" | ||
else | ||
echo "***************** Compiling ADF mode **************" | ||
. $DAFOAM_ROOT_PATH/loadDAFoam.sh | ||
. $DAFOAM_ROOT_PATH/OpenFOAM/OpenFOAM-v1812-ADF/etc/bashrc | ||
makeDAFoam | ||
fi | ||
|
||
# reset the OpenFOAM environment to the original mode | ||
. $DAFOAM_ROOT_PATH/loadDAFoam.sh | ||
|
||
pip install . |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.