Skip to content

Commit

Permalink
add precompilation workload
Browse files Browse the repository at this point in the history
  • Loading branch information
baggepinnen committed May 15, 2023
1 parent 3cf5dd7 commit c400e1d
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/ControlSystemsBase/src/ControlSystemsBase.jl
Original file line number Diff line number Diff line change
Expand Up @@ -233,4 +233,6 @@ function __init__()
end
end

include("precompilation.jl")

end
31 changes: 31 additions & 0 deletions lib/ControlSystemsBase/src/precompilation.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
using PrecompileTools


PrecompileTools.@setup_workload begin
P = ssrand(1,1,2, proper=true)
PrecompileTools.@compile_workload begin
Pd = c2d(P, 0.1)
for P in (P, Pd)
bode(P)
# nyquist(P)
step(P)
feedback(P)
feedback(P, P)
minreal(P)
balance_statespace(P)
P*P
P+P
2.0*P
# hinfnorm(P)
poles(P)
tzeros(P)
end
G = tf(1.0, [1.0, 1])
ss(G)
G = tf(1.0, [1.0, 1], 1)
ss(G)

# Pdel = P*delay(1.0)
# pade(Pdel, 2)
end
end

0 comments on commit c400e1d

Please sign in to comment.