Skip to content

Commit

Permalink
length call
Browse files Browse the repository at this point in the history
  • Loading branch information
andgoldschmidt committed Jul 31, 2024
1 parent b26231d commit 60084d5
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/methods_named_trajectory.jl
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,16 @@ function Base.vec(Z::NamedTrajectory)
end


"""
length(::NamedTrajectory)
Returns the length of all variables of the trajectory.
"""
function Base.length(Z::NamedTrajectory)
return Z.dim * Z.T + Z.global_dim
end


"""
copy(::NamedTrajectory)
Expand Down

0 comments on commit 60084d5

Please sign in to comment.