Skip to content

Commit

Permalink
fix [aerogrid] add user-specified chordwise panel distribution
Browse files Browse the repository at this point in the history
- must have been removed during a merge process as it is included in the current SHARPy version
  • Loading branch information
sduess committed Sep 18, 2023
1 parent 5d211cc commit 02acde7
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions sharpy/aero/models/aerogrid.py
Original file line number Diff line number Diff line change
Expand Up @@ -390,6 +390,9 @@ def generate_strip(node_info, airfoil_db, aligned_grid,
strip_coordinates_b_frame[1, :] = np.linspace(0.0, 1.0, node_info['M'] + 1)
elif node_info['M_distribution'] == '1-cos':
domain = np.linspace(0, 1.0, node_info['M'] + 1)
strip_coordinates_b_frame[1, :] = 0.5*(1.0 - np.cos(domain*np.pi))
elif node_info['M_distribution'].lower() == 'user_defined':
strip_coordinates_b_frame[1,:] = node_info['user_defined_m_distribution']
else:
raise NotImplemented('M_distribution is ' + node_info['M_distribution'] +
' and it is not yet supported')
Expand Down

0 comments on commit 02acde7

Please sign in to comment.