Skip to content

Commit

Permalink
Tao version update. (bmad-sim#1376)
Browse files Browse the repository at this point in the history
* Fix PTC bookkeeping problem with multiple universes.
  • Loading branch information
DavidSagan authored Jan 27, 2025
1 parent 3aeb0e6 commit c542ee8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
9 changes: 6 additions & 3 deletions bmad/modules/equal_mod.f90
Original file line number Diff line number Diff line change
Expand Up @@ -568,6 +568,7 @@ subroutine lat_equal_lat (lat_out, lat_in)
type (lat_struct), intent(inout), target :: lat_out
type (lat_struct), intent(in), target :: lat_in
type (branch_struct), pointer :: branch_out
type (ele_struct), pointer :: ele
type (control_struct), pointer :: c_in, c_out
integer i, n, nb, ne, ie, n_out, n_in
logical do_alloc
Expand Down Expand Up @@ -602,9 +603,11 @@ subroutine lat_equal_lat (lat_out, lat_in)
branch_out = lat_in%branch(i)
branch_out%lat => lat_out
do ie = 0, ubound(branch_out%ele, 1)
branch_out%ele(ie)%ix_ele = ie
branch_out%ele(ie)%ix_branch = i
branch_out%ele(ie)%branch => branch_out
ele => branch_out%ele(ie)
ele%ix_ele = ie
ele%ix_branch = i
ele%branch => branch_out
if (associated(ele%ptc_fibre)) nullify(ele%ptc_fibre)
enddo
enddo

Expand Down
3 changes: 0 additions & 3 deletions tao/code/tao_init.f90
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,6 @@ subroutine tao_init (err_flag)

do i = lbound(s%u, 1), ubound(s%u, 1)
u => s%u(i)
if (u%design_same_as_previous) u%model = s%u(i-1)%model

u%design = u%model
u%base = u%design
Expand All @@ -375,8 +374,6 @@ subroutine tao_init (err_flag)
u%model%name = 'model'
u%base%name = 'base'

u%design%tao_branch = u%model%tao_branch
u%base%tao_branch = u%design%tao_branch
u%data%design_value = u%data%model_value
u%data%base_value = u%data%model_value
u%data%good_design = u%data%good_model
Expand Down
2 changes: 1 addition & 1 deletion tao/version/tao_version_mod.f90
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@
!-

module tao_version_mod
character(*), parameter :: tao_version_date = "2025/01/25 20:41:09"
character(*), parameter :: tao_version_date = "2025/01/27 17:39:40"
end module

0 comments on commit c542ee8

Please sign in to comment.