-
Notifications
You must be signed in to change notification settings - Fork 121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow iterables in mapdl.cmsel
#3425
Comments
Mmhhh.. Now I think about it... it might not make much sense to have iterables..... New selection
|
I am wondering if makes sense to overload the math operators for selections. Given: # node selection 1
cm1 = mapdl.cm("cm1", "nodes") # current implementation does not return anything
# node selection 2
cm2 = mapdl.cm("cm2", "nodes")
mapdl.select # imaginary function to select components What the following operation will mean:
|
Python operator | MAPDL operation | Python example | PyMAPDL command |
---|---|---|---|
and |
Reselect R |
mapdl.select(cm1 and cm2) |
mapdl.cmsel("S", "cm1");mapdl.cmsel("R", "cm2") |
or |
Add A |
mapdl.select(cm1 or cm2) |
mapdl.cmsel("S", "cm1");mapdl.cmsel("A", "cm2") |
not |
Unselect U |
mapdl.select(not cm1) |
mapdl.cmsel("U", "cm1") |
Pinging @koubaa, @mcMunich, @mikerife and @pthieffry for feedback before considering it for future work. |
@germa89 I much prefer the idea of logic operators than iterables. I concur with your assessment on the ambiguity iterables could introduce. |
As the title.
The text was updated successfully, but these errors were encountered: