Open DanielCohenHillel opened 4 years ago
I don’t recall off the top of my head that this options is in the codebase right now. I don’t think I’ve used it yet. I’d have to check the Ansys API manual, but I do imagine as you say that it is likely it exits. I plan to do some work on the codebase next week, and can also try to see it.
From: Daniel Cohen Hillel notifications@github.com Reply-To: zlatko-minev/pyEPR reply@reply.github.com Date: Sunday, May 17, 2020 at 9:58 AM To: zlatko-minev/pyEPR pyEPR@noreply.github.com Cc: Subscribed subscribed@noreply.github.com Subject: [zlatko-minev/pyEPR] Add automatic surface energy calculation (#39)
If you want to calculate the electric energy of a volume you can simply use DistributedAnalysis.calc_energy_electric(), but if you want to calculate the energy of a surface you need to write the code manually. The two codes are nearly identical with the only difference being that you need to replace the line A = A.integrate_vol(name=volume) with A = A.integrate_surf(name=surf). Now, I could've simply added a boolean surface or something and it would work just fine but I think it would be best if the function would automatically check if the name given is a volume or a surface (or an edge). I don't think it would be that difficult but I didn't found where in the code you can get a list of names + their corresponding type (i.e. solid\sheet\edge). If there is no such option I could add it myself but I'm posting this because there might be such option that I didn't found, or maybe someone wants to give it a go before I get to it 😉
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.
If you want to calculate the electric energy of a volume you can simply use
DistributedAnalysis.calc_energy_electric()
, but if you want to calculate the energy of a surface you need to write the code manually. The two codes are nearly identical with the only difference being that you need to replace the lineA = A.integrate_vol(name=volume)
withA = A.integrate_surf(name=surf)
. Now, I could've simply added a booleansurface
or something and it would work just fine but I think it would be best if the function would automatically check if the name given is a volume or a surface (or an edge). I don't think it would be that difficult but I didn't found where in the code you can get a list of names + their corresponding type (i.e. solid\sheet\edge). If there is no such option I could add it myself but I'm posting this because there might be such option that I didn't found, or maybe someone wants to give it a go before I get to it 😉