Skip to content

can not SOLVE during Acoustic radiation analysis #1428

Closed
@FemLearner

Description

@FemLearner

Before submitting the issue

  • I have searched among the existing issues
  • I am using a Python virtual environment

Description of the bug

pymapdl cannot complete
mapdl.solve()
Before the mapdl.solve() step,all the other steps are run successfully,but the examples like 2D Plane Stress Concentration Analysis can run successfully and out put the result.
An acoustic radiation belongs to an harmonic response analysis , I converted APDL language sentence by sentence to pymapdl language , it can run successfully in the ansys19.2 GUI interface but failed in the pymapdl.
I'm thinking about whether it's my code writing error that makes it impossible to calculate .This is my short demo,is there anyone who can help me see if it is a code error,thanks!!!

Steps To Reproduce

  • start pymapdl

import matplotlib.pyplot as plt
import numpy as np
from ansys.mapdl.core import launch_mapdl
mapdl = launch_mapdl()
  • apdl start set

mapdl.prep7()
mapdl.units("SI")  # SI - International system (m, kg, s, K).
  • define a ET30 and ET130 element type

mapdl.et(1, "FLUID30", kop2=3)
mapdl.et(2, "FLUID130", kop1=1)
  • Define a material (nominal steel in SI)

mapdl.mp("SONC", 1, 1500)  # sonc in m/s
mapdl.mp("DENS", 1, 1000)  # Density in kg/m3
mapdl.mp("SONC", 2, 1500)  # sonc in m/s
mapdl.mp("DENS", 2, 1000)  # Density in kg/m3
print(mapdl.mplist())
  • Define real const

mapdl.r('1', '1e-6')
mapdl.r('2', '1')
print(mapdl.rlist())
  • make a hollow sphere

vnum = mapdl.sphere(rad1=0.5, rad2=1.0)
mapdl.vsbw('all')
mapdl.vplot(show_area_numbering=True)
  • mesh 30

mapdl.type(itype=1)  
mapdl.real(nset=1)
mapdl.mat(mat=1)
mapdl.mshape(1, '3D')
mapdl.esize(1.5)
mapdl.vmesh('all')
mapdl.eplot(show_node_numbering=False, vtk=None)
  • add boundary condition

mapdl.csys(2)
mapdl.asel('s', 'loc', 'x', 0.5)
mapdl.csys(0)
mapdl.nsla('S', 1)
mapdl.sf('all', 'SHLD', 0.05)
mapdl.allsel()
  • solu

mapdl.run('/SOLU')
mapdl.antype(3)
mapdl.harfrq(freqb=100)
mapdl.allsel()
mapdl.solve()
mapdl.exit()
  • error!!!

CRITICAL -  -  logging - handle_exception - Uncaught exception
Traceback (most recent call last):
  File "D:/CODE_1/puthon_code/SPHERE_INFEM", line 68, in <module>
    mapdl.solve()
  File "D:\code_language\python3.8.10\lib\site-packages\ansys\mapdl\core\_commands\solution\analysis_options.py", line 3425, in solve
    return self.run(command, **kwargs)
  File "D:\code_language\python3.8.10\lib\site-packages\ansys\mapdl\core\mapdl.py", line 2630, in run
    text = self._run(command, verbose=verbose, mute=mute)
  File "D:\code_language\python3.8.10\lib\site-packages\ansys\mapdl\core\mapdl_corba.py", line 380, in _run
    text = self._server.executeCommandToString(command)
  File "D:\code_language\python3.8.10\Lib\site-packages\ansys_corba\ICoMapdlUnit_idl.py", line 206, in executeCommandToString
    return self._obj.invoke("executeCommandToString", _0_AAS_CORBA.MAPDL.Solvers.ICoMapdlUnit._d_executeCommandToString, args)
AAS_CORBA.MAPDL.Exceptions.EAnsysUnknown: AAS_CORBA.MAPDL.Exceptions.EAnsysUnknown(code=-15, description='Low-level communication error -15: Connection was closed', scope='MAPDL', interfaceName='ICoMapdlUnit', operation='executeCommand', moreInfo='SOLVE,')

Which Operating System are you using?

Windows

Which Python version are you using?

3.8

PyMAPDL Report

PyMAPDL Software and Environment Report

Packages Requirements


Core packages

ansys.mapdl.core : 0.63.1
numpy : 1.23.2
appdirs : 1.4.4
scipy : 1.9.1
grpc : Package not found
ansys.api.mapdl.v0 : Package not found
ansys.mapdl.reader : 0.51.15
google.protobuf : Package not found

Optional packages

matplotlib : 3.5.3
pyvista : 0.36.1
pyiges : 0.2.1
tqdm : 4.64.0
ansys_corba : 0.1.1

Ansys Installation


Unable to locate any Ansys installations

Ansys Environment Variables


ANSYS192_DIR D:\setup_position_1\ansys19.2\ANSYS Inc\v192\ANSYS
ANSYS_SYSDIR winx64
ANSYS_SYSDIR32 win32
AWP_ROOT192 D:\setup_position_1\ansys19.2\ANSYS Inc\v192
CADOE_LIBDIR192 D:\setup_position_1\ansys19.2\ANSYS Inc\v192\CommonFiles\Language\en-us

Installed packages

aiohttp==3.8.1
aiosignal==1.2.0
ansys-api-mapdl==0.5.1
ansys-api-platform-instancemanagement==1.0.0b3
ansys-corba==0.1.1
ansys-mapdl-core==0.63.1
ansys-mapdl-reader==0.51.15
ansys-platform-instancemanagement==1.0.2
appdirs==1.4.4
async-timeout==4.0.2
attrs==22.1.0
charset-normalizer==2.1.1
colorama==0.4.5
cycler==0.11.0
fonttools==4.37.1
frozenlist==1.3.1
geomdl==5.3.1
googleapis-common-protos==1.56.4
grpcio==1.48.0
idna==3.3
imageio==2.21.2
importlib-metadata==4.12.0
kiwisolver==1.4.4
matplotlib==3.5.3
multidict==6.0.2
numpy==1.23.2
packaging==21.3
Pillow==9.2.0
protobuf==3.20.1
protoc-gen-swagger==0.1.0
pyiges==0.2.1
pyparsing==3.0.9
python-dateutil==2.8.2
pyvista==0.36.1
scipy==1.9.1
scooby==0.6.0
six==1.16.0
tqdm==4.64.0
vtk==9.1.0
wslink==1.8.2
yarl==1.8.1
zipp==3.8.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions