This is unreleased documentation for Scirocco Next version.
For up-to-date documentation, see the latest version (0.4.0).
Version: Next
Comparison with XFOIL and mfoil
Scirocco implements the model of mfoil,
Fidkowski's Python reimplementation of XFOIL's panel method and integral
boundary layer. Wherever both converge, Scirocco with mfoil's closure
selected reproduces mfoil's forces and transition locations to every
stored digit. Both differ from XFOIL by the same small amount: on average
0.3–0.5% in Cl and 0.5–1% in Cd.
Case
Converged (Scirocco / XFOIL / mfoil)
Cl vs XFOIL, mean / max
Cd vs XFOIL, mean / max
Transition vs XFOIL, max
vs mfoil
NACA 2412, inviscid, α = −4…12°
9 / 9 / 9
0.00% / 0.00%
—
—
identical
NACA 0012, Re = 10⁶, α = 0…15°
16 / 15 / 12
0.31% / 0.89%
0.94% / 3.8%
0.0014c
identical
NACA 2412, Re = 3×10⁶, α = −4…14°
19 / 18 / 14
0.50% / 1.6%
0.54% / 1.0%
0.0023c
identical
NACA 4412, Re = 2×10⁵, α = −2…12°
15 / 15 / 13
0.35% / 0.85%
0.84% / 2.8%
0.0082c
identical
NACA 2412, Re = 6×10⁶, M = 0.4, α = −2…6°
8 / 9 / 7
0.47% / 0.68%
0.48% / 0.77%
0.0024c
identical
Differences are relative, over the angles where both codes converged; Cl
differences skip |Cl| < 0.05. "Identical" means equal to the six
significant digits stored, which leaves a largest transition difference of
1e-4c from rounding.
Same nodes. mfoil panels each airfoil with 199 panels. Scirocco takes
those nodes, arc lengths and tangents unchanged, and XFOIL loads the
nodes without repaneling (PCOP). Paneling differences are therefore
ruled out; what remains is the solver.
Same physics. ncrit = 9, free transition on both surfaces, Kármán–Tsien
correction at M = 0.4. Scirocco runs mfoil's closure
(cf_laminar_floor = false); see
The skin-friction floor for its default.
How each code runs. Scirocco and XFOIL sweep each polar the way a user
would, starting at the angle nearest 0° and continuing up, then down, each
point warm-starting from the last (Scirocco with warm_start = true; see
warm starts). mfoil solves every point from a cold
start. XFOIL is version 6.99 with 100 iterations allowed per point.
Precision. XFOIL's forces and distributions are read from its binary
polar dump, in double precision, not from the rounded text polar.
On the same nodes the three linear-vorticity panel methods give the same
lift and moment to five or more significant digits. The inviscid Cp is
the starting point for everything else, so the viscous differences below
don't come from the panel method.
NACA 2412, Re = 3×10⁶. Not converged: XFOIL 6.99 at 6°; mfoil at 7°, 8°, 9°, 10°, 12°.Show data
Scirocco
α (deg)
Cl
-4
-0.206
-3
-0.094
-2
0.018
-1
0.130
0
0.241
1
0.352
2
0.462
3
0.569
4
0.675
5
0.804
6
0.913
7
1.008
8
1.107
9
1.206
10
1.303
11
1.395
12
1.483
13
1.555
14
1.617
XFOIL 6.99
α (deg)
Cl
-4
-0.208
-3
-0.096
-2
0.017
-1
0.130
0
0.242
1
0.354
2
0.465
3
0.573
4
0.677
5
0.806
7
1.009
8
1.109
9
1.209
10
1.307
11
1.400
12
1.489
13
1.564
14
1.627
mfoil
α (deg)
Cl
-4
-0.206
-3
-0.094
-2
0.018
-1
0.130
0
0.241
1
0.352
2
0.462
3
0.569
4
0.675
5
0.804
6
0.913
11
1.395
13
1.555
14
1.617
Scirocco
XFOIL 6.99
mfoil
Show data
Scirocco
Cd
Cl
0.00637
-0.206
0.00607
-0.094
0.00582
0.018
0.00564
0.130
0.00547
0.241
0.00519
0.352
0.00508
0.462
0.00514
0.569
0.00570
0.675
0.00677
0.804
0.00791
0.913
0.00892
1.008
0.00994
1.107
0.01103
1.206
0.01216
1.303
0.01348
1.395
0.01482
1.483
0.01660
1.555
0.01852
1.617
XFOIL 6.99
Cd
Cl
0.00639
-0.208
0.00609
-0.096
0.00584
0.017
0.00566
0.130
0.00549
0.242
0.00521
0.354
0.00511
0.465
0.00518
0.573
0.00574
0.677
0.00680
0.806
0.00896
1.009
0.00998
1.109
0.01107
1.209
0.01221
1.307
0.01356
1.400
0.01497
1.489
0.01672
1.564
0.01871
1.627
mfoil
Cd
Cl
0.00637
-0.206
0.00607
-0.094
0.00582
0.018
0.00564
0.130
0.00547
0.241
0.00519
0.352
0.00508
0.462
0.00514
0.569
0.00570
0.675
0.00677
0.804
0.00791
0.913
0.01348
1.395
0.01660
1.555
0.01852
1.617
The three curves lie on top of each other until stall approaches. The
largest XFOIL differences, 1–4%, come at the highest angles.
Scirocco
XFOIL 6.99
mfoil
NACA 0012, Re = 10⁶. Not converged: XFOIL 6.99 at 1°; mfoil at 5°, 7°, 11°, 13°.Show data
Scirocco
α (deg)
Cl
0
0.000
1
0.106
2
0.212
3
0.318
4
0.428
5
0.556
6
0.693
7
0.830
8
0.914
9
0.997
10
1.078
11
1.165
12
1.238
13
1.306
14
1.348
15
1.351
XFOIL 6.99
α (deg)
Cl
0
-0.000
2
0.214
3
0.320
4
0.428
5
0.556
6
0.694
7
0.827
8
0.910
9
0.995
10
1.078
11
1.167
12
1.242
13
1.312
14
1.351
15
1.357
mfoil
α (deg)
Cl
0
-0.000
1
0.106
2
0.212
3
0.318
4
0.428
6
0.693
8
0.914
9
0.997
10
1.078
12
1.238
14
1.348
15
1.351
Scirocco
XFOIL 6.99
mfoil
Show data
Scirocco
Cd
Cl
0.00539
0.000
0.00548
0.106
0.00579
0.212
0.00639
0.318
0.00728
0.428
0.00846
0.556
0.00972
0.693
0.01091
0.830
0.01208
0.914
0.01340
0.997
0.01515
1.078
0.01673
1.165
0.01939
1.238
0.02186
1.306
0.02521
1.348
0.03255
1.351
XFOIL 6.99
Cd
Cl
0.00541
-0.000
0.00582
0.214
0.00641
0.320
0.00730
0.428
0.00849
0.556
0.00975
0.694
0.01095
0.827
0.01211
0.910
0.01344
0.995
0.01524
1.078
0.01686
1.167
0.01961
1.242
0.02214
1.312
0.02604
1.351
0.03382
1.357
mfoil
Cd
Cl
0.00539
-0.000
0.00548
0.106
0.00579
0.212
0.00639
0.318
0.00728
0.428
0.00972
0.693
0.01208
0.914
0.01340
0.997
0.01515
1.078
0.01939
1.238
0.02521
1.348
0.03255
1.351
At low Reynolds number a laminar separation bubble forms ahead of
transition. The codes agree on it as closely as at the higher Reynolds
numbers:
Scirocco
XFOIL 6.99
mfoil
NACA 4412, Re = 2×10⁵. Not converged: mfoil at 9°, 10°.Show data
Scirocco
α (deg)
Cl
-2
0.248
-1
0.352
0
0.490
1
0.593
2
0.696
3
0.801
4
0.905
5
1.008
6
1.109
7
1.201
8
1.284
9
1.349
10
1.367
11
1.359
12
1.357
XFOIL 6.99
α (deg)
Cl
-2
0.250
-1
0.354
0
0.488
1
0.591
2
0.696
3
0.801
4
0.906
5
1.010
6
1.111
7
1.203
8
1.287
9
1.353
10
1.372
11
1.366
12
1.368
mfoil
α (deg)
Cl
-2
0.248
-1
0.352
0
0.490
1
0.593
2
0.696
3
0.801
4
0.905
5
1.008
6
1.109
7
1.201
8
1.284
11
1.359
12
1.357
Scirocco
XFOIL 6.99
mfoil
Show data
Scirocco
Cd
Cl
0.01279
0.248
0.01076
0.352
0.01000
0.490
0.01037
0.593
0.01097
0.696
0.01174
0.801
0.01262
0.905
0.01357
1.008
0.01454
1.109
0.01542
1.201
0.01643
1.284
0.01797
1.349
0.02182
1.367
0.02884
1.359
0.03709
1.357
XFOIL 6.99
Cd
Cl
0.01284
0.250
0.01081
0.354
0.01002
0.488
0.01040
0.591
0.01101
0.696
0.01178
0.801
0.01266
0.906
0.01361
1.010
0.01459
1.111
0.01548
1.203
0.01651
1.287
0.01817
1.353
0.02233
1.372
0.02966
1.366
0.03812
1.368
mfoil
Cd
Cl
0.01279
0.248
0.01076
0.352
0.01000
0.490
0.01037
0.593
0.01097
0.696
0.01174
0.801
0.01262
0.905
0.01357
1.008
0.01454
1.109
0.01542
1.201
0.01643
1.284
0.02884
1.359
0.03709
1.357
At M = 0.4 the Kármán–Tsien correction matches XFOIL's to the same level
as the incompressible cases. Scirocco and mfoil both fail to converge at
4°, from the same model, where XFOIL converges.
Scirocco
XFOIL 6.99
mfoil
NACA 2412, Re = 6×10⁶, M = 0.4. Not converged: Scirocco at 4°; mfoil at 4°, 6°.Show data
The transition point is where the codes could disagree most, because it
depends on the amplification-factor march and on where in the interval
the cut cell places it. Scirocco and XFOIL put it within 0.0025c of each
other at Re ≥ 10⁶, and within 0.01c at Re = 2×10⁵:
Scirocco
XFOIL 6.99
mfoil
NACA 4412, Re = 2×10⁵: transition location on the upper surface.Show data
NACA 2412 at Re = 3×10⁶ and α = 4°. The markers are every sixth mfoil node.
Scirocco
XFOIL 6.99
mfoil
NACA 2412, Re = 3×10⁶, α = 4°.
Scirocco
XFOIL 6.99
mfoil
NACA 2412, Re = 3×10⁶, α = 4° on the upper surface. The axis cuts off the leading-edge peak.
Away from transition the skin friction from Scirocco and XFOIL agrees to
about 1e-6 (the median difference). The largest differences, up to 6e-4,
are in the first few turbulent stations, where XFOIL's Cf rises a little
faster. The pressure differs most near the trailing edge, by up to 0.008 in
Cp.
NACA 4412 at Re = 2×10⁵ and α = 4°: Cf drops below zero on the upper
surface from x/c = 0.39 to 0.59. That is the laminar separation bubble;
transition at 0.58c closes it.
Scirocco
XFOIL 6.99
mfoil
NACA 4412, Re = 2×10⁵, α = 4° on the upper surface. The axis cuts off the leading-edge peak.
By default Scirocco does not let the turbulent skin friction fall below the
laminar value, as XFOIL does and mfoil does not (see
Trips near the leading edge).
The comparison above switches that off, to check the implementation against
mfoil. With the default, the same polars converge at the same points and
move slightly towards XFOIL in drag:
Case
Cd change, mean / max
Cl change, max
Cd vs XFOIL, mean / max
NACA 0012, Re = 10⁶
0.08% / 0.19%
0.11%
0.86% / 3.6%
NACA 2412, Re = 3×10⁶
0.02% / 0.06%
0.02%
0.53% / 0.94%
NACA 4412, Re = 2×10⁵
0.23% / 0.75%
0.14%
0.62% / 2.4%
NACA 2412, Re = 6×10⁶, M = 0.4
0.0005% / 0.004%
0.00%
0.48% / 0.77%
The floor acts at the first few turbulent stations behind transition. Its
effect is largest at the lowest Reynolds number, where a laminar separation
bubble precedes transition.
mfoil has no floor and no forced transition, so it cannot check either.
They are checked against XFOIL and against measured tripped polars instead:
see tripped drag at low Reynolds numbers.
Scirocco converged at 58 of the 59 viscous points, XFOIL at 57, and mfoil,
from cold starts, at 46. XFOIL's miss at 1° on NACA 0012 is a limit cycle:
its Newton iteration settles on Cl = 0.1075 and stalls there for all 100
iterations. mfoil's misses are all at α ≥ 4°, each solved from a cold
start.
The scripts are in
scirocco/validation/vv.
vv.py codes runs all three codes, and flexfoil, and writes
docs/src/data/vv_codes.json, which the figures on this page read. It needs
XFOIL on the PATH and the flexfoil Python package, and takes
about 80 seconds on an Apple M1 Pro; the mfoil solves dominate.