Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add FMU participants to oscillator tutorial #466

Merged
merged 42 commits into from
Mar 15, 2024
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
4c92b98
Add FMU example. Exchanged data switches from 'Force' to 'Displacement'.
Feb 5, 2023
42884c1
Update README
Feb 5, 2023
d7fee6c
Update README.md
LeonardWilleke Feb 5, 2023
8209447
Use Oscillator.fmu and force-force exchange
Feb 17, 2023
a4ee334
Adapt README.md
Feb 17, 2023
d32e15e
Adapt README.md
Feb 17, 2023
bf5b8aa
Minor changes to runner.py
Feb 17, 2023
fce783e
Update FMU model and README.md
Feb 21, 2023
a70d411
Update make files to allow compilation as FMI 1, 2 and 3
Feb 22, 2023
2b3157f
Implement requested changes
Mar 31, 2023
9849995
Adapt case to use fmiprecice instead of local runner script
Apr 12, 2023
f17125e
Update License and README, do cosmetic changes on code
Apr 16, 2023
9a22c67
Adapt makefile to include LICENSE in FMU
Apr 18, 2023
8ab4529
Update Python oscillator to precice v3
Jul 25, 2023
0fd3bd9
Add link to reference
Jan 25, 2024
3db4327
Merge branch 'develop' into create-fmu-oscillator-v3
uekerman Feb 21, 2024
2e9f61d
Use python oscillator from develop
uekerman Feb 21, 2024
11072ae
Adjust precice-settings.json to v3 runner
uekerman Feb 21, 2024
35d6adb
Tweak README
uekerman Feb 22, 2024
a1d38be
Make pre-commit work for Ubuntu 20.04
uekerman Feb 22, 2024
2f05209
Make md linter happy
uekerman Feb 22, 2024
ef0ea11
Format all FMI xml files
uekerman Feb 22, 2024
c892903
Format code
uekerman Feb 26, 2024
cb5137d
Format code
uekerman Feb 26, 2024
fba9c9a
Merge branch 'develop' into create-fmu-oscillator-v3
MakisH Mar 11, 2024
98adffd
Update oscillator/README.md
MakisH Mar 11, 2024
2e57756
Oscillator: Move license
MakisH Mar 11, 2024
53b8c5c
Update link to license in CMakeLists.txt
MakisH Mar 11, 2024
47b0904
Remove binary FMU, replace with automatic building in run
uekerman Mar 12, 2024
960a588
Format all FMU C code
uekerman Mar 12, 2024
558fac4
Remove duplicate FMU readme.html
MakisH Mar 13, 2024
94ba065
Merge branch 'develop' into create-fmu-oscillator-v3
MakisH Mar 13, 2024
1f9a2b4
Add FMU readme.html again
MakisH Mar 13, 2024
e5e8e5d
Delete duplicate FMU readme.md
MakisH Mar 13, 2024
4517bbd
Change causality of mass.a to local, fix CATIA bug
uekerman Mar 14, 2024
af91d46
Fix spelling of state attributes in FMI3
uekerman Mar 14, 2024
11cc439
Remove FMI1 config files
uekerman Mar 14, 2024
99d3c8a
Switch to FMI3 again
uekerman Mar 14, 2024
6a57614
Increase accuracy of material params and initial cond
uekerman Mar 14, 2024
e29dd45
Merge branch 'develop' into create-fmu-oscillator-v3
MakisH Mar 15, 2024
945836a
Remove more FMI1 things
uekerman Mar 15, 2024
39272a8
Merge branch 'develop' into create-fmu-oscillator-v3
MakisH Mar 15, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions oscillator/fmi/MassLeft/fmi-settings.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"model_params": {
"mass.m": 1,
"spring_fixed.c": 39.478,
"spring_middle.c": 157.914
"spring_fixed.c": 39.4784176044,
"spring_middle.c": 157.913670417
},
"initial_conditions": {
"mass.u": 1,
"mass.v": 0,
"mass.a": -197.392
"mass.a": -197.392088022
},
"simulation_params": {
"fmu_file_name": "./Oscillator.fmu",
Expand Down
6 changes: 3 additions & 3 deletions oscillator/fmi/MassRight/fmi-settings.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"model_params": {
"mass.m": 1,
"spring_fixed.c": 39.478,
"spring_middle.c": 157.914
"spring_fixed.c": 39.4784176044,
"spring_middle.c": 157.913670417
},
"initial_conditions": {
"mass.u": 0,
"mass.v": 0,
"mass.a": 157.914
"mass.a": 157.913670417
},
"simulation_params": {
"fmu_file_name": "./Oscillator.fmu",
Expand Down
109 changes: 0 additions & 109 deletions oscillator/fmi/fmu/Oscillator/FMI1CS.xml

This file was deleted.

103 changes: 0 additions & 103 deletions oscillator/fmi/fmu/Oscillator/FMI1ME.xml

This file was deleted.

2 changes: 1 addition & 1 deletion oscillator/fmi/fmu/Oscillator/FMI2.xml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@
<ScalarVariable
name="mass.a"
valueReference="4"
causality="parameter"
causality="local"
uekerman marked this conversation as resolved.
Show resolved Hide resolved
variability="tunable"
initial="calculated"
description="Acceleration of the body">
Expand Down
6 changes: 3 additions & 3 deletions oscillator/fmi/fmu/Oscillator/FMI3.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@

<CoSimulation
modelIdentifier="Oscillator"
canGetAndSetFMUstate="true"
canSerializeFMUstate="false"
canGetAndSetFMUState="true"
canSerializeFMUState="false"
canHandleVariableCommunicationStepSize="true"
providesIntermediateUpdate="false"
canReturnEarlyAfterIntermediateUpdate="false"
Expand Down Expand Up @@ -97,7 +97,7 @@
<Float64
name="mass.a"
valueReference="4"
causality="parameter"
causality="local"
variability="tunable"
initial="calculated"
unit="m/s2"
Expand Down
3 changes: 0 additions & 3 deletions oscillator/fmi/fmu/Oscillator/readme.md

This file was deleted.

1 change: 1 addition & 0 deletions oscillator/fmi/run.sh
MakisH marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ if [ ! -f Oscillator.fmu ]; then
rm -rf build
mkdir build
cd build
# Both FMI_VERSION=3 and FMI_VERSION=2 are supported
cmake -DFMI_TYPE=CS -DFMI_VERSION=3 ..
make
cp ./Oscillator.fmu ../..
Expand Down