-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add rotational inertial for kite (#100)
- Loading branch information
1 parent
104ae50
commit a8559a8
Showing
3 changed files
with
105 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,53 @@ | ||
using KiteModels | ||
using Test | ||
|
||
set = deepcopy(load_settings("system.yaml")) | ||
|
||
TEST_KCU = KCU(set) | ||
S = KPS4(TEST_KCU) | ||
|
||
@testset verbose=true "test_rotational_inertia" begin | ||
@testset "kite including KCU around CoM " begin | ||
Ixx, Ixy, Ixz, Iyy, Iyz, Izz = calculate_inertia_for_setting!(S, true, false) | ||
|
||
@test isapprox(Ixx, 124.53, rtol=0.005) | ||
@test isapprox(Ixy, 0, rtol=0.001) | ||
@test isapprox(Ixz, -8.805, rtol=0.007) | ||
@test isapprox(Iyy, 111.227, rtol=0.006) | ||
@test isapprox(Iyz, 0, rtol=0.001) | ||
@test isapprox(Izz, 19.516, rtol=0.001) | ||
end | ||
|
||
@testset "kite no KCU around CoM" begin | ||
Ixx, Ixy, Ixz, Iyy, Iyz, Izz = calculate_inertia_for_setting!(S, false, false) | ||
|
||
@test isapprox(Ixx, 21.5607, rtol=0.001) | ||
@test isapprox(Ixy, 0, rtol=0.001) | ||
@test isapprox(Ixz, 1.589, rtol=0.001) | ||
@test isapprox(Iyy, 7.2073, rtol=0.001) | ||
@test isapprox(Iyz, 0, rtol=0.001) | ||
@test isapprox(Izz, 18.4558, rtol=0.001) | ||
end | ||
|
||
@testset "kite including KCU around KCU" begin | ||
Ixx, Ixy, Ixz, Iyy, Iyz, Izz = calculate_inertia_for_setting!(S, true, true) | ||
|
||
@test isapprox(Ixx, 200.533, rtol=0.001) | ||
@test isapprox(Ixy, 0, rtol=0.001) | ||
@test isapprox(Ixz, -16.478, rtol=0.001) | ||
@test isapprox(Iyy, 188.004, rtol=0.001) | ||
@test isapprox(Iyz, 0, rtol=0.001) | ||
@test isapprox(Izz, 20.2907, rtol=0.001) | ||
end | ||
|
||
@testset "kite no KCU around KCU" begin | ||
Ixx, Ixy, Ixz, Iyy, Iyz, Izz = calculate_inertia_for_setting!(S, false, true) | ||
|
||
@test isapprox(Ixx, 200.533, rtol=0.001) | ||
@test isapprox(Ixy, 0, rtol=0.001) | ||
@test isapprox(Ixz, -16.478, rtol=0.001) | ||
@test isapprox(Iyy, 188.004, rtol=0.001) | ||
@test isapprox(Iyz, 0, rtol=0.001) | ||
@test isapprox(Izz, 20.2907, rtol=0.001) | ||
end | ||
end |