Skip to content

Commit b496944

Browse files
committed
Fix plotting bug
1 parent bd0e7cb commit b496944

2 files changed

Lines changed: 16 additions & 13 deletions

File tree

examples_cp/menu_cp.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ url = "https://opensourceawe.github.io/VortexStepMethod.jl/dev"
1111

1212
options = [
1313
"V3_kite = include(\"../examples/V3_kite.jl\")",
14+
"billowing = include(\"../examples/billowing.jl\")",
1415
"pyramid_model = include(\"../examples/pyramid_model.jl\")",
1516
"rectangular_wing = include(\"../examples/rectangular_wing.jl\")",
1617
"ram_air_kite = include(\"../examples/ram_air_kite.jl\")",

ext/VortexStepMethodControlPlotsExt.jl

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -740,25 +740,27 @@ function VortexStepMethod.plot_polars(
740740
# Number of computational results (excluding literature)
741741
n_solvers = length(solver_list)
742742

743-
# Helper: format label for LaTeX rendering
743+
# Helper: format label and line style
744744
function format_label(label, i, n_solvers)
745745
if i < n_solvers
746746
linestyle, marker, markersize = "-", "*", 7
747747
else
748748
linestyle, marker, markersize = "-", ".", 5
749749
end
750-
if contains(label, "LLT")
751-
label = replace(label, "e5" => raw"\cdot10^5")
752-
label = replace(label, " " => raw"~")
753-
label = replace(label,
754-
"LLT" => raw"\mathrm{LLT}{~\,}")
755-
label = raw"$" * label * raw"$"
756-
else
757-
label = replace(label, "e5" => raw"\cdot10^5")
758-
label = replace(label, " " => "~")
759-
label = replace(label,
760-
"VSM" => raw"\mathrm{VSM}")
761-
label = raw"$" * label * raw"$"
750+
if use_tex
751+
if contains(label, "LLT")
752+
label = replace(label, "e5" => raw"\cdot10^5")
753+
label = replace(label, " " => raw"~")
754+
label = replace(label,
755+
"LLT" => raw"\mathrm{LLT}{~\,}")
756+
label = raw"$" * label * raw"$"
757+
else
758+
label = replace(label, "e5" => raw"\cdot10^5")
759+
label = replace(label, " " => "~")
760+
label = replace(label,
761+
"VSM" => raw"\mathrm{VSM}")
762+
label = raw"$" * label * raw"$"
763+
end
762764
end
763765
return label, linestyle, marker, markersize
764766
end

0 commit comments

Comments
 (0)