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

SD: Implementing directional cosine matrices and section properties for rectangular members #1413

Merged
merged 21 commits into from
Apr 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
207bfd1
hacky updates for cosines and X section properties
samuel-ramsahoye Jan 17, 2023
b5ea3f1
removed temporary files
samuel-ramsahoye Jan 17, 2023
a12ccf6
added example
samuel-ramsahoye Jan 18, 2023
5607719
added refinement of member with X section properties
samuel-ramsahoye Jan 18, 2023
1e7a352
added refinement of member with X section properties
samuel-ramsahoye Jan 18, 2023
20b3860
ensured SHEAR is defined for X members
samuel-ramsahoye Jan 18, 2023
60a4b43
added trick to get eType=4 elements to be added to stiffness/mass mat…
samuel-ramsahoye Jan 20, 2023
e471e31
updated SubDyn_registry to split Kappa into Kappa_x and Kappa_y
samuel-ramsahoye Jan 20, 2023
f69da2a
started to add regression tests
samuel-ramsahoye Jan 20, 2023
bf7239e
started to add regression tests
samuel-ramsahoye Jan 20, 2023
67f6ab8
responding to @ebranlard's comments
samuel-ramsahoye Jan 23, 2023
ee2c0be
removed tests
samuel-ramsahoye Jan 23, 2023
3b687b8
updated FINDLOCI interfaces
samuel-ramsahoye Jan 24, 2023
5b4b670
SD: renaming members to BeamCirc and BeamArb, adding comments
ebranlard Apr 14, 2023
40b619c
SD: update of documentation
ebranlard Apr 14, 2023
75613f6
SD: update of r-test
ebranlard Apr 14, 2023
068506e
SD:using r-test with new test of dircos
ebranlard Apr 14, 2023
0c66ad3
SD: adding arbitrary section test (not run yet, waiiting for NDIV>1)
ebranlard Apr 14, 2023
45fe823
SD: pointing to dev r-test
ebranlard Apr 14, 2023
b24e97c
SD: Removed print statement and count of BeamArb in ndiv
ebranlard Apr 14, 2023
55cbeb0
Merge branch 'dev' into f/subdyn_updates
ebranlard Apr 14, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ vs-build/
.vscode
.atom
.fortls
.devcontainer
# backup files
*.asv
~$*.xlsx
Expand Down
278 changes: 139 additions & 139 deletions docs/source/user/subdyn/examples/OC4_Jacket_SD_Input.dat

Large diffs are not rendered by default.

19 changes: 8 additions & 11 deletions docs/source/user/subdyn/input_files.rst
Original file line number Diff line number Diff line change
Expand Up @@ -427,8 +427,9 @@ A member is one of the three following types (see :numref:`SD_FEM`):

- Rigid link (*MType=3*)

**COSMID** refers to the IDs of the members’ cosine matrices for
noncircular members; the current release ignores this column.
**COSMID** refers to the IDs of the members' cosine matrices for
noncircular members; the current release uses SubDyn's default direction
cosine convention if it's not present or when COSMID values are -1.


An example of member table is given below
Expand Down Expand Up @@ -543,17 +544,13 @@ An example of rigid link properties table is given below

Member Cosine Matrices COSM (i,j)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This table is not currently used by SubDyn, but in future releases it
will need to be populated if members with cross-sections other than
circular will be employed.

**NCOSMs** rows, one for each unique member orientation set, will need
to be provided. Each row of the table will list the nine entries of the
direction cosine matrices (COSM11, COSM12,…COSM33) for matrix elements
(1,1), (1,2),…(3,3) that establish the orientation of the local member
axes (*x*,\ *y* principal axes in the cross-sectional plane, *z* along
the member longitudinal axis) with respect to the SS coordinate system
(local-to-global transformation matrices).
direction cosine matrices (COSM11, COSM12,…COSM33) for matrix elements.
Each row is a vector in the global coordinate system for principal axes
in the x, y and z directions respectively. These vectors need to be
specified with an extremely high level of precision for results to be
equivalent to an internal calculation.

Joint Additional Concentrated Masses
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
30 changes: 23 additions & 7 deletions modules/subdyn/src/FEM.f90
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,9 @@ MODULE FEM
INTEGER, PARAMETER :: LaKi = R8Ki ! Define the kind to be used for LaPack

INTERFACE FINDLOCI ! In the future, use FINDLOC from intrinsic
MODULE PROCEDURE FINDLOCI_ReKi
MODULE PROCEDURE FINDLOCI_R8Ki
MODULE PROCEDURE FINDLOCI_IntKi
MODULE PROCEDURE FINDLOCI_SiKi
END INTERFACE


Expand Down Expand Up @@ -836,8 +837,8 @@ END SUBROUTINE InsertDOFrows
!------------------------------------------------------------------------------------------------------
!> Returns index of val in Array (val is an integer!)
! NOTE: in the future use intrinsinc function findloc
FUNCTION FINDLOCI_ReKi(Array, Val) result(i)
real(ReKi) , dimension(:), intent(in) :: Array !< Array to search in
FUNCTION FINDLOCI_R8Ki(Array, Val) result(i)
real(R8Ki) , dimension(:), intent(in) :: Array !< Array to search in
integer(IntKi), intent(in) :: val !< Val
integer(IntKi) :: i !< Index of joint in joint table
i = 1
Expand Down Expand Up @@ -866,6 +867,21 @@ FUNCTION FINDLOCI_IntKi(Array, Val) result(i)
enddo
i=-1
END FUNCTION

FUNCTION FINDLOCI_SiKi(Array, Val) result(i)
real(SiKi), dimension(:), intent(in) :: Array !< Array to search in
integer(IntKi), intent(in) :: val !< Val
integer(IntKi) :: i !< Index of joint in joint table
i = 1
do while ( i <= size(Array) )
if ( Val == Array(i) ) THEN
return ! Exit when found
else
i = i + 1
endif
enddo
i=-1
END FUNCTION
!------------------------------------------------------------------------------------------------------
SUBROUTINE RigidTransformationLine(dx,dy,dz,iLine,Line)
real(ReKi), INTENT(IN) :: dx,dy,dz
Expand Down Expand Up @@ -1022,17 +1038,17 @@ END SUBROUTINE GetOrthVectors
!> Element stiffness matrix for classical beam elements
!! shear is true -- non-tapered Timoshenko beam
!! shear is false -- non-tapered Euler-Bernoulli beam
SUBROUTINE ElemK_Beam(A, L, Ixx, Iyy, Jzz, Shear, kappa, E, G, DirCos, K)
REAL(ReKi), INTENT( IN) :: A, L, Ixx, Iyy, Jzz, E, G, kappa
SUBROUTINE ElemK_Beam(A, L, Ixx, Iyy, Jzz, Shear, kappa_x, kappa_y, E, G, DirCos, K)
REAL(ReKi), INTENT( IN) :: A, L, Ixx, Iyy, Jzz, E, G, kappa_x, kappa_y
REAL(FEKi), INTENT( IN) :: DirCos(3,3) !< From element to global: xg = DC.xe, Kg = DC.Ke.DC^t
LOGICAL , INTENT( IN) :: Shear
REAL(FEKi), INTENT(OUT) :: K(12, 12)
! Local variables
REAL(FEKi) :: Ax, Ay, Kx, Ky
REAL(FEKi) :: DC(12, 12)

Ax = kappa*A
Ay = kappa*A
Ax = kappa_x*A
Ay = kappa_y*A

K(1:12,1:12) = 0.0_FEKi

Expand Down