DynaSolution
#
- class ansys.dyna.core.pre.dynasolution.DynaSolution(hostname='localhost', port='50051', channel=None, server_path='')#
Contains methods for creating a general LS-DYNA keyword.
Overview#
Get the stub of the solution object. |
|
Add a case in the solution. |
|
Get file chunks. |
|
Upload files to the server. |
|
Download files from the server. |
|
Open initial model files. |
|
Set time for terminating the job. |
|
Request binary output. |
|
Obtain output files containing result information. |
|
Obtain output files containing result information. |
|
Save keyword files. |
|
Delete remote instance. |
Get model associated with the solution. |
Check if the server is launched locally. |
Import detail#
from ansys.dyna.core.pre.dynasolution import DynaSolution
Property detail#
- property DynaSolution.model#
Get model associated with the solution.
Attribute detail#
- DynaSolution.pim_client = None#
- DynaSolution.remote_instance = None#
- DynaSolution.stub#
- DynaSolution.object_list = []#
- DynaSolution.mainname = ''#
Method detail#
- DynaSolution.get_download_path()#
- static DynaSolution.get_appdata_path()#
- static DynaSolution.grpc_local_server_on() bool #
Check if the server is launched locally.
- Returns:
- bool
True
when successful,False
when failed.
- DynaSolution.get_stub()#
Get the stub of the solution object.
- DynaSolution.add(obj)#
Add a case in the solution.
- Parameters:
- obj
- DynaSolution.upload(stub_, filename)#
Upload files to the server.
- Parameters:
- stub_
- filename
str
Name of the file.
- DynaSolution.download(remote_name, local_name)#
Download files from the server.
- Parameters:
- stub_
- remote_name
- local_name
- DynaSolution.open_files(filenames)#
Open initial model files.
- DynaSolution.set_termination(termination_time)#
Set time for terminating the job.
- DynaSolution.create_database_binary(filetype='D3PLOT', dt=0, maxint=3, ieverp=0, dcomp=1, nintsld=1)#
Request binary output.
- Parameters:
- filetype
str
,optional
Type of file. The default is
"D3PLOT"
.- dt
float
,optional
Time interval between output states. The default is
0
.- maxint
int
,optional
Number of shell and thick shell through-thickness integration points to output to the d3plot. The default is
3
.- ieverp
int
,optional
How to plot output states on plot files. The default is
0
. Every output state for the d3plot database is written to a separate file. Options are:EQ.0: More than one state can be on each plot file.
EQ.1: Only one state can be on each plot file.
- dcomp
int
,optional
Data compression to eliminate rigid body data. The default is
1
.- nintsld
int
,optional
Number of solid element integration points written to the LS-DYNA database. The default is
1
.
- filetype
- Returns:
- bool
True
when successful,False
when failed.
- DynaSolution.create_database_ascii(type, dt=0.0, binary=1, lcur=0, ioopt=0)#
Obtain output files containing result information.
- Parameters:
- type
str
Type of the database. Options are:
BNDOUT
GLSTAT
MATSUM
NODFOR
RCFORC
SLEOUT
- dt
float
,optional
Time interval between outputs. The default is
0.0
.- binary
int
,optional
Flag for whether to generate binary output. The default is
1
.- lcur
int
,optional
Curve ID specifying the time interval between outputs. The default is
0
.- ioopt
int
,optional
Flag for governing the behavior of the output frequency load curve defined by the
lcur
parameter. The default is0
.
- type
- Returns:
- bool
True
when successful,False
when failed.
- DynaSolution.set_output_database(matsum=0, glstat=0, elout=0, nodout=0, nodfor=0, rbdout=0, rcforc=0, secforc=0, rwforc=0, abstat=0, bndout=0, sleout=0, sphmassflow=0)#
Obtain output files containing result information.
- Parameters:
- Returns:
- bool
True
when successful,False
when failed.
- DynaSolution.quit()#
Delete remote instance.