feat: Add precision rounding for optimization values

Round design variables, objectives, and constraints to appropriate
decimal precision based on physical units (4 decimals for mm, degrees, MPa).

- Added _get_precision() method with unit-based precision mapping
- Round design variables when sampled from Optuna
- Round extracted results (objectives and constraints)
- Added units field to objectives in config files
- Tested: values now show 4 decimals instead of 17+

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-11-15 12:56:50 -05:00
parent d694344b9f
commit a267e2d6f0
12 changed files with 5753 additions and 6303 deletions

View File

@@ -17,8 +17,8 @@ symbol=DELDIR='c:/program files/siemens/simcenter3d_2412/nxnastran/scnas/nast/de
symbol=DEMODIR='c:/program files/siemens/simcenter3d_2412/nxnastran/scnas/nast/demo' $(program default)
symbol=SSSALTERDIR='c:/program files/siemens/simcenter3d_2412/nxnastran/scnas/nast/misc/sssalter' $(program default)
symbol=TPLDIR='c:/program files/siemens/simcenter3d_2412/nxnastran/scnas/nast/tpl' $(program default)
SDIR='c:/users/antoi/appdata/local/temp/bracket_sim1-solution_1.T109004_37'
DBS='c:/users/antoi/appdata/local/temp/bracket_sim1-solution_1.T109004_37'
SDIR='c:/users/antoi/appdata/local/temp/bracket_sim1-solution_1.T150692_57'
DBS='c:/users/antoi/appdata/local/temp/bracket_sim1-solution_1.T150692_57'
SCR=yes
SMEM=20.0X
NEWDEL='c:/program files/siemens/simcenter3d_2412/nxnastran/scnas/em64tntl/SSS'
@@ -43,9 +43,9 @@ NXN_MSG: stderr
--------------------------------------------------------------------------------------
Current resource limits:
Physical memory: 65208 MB
Physical memory available: 36638 MB
Physical memory available: 36892 MB
Paging file size: 83640 MB
Paging file size available: 34893 MB
Paging file size available: 35351 MB
Virtual memory: 134217727 MB
Virtual memory available: 134213557 MB
--------------------------------------------------------------------------------------
@@ -66,20 +66,20 @@ System configuration:
Disk block size: 512 bytes (64 words)
Remote shell cmd: Remote capabilities not available.
--------------------------------------------------------------------------------------
Simcenter Nastran started Sat Nov 15 12:51:38 EST 2025
12:51:38 Beginning Analysis
Simcenter Nastran started Sat Nov 15 12:54:57 EST 2025
12:54:58 Beginning Analysis
12:51:38 Simcenter NASTRAN Authorization Information - System Attributes
12:51:38 --------------------------------------------------------
12:51:38 Model: Intel(R) Core(TM) i7-14700HX (An
12:51:38 Machine: Intel64 Family 6 Model 183 Stepp
12:51:38 OS: Windows 10
12:51:38 Version:
12:51:38 License File(s): 29000@AntoineThinkpad
12:54:58 Simcenter NASTRAN Authorization Information - System Attributes
12:54:58 --------------------------------------------------------
12:54:58 Model: Intel(R) Core(TM) i7-14700HX (An
12:54:58 Machine: Intel64 Family 6 Model 183 Stepp
12:54:58 OS: Windows 10
12:54:58 Version:
12:54:58 License File(s): 29000@AntoineThinkpad
12:51:38 app set license server to 29000@AntoineThinkpad
12:54:58 app set license server to 29000@AntoineThinkpad
12:51:38 ************** License Server/File Information **************
12:54:58 ************** License Server/File Information **************
Server/File : 29000@AntoineThinkpad
License File Sold To / Install : 10219284 - Atomaste
@@ -89,10 +89,10 @@ Simcenter Nastran started Sat Nov 15 12:51:38 EST 2025
Flexera Daemon Version : 11.19
Vendor Daemon Version : 11.1 SALT v5.0.0.0
12:51:38 *************************************************************
12:54:58 *************************************************************
12:51:38 **************** License Session Information ****************
12:54:58 **************** License Session Information ****************
Toolkit Version : 2.6.2.0
Server Setting Used : 29000@AntoineThinkpad
@@ -100,30 +100,30 @@ Simcenter Nastran started Sat Nov 15 12:51:38 EST 2025
Number of bundles in use : 0
12:51:38 *************************************************************
12:54:58 *************************************************************
12:51:38 SALT_startLicensingSession: call count: 1
12:54:58 SALT_startLicensingSession: call count: 1
12:51:38 Simcenter NASTRAN Authorization Information - Checkout Successful
12:51:38 -----------------------------------------------------------------
12:51:38 License for module Simcenter Nastran Basic - NX Desktop (Bundle) checked out successfully
12:54:58 Simcenter NASTRAN Authorization Information - Checkout Successful
12:54:58 -----------------------------------------------------------------
12:54:58 License for module Simcenter Nastran Basic - NX Desktop (Bundle) checked out successfully
12:51:38 Analysis started.
12:51:38 Geometry access/verification to CAD part initiated (if needed).
12:51:38 Geometry access/verification to CAD part successfully completed (if needed).
12:51:38 Finite element model generation started.
12:51:38 Finite element model generated 12516 degrees of freedom.
12:51:38 Finite element model generation successfully completed.
12:51:38 Application of Loads and Boundary Conditions to the finite element model started.
12:51:38 Application of Loads and Boundary Conditions to the finite element model successfully completed.
12:51:38 Solution of the system equations for linear statics started.
12:51:38 Solution of the system equations for linear statics successfully completed.
12:51:38 Linear static analysis completed.
12:51:38 NSEXIT: EXIT(0)
12:51:38 SALT_term: Successful session call count: 0
12:51:38 Session has been terminated.
12:51:38 Analysis complete 0
Real: 0.735 seconds ( 0:00:00.735)
User: 0.296 seconds ( 0:00:00.296)
Sys: 0.187 seconds ( 0:00:00.187)
Simcenter Nastran finished Sat Nov 15 12:51:38 EST 2025
12:54:58 Analysis started.
12:54:58 Geometry access/verification to CAD part initiated (if needed).
12:54:58 Geometry access/verification to CAD part successfully completed (if needed).
12:54:58 Finite element model generation started.
12:54:58 Finite element model generated 11460 degrees of freedom.
12:54:58 Finite element model generation successfully completed.
12:54:58 Application of Loads and Boundary Conditions to the finite element model started.
12:54:58 Application of Loads and Boundary Conditions to the finite element model successfully completed.
12:54:58 Solution of the system equations for linear statics started.
12:54:58 Solution of the system equations for linear statics successfully completed.
12:54:58 Linear static analysis completed.
12:54:58 NSEXIT: EXIT(0)
12:54:58 SALT_term: Successful session call count: 0
12:54:58 Session has been terminated.
12:54:58 Analysis complete 0
Real: 0.710 seconds ( 0:00:00.710)
User: 0.343 seconds ( 0:00:00.343)
Sys: 0.078 seconds ( 0:00:00.078)
Simcenter Nastran finished Sat Nov 15 12:54:58 EST 2025