Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Steve Doyle committed Dec 13, 2024
2 parents 0ee4c74 + d88238d commit c66f5d2
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 12 deletions.
18 changes: 11 additions & 7 deletions pyNastran/bdf/mesh_utils/export_caero_mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,16 @@ def export_caero_mesh(model: BDF,
continue

bdf_file.write('$ ' + '\n$ '.join(scaero) + '\n')
if caero.lspan_ref:
aefact_chord = str(caero.lspan_ref).rstrip().split('\n')
bdf_file.write('$ ' + '\n$ '.join(aefact_chord) + '\n')
if caero.lchord_ref:
aefact_span = str(caero.lchord_ref).rstrip().split('\n')
bdf_file.write('$ ' + '\n$ '.join(aefact_span) + '\n')
if hasattr(caero, 'lspan'):
assert caero.type in {'CAERO1', 'CAERO4', 'CAERO5'}, caero
if caero.lspan_ref:
aefact_chord = str(caero.lspan_ref).rstrip().split('\n')
bdf_file.write('$ ' + '\n$ '.join(aefact_chord) + '\n')
if hasattr(caero, 'lchord'):
assert caero.type in {'CAERO1', }, caero
if caero.lchord_ref:
aefact_span = str(caero.lchord_ref).rstrip().split('\n')
bdf_file.write('$ ' + '\n$ '.join(aefact_span) + '\n')

#bdf_file.write("$ CAEROID ID XLE YLE ZLE CHORD SPAN\n")
points, elements = caero.panel_points_elements()
Expand Down Expand Up @@ -146,7 +150,7 @@ def _write_caero2_subpanel(bdf_file: TextIO, caero: CAERO2):
scaero = str(caero).rstrip().split('\n')
bdf_file.write('$ ' + '\n$ '.join(scaero) + '\n')
if caero.lsb_ref:
aefact_lsb = str(caero.aefact_lsb).rstrip().split('\n')
aefact_lsb = str(caero.lsb_ref).rstrip().split('\n')
bdf_file.write('$ ' + '\n$ '.join(aefact_lsb) + '\n')
if caero.lint_ref:
aefact_lint = str(caero.lint_ref).rstrip().split('\n')
Expand Down
8 changes: 3 additions & 5 deletions pyNastran/f06/parse_flutter.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,17 +159,15 @@ def make_flutter_response(f06_filename: PathLike,
line = f06_file.readline()
iline += 1

if methodi == 'PKNL':
assert 'VELOCITY' in line, line
if 'VELOCITY' in line:
#' EIGENVALUE = -9.88553E-02 1.71977E+01 VELOCITY = 1.52383E+02
eig_value, velocity_str = line.split('VELOCITY =')
eigr_str, eigi_str = eig_value.strip().split('EIGENVALUE =')[1].split()
velocity = float(velocity_str)
elif methodi == 'PK':
else:
eigr_str, eigi_str = line.strip().split('EIGENVALUE =')[1].split()
velocity = np.nan
else: # pragma: no cover
raise RuntimeError(f'methodi={methodi}')

eigr = float(eigr_str)
eigi = float(eigi_str)
#print(f'eigr,eigi,velo = {eigr}, {eigi}, {velocity}')
Expand Down

0 comments on commit c66f5d2

Please sign in to comment.