Skip to content

Commit 6ddc795

Browse files
Spelling and formatting run
1 parent e80952b commit 6ddc795

File tree

6 files changed

+142
-142
lines changed

6 files changed

+142
-142
lines changed

src/common/m_derived_types.fpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -329,9 +329,9 @@ module m_derived_types
329329
!! Patch conditions for moving imersed boundaries
330330
integer :: moving_ibm ! 0 for no moving, 1 for moving, 2 for moving on forced path
331331
real(wp), dimension(1:3) :: vel
332-
real(wp), dimension(1:3) :: step_vel ! velcoity array used to store intermediate steps in the time_stepper module
332+
real(wp), dimension(1:3) :: step_vel ! velocity array used to store intermediate steps in the time_stepper module
333333
real(wp), dimension(1:3) :: angular_vel
334-
real(wp), dimension(1:3) :: step_angular_vel ! velcoity array used to store intermediate steps in the time_stepper module
334+
real(wp), dimension(1:3) :: step_angular_vel ! velocity array used to store intermediate steps in the time_stepper module
335335

336336
end type ib_patch_parameters
337337

src/common/m_ib_patches.fpp

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -529,9 +529,9 @@ contains
529529
! Computing the beginning and the end x- and y-coordinates of the
530530
! rectangle based on its centroid and lengths
531531
x_boundary%beg = -0.5_wp*length_x
532-
x_boundary%end = 0.5_wp*length_x
532+
x_boundary%end = 0.5_wp*length_x
533533
y_boundary%beg = -0.5_wp*length_y
534-
y_boundary%end = 0.5_wp*length_y
534+
y_boundary%end = 0.5_wp*length_y
535535
536536
! Since the rectangular patch does not allow for its boundaries to
537537
! be smoothed out, the pseudo volume fraction is set to 1 to ensure
@@ -545,7 +545,7 @@ contains
545545
! variables of the current patch are assigned to this cell.
546546
do j = 0, n
547547
do i = 0, m
548-
! get the x and y coodinates in the local IB frame
548+
! get the x and y coordinates in the local IB frame
549549
xy_local = [x_cc(i) - x_centroid, y_cc(j) - y_centroid, 0._wp]
550550
xy_local = matmul(inverse_rotation, xy_local)
551551
if (x_boundary%beg <= xy_local(1) .and. &
@@ -1004,36 +1004,36 @@ contains
10041004
10051005
! construct the x, y, and z rotation matrices
10061006
if (num_dims == 3) then
1007-
! also compute the x and y axes in 3D
1008-
angle = patch_ib(patch_id)%angles(1)
1009-
rotation(1, 1, :) = [1._wp, 0._wp , 0._wp ]
1010-
rotation(1, 2, :) = [0._wp, cos(angle), -sin(angle)]
1011-
rotation(1, 3, :) = [0._wp, sin(angle), cos(angle) ]
1012-
1013-
angle = patch_ib(patch_id)%angles(2)
1014-
rotation(2, 1, :) = [cos(angle) , 0._wp, sin(angle)]
1015-
rotation(2, 2, :) = [0._wp , 1._wp, 0._wp ]
1016-
rotation(2, 3, :) = [-sin(angle), 0._wp, cos(angle)]
1017-
1018-
! apply the y rotation to the x rotation
1019-
patch_ib(patch_id)%rotation_matrix(:, :) = matmul(rotation(1, :, :), rotation(2, :, :))
1020-
patch_ib(patch_id)%rotation_matrix_inverse(:, :) = matmul(transpose(rotation(2, :, :)), transpose(rotation(1, :, :)))
1007+
! also compute the x and y axes in 3D
1008+
angle = patch_ib(patch_id)%angles(1)
1009+
rotation(1, 1, :) = [1._wp, 0._wp, 0._wp]
1010+
rotation(1, 2, :) = [0._wp, cos(angle), -sin(angle)]
1011+
rotation(1, 3, :) = [0._wp, sin(angle), cos(angle)]
1012+
1013+
angle = patch_ib(patch_id)%angles(2)
1014+
rotation(2, 1, :) = [cos(angle), 0._wp, sin(angle)]
1015+
rotation(2, 2, :) = [0._wp, 1._wp, 0._wp]
1016+
rotation(2, 3, :) = [-sin(angle), 0._wp, cos(angle)]
1017+
1018+
! apply the y rotation to the x rotation
1019+
patch_ib(patch_id)%rotation_matrix(:, :) = matmul(rotation(1, :, :), rotation(2, :, :))
1020+
patch_ib(patch_id)%rotation_matrix_inverse(:, :) = matmul(transpose(rotation(2, :, :)), transpose(rotation(1, :, :)))
10211021
end if
10221022
10231023
! z component first, since it applies in 2D and 3D
10241024
angle = patch_ib(patch_id)%angles(3)
10251025
rotation(3, 1, :) = [cos(angle), -sin(angle), 0._wp]
1026-
rotation(3, 2, :) = [sin(angle), cos(angle) , 0._wp]
1027-
rotation(3, 3, :) = [0._wp , 0._wp , 1._wp]
1026+
rotation(3, 2, :) = [sin(angle), cos(angle), 0._wp]
1027+
rotation(3, 3, :) = [0._wp, 0._wp, 1._wp]
10281028
10291029
if (num_dims == 3) then
1030-
! apply the z rotation to the xy rotation in 3D
1031-
patch_ib(patch_id)%rotation_matrix(:, :) = matmul(patch_ib(patch_id)%rotation_matrix(:, :), rotation(3, :, :))
1032-
patch_ib(patch_id)%rotation_matrix_inverse(:, :) = matmul(transpose(rotation(3, :, :)), patch_ib(patch_id)%rotation_matrix_inverse(:, :))
1030+
! apply the z rotation to the xy rotation in 3D
1031+
patch_ib(patch_id)%rotation_matrix(:, :) = matmul(patch_ib(patch_id)%rotation_matrix(:, :), rotation(3, :, :))
1032+
patch_ib(patch_id)%rotation_matrix_inverse(:, :) = matmul(transpose(rotation(3, :, :)), patch_ib(patch_id)%rotation_matrix_inverse(:, :))
10331033
else
1034-
! write out only the z rotation in 2D
1035-
patch_ib(patch_id)%rotation_matrix(:, :) = rotation(3, :, :)
1036-
patch_ib(patch_id)%rotation_matrix_inverse(:, :) = transpose(rotation(3, :, :))
1034+
! write out only the z rotation in 2D
1035+
patch_ib(patch_id)%rotation_matrix(:, :) = rotation(3, :, :)
1036+
patch_ib(patch_id)%rotation_matrix_inverse(:, :) = transpose(rotation(3, :, :))
10371037
end if
10381038
10391039
end subroutine s_update_ib_rotation_matrix

src/pre_process/m_global_parameters.fpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -545,7 +545,7 @@ contains
545545
patch_ib(i)%angles(:) = 0._wp
546546
patch_ib(i)%angular_vel(:) = 0._wp
547547

548-
! sets values of a rotation matrix which can be used when calculating rotaitons
548+
! sets values of a rotation matrix which can be used when calculating rotations
549549
patch_ib(i)%rotation_matrix = 0._wp
550550
patch_ib(i)%rotation_matrix(1, 1) = 1._wp
551551
patch_ib(i)%rotation_matrix(2, 2) = 1._wp

src/pre_process/m_initial_condition.fpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ contains
193193

194194
if (ib) then
195195
do i = 1, num_ibs
196-
! call s_update_ib_rotation_matrix(i)
196+
! call s_update_ib_rotation_matrix(i)
197197
end do
198198
call s_apply_ib_patches(ib_markers%sf, levelset, levelset_norm)
199199
end if

src/simulation/m_ibm.fpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ contains
9494
do i = 1, num_ibs
9595
if (patch_ib(i)%moving_ibm /= 0) then
9696
moving_immersed_boundary_flag = .true.
97-
97+
9898
end if
9999
call s_update_ib_rotation_matrix(i)
100100
end do
@@ -270,8 +270,8 @@ contains
270270
else
271271
! get the vector that points from the centroid to the ghost
272272
radial_vector = physical_loc - [patch_ib(patch_id)%x_centroid, &
273-
patch_ib(patch_id)%y_centroid, patch_ib(patch_id)%z_centroid]
274-
! convert the angular velcoity from the inertial reference frame to the fluids frame, then convert to linear velocity
273+
patch_ib(patch_id)%y_centroid, patch_ib(patch_id)%z_centroid]
274+
! convert the angular velocity from the inertial reference frame to the fluids frame, then convert to linear velocity
275275
rotation_velocity = cross_product(matmul(patch_ib(patch_id)%rotation_matrix, patch_ib(patch_id)%angular_vel), radial_vector)
276276
do q = 1, 3
277277
! if mibm is 1 or 2, then the boundary may be moving
@@ -920,7 +920,7 @@ contains
920920

921921
! recalulcate the rotation matrix based upon the new angles
922922
do i = 1, num_ibs
923-
if (patch_ib(i)%moving_ibm .ne. 0) call s_update_ib_rotation_matrix(i)
923+
if (patch_ib(i)%moving_ibm /= 0) call s_update_ib_rotation_matrix(i)
924924
end do
925925

926926
! recompute the new ib_patch locations and broadcast them.
@@ -952,13 +952,13 @@ contains
952952
end subroutine s_finalize_ibm_module
953953

954954
function cross_product(a, b) result(c)
955-
implicit none
956-
real(8), intent(in) :: a(3), b(3)
957-
real(8) :: c(3)
955+
implicit none
956+
real(8), intent(in) :: a(3), b(3)
957+
real(8) :: c(3)
958958

959-
c(1) = a(2)*b(3) - a(3)*b(2)
960-
c(2) = a(3)*b(1) - a(1)*b(3)
961-
c(3) = a(1)*b(2) - a(2)*b(1)
959+
c(1) = a(2)*b(3) - a(3)*b(2)
960+
c(2) = a(3)*b(1) - a(1)*b(3)
961+
c(3) = a(1)*b(2) - a(2)*b(1)
962962
end function cross_product
963963

964964
end module m_ibm

0 commit comments

Comments
 (0)