2

I am working on Pyansys mapdl reader to visualise the values on the FE model. I have calculated few scalar values of no.of cycles to failure at each element and wrapped around the mesh to visualise it but the issue here is that the maximum values of scalar are in a range of blue colour in scalar_bar_args. I am attaching you the picture of the result. My question is do we have an option to visulaise only critical area or any method to scale the scalar_bar_args so that all the values are visible clearly. I will also attach the code in the attachments. Please let me know is there is any solution. It would be appreciated for the early reply

solver,filename_FEM = "ansys", "C:/Users/Desktop/SpecimenModel_ANSYS/BZ12_CADMOULDKOS_W0_PA66GF30_files/dp0/SYS-8/MECH/ds.dat"
if solver.lower() =="ansys": #Read RECIEVING MESH File via pyanys

# Read FEM archive file
    archive_FEM = pymapdl_reader.Archive(filename_FEM, parse_vtk=True,force_linear=True)
    print ("archive_FEM.enum Ansys element numbers", archive_FEM.enum)
mesh_FEM = archive_FEM.grid
#Ansys-Informationen sind im Grid in cell_data gespeichert! mesh_FEM.cell_data
print ("mesh_FEM.cell_data", mesh_FEM.cell_data)                 
points = mesh_FEM.points
mesh_FEM.cell_data["my_data"] = np.arange(mesh_FEM.n_cells)
print(mesh_FEM.cell_data)
scalars = cycles

sbar_kwargs = {"color": "black", "title": "life cycles"}
mesh_FEM.plot(scalars= scalars,show_scalar_bar=True, show_edges= True,
scalar_bar_args=sbar_kwargs)
[![Pyansys mapdl reader view][1]][1]
  [1]: https://i.stack.imgur.com/3bbj6.png
suss
  • 31
  • 3
  • Without the file is going to be very difficult to suggest a solution. I would open an issue in their repo, although this project is almost discontinued. – Ger May 30 '23 at 14:36

0 Answers0