When I plot the bode diagram it hides the decade 10¹
begin
using ControlSystems
using Plots
h₁ = tf(
[10],
[1, 20]
)
bodeplot(h₁)
end
How to show the missing decade?
When I plot the bode diagram it hides the decade 10¹
begin
using ControlSystems
using Plots
h₁ = tf(
[10],
[1, 20]
)
bodeplot(h₁)
end
How to show the missing decade?
The xticks
are autogenerated, but you can always pass your own: xticks = [1, 10, 100]
You could fix first the common frequency axis, and then the individual subplots y-axes (better to use both ticks
and lims
keywords for more general case):
bodeplot(h₁, xticks=10.0.^(0:3), xlims=(1, 10^3))
plot!(yticks=10.0.^(-2:0), ylims=(10^-2,1), subplot=1)
plot!(yticks=-90:30:0, ylims=(-90,0), subplot=2)
according to baggepinnen in:
This is up to the plotting backend to select, if you plot with GR (the default backend), it does indeed look like they do not display the 1e1 tick
plotly()
orxticks =
, e.g., bodeplot(h₁, xticks=exp10.(0:0.5:3))