Skip to content

Commit 2bbbe15

Browse files
committed
added plot 2 of 9
1 parent 653dbbe commit 2bbbe15

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

src/plotting.jl

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,27 @@ function plot_distribution(y_coordinates_list, results_list, label_list;
278278
axs[1, 1].set_xlabel(L"Spanwise Position $y/b$")
279279
axs[1, 1].set_ylabel(L"Lift Coefficient $C_L$")
280280
axs[1, 1].legend()
281+
282+
# CD plot
283+
for (y_coordinates_i, result_i, label_i) in zip(y_coordinates_list, results_list, label_list)
284+
value = "$(round(result_i["cl"], digits=2))"
285+
println(label_i)
286+
if label_i == "LLT"
287+
label = label_i * L" $~C_D$: " * value
288+
else
289+
label = label_i * L" $C_D$: " * value
290+
end
291+
axs[1, 2].plot(
292+
y_coordinates_i,
293+
result_i["cd_distribution"],
294+
label=label
295+
)
296+
end
297+
axs[1, 2].set_title(L"$C_D$ Distribution", size=16)
298+
axs[1, 2].set_xlabel(L"Spanwise Position $y/b$")
299+
axs[1, 2].set_ylabel(L"Drag Coefficient $C_D$")
300+
axs[1, 2].legend()
301+
281302
fig.tight_layout()
282303

283304
# # CD Distribution

0 commit comments

Comments
 (0)