From 2cf24eb86d9faed4fd28e6dd41c5a53d682f7fe5 Mon Sep 17 00:00:00 2001 From: EdoAlvarezR Date: Sun, 15 Dec 2024 00:01:39 -0600 Subject: [PATCH] Fix broken type broadcast in latest Julia --- Project.toml | 2 +- src/FLOWVLM_rotor_ccb.jl | 14 ++++++++++++-- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/Project.toml b/Project.toml index 8dd3512..6f990e2 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "FLOWVLM" uuid = "1a3ff0be-0410-4572-aa62-b496bdd1f33b" authors = ["Eduardo J. Alvarez "] -version = "2.1.2" +version = "2.1.3" [deps] PyPlot = "d330b81b-6aea-500a-939a-2ce795aea3ee" diff --git a/src/FLOWVLM_rotor_ccb.jl b/src/FLOWVLM_rotor_ccb.jl index f9a72ea..c153ddb 100644 --- a/src/FLOWVLM_rotor_ccb.jl +++ b/src/FLOWVLM_rotor_ccb.jl @@ -186,9 +186,19 @@ function OCCB2CCB(orotor::OCCBRotor, turbine::Bool, oinflow::OCCBInflow; airfoil_funs = [(alpha, Re, Mach) -> occb_airfoil(af, alpha) for af in orotor.af] - sections = ccb.Section.(orotor.r, orotor.chord, orotor.theta, airfoil_funs) + # sections = ccb.Section.(orotor.r, orotor.chord, orotor.theta, airfoil_funs) + # sections = [ccb.Section(r, c, tht, rfl) for (r, c, tht, rfl) in zip(orotor.r, orotor.chord, orotor.theta, airfoil_funs)] + sections = [] + for (r, c, tht, rfl) in zip(orotor.r, orotor.chord, orotor.theta, airfoil_funs) + push!(sections, ccb.Section(r, c, tht, rfl)) + end - ops = ccb.OperatingPoint.(oinflow.Vx, oinflow.Vy, oinflow.rho) + # ops = ccb.OperatingPoint.(oinflow.Vx, oinflow.Vy, oinflow.rho) + # ops = [ccb.OperatingPoint(Vx, Vy, oinflow.rho) for (Vx, Vy) in zip(oinflow.Vx, oinflow.Vy)] + ops = [] + for (Vx, Vy) in zip(oinflow.Vx, oinflow.Vy) + push!(ops, ccb.OperatingPoint(Vx, Vy, oinflow.rho)) + end return rotor, sections, ops end