Skip to content

Commit f275858

Browse files
authored
fixing numpy 2.0 deprecation warning (#459)
1 parent 8473fb0 commit f275858

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

openaerostruct/mphys/lift_distribution.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import numpy as np
2+
import scipy as sp
23

34
from openmdao.api import ExplicitComponent
45
import os
@@ -108,7 +109,7 @@ def compute(self, inputs, outputs):
108109
total_lift_dist += np.interp(y, y_station, surface_lift_dist, left=0, right=0)
109110

110111
# Compute the normalized lift distribution by integrating
111-
total_lift = np.trapz(total_lift_dist, y)
112+
total_lift = sp.integrate.trapezoid(total_lift_dist, y)
112113
span = y_max - y_min
113114
# Normalize the lift distribution so that the area under the curve is
114115
# unity

0 commit comments

Comments
 (0)