feelpp icon indicating copy to clipboard operation
feelpp copied to clipboard

Support keywords/language with marker name on mesh filters

Open vincentchabannes opened this issue 3 years ago • 8 comments

In order to facilitate the access on mesh entities (as marked or topological type, i.e elements, boundaryfaces, ....),we can define special keywords that can be used with markedelements(.), markedfaces(.) ,markededges(.) and markedpoints(.) :

  • @elements@: corresponds to elements(mesh)
  • @boundaryelements@ : corresponds to boundaryelements(mesh)
  • @markedelements("toto","titi")@ : corresponds to markedelements(mesh,{"toto","titi"})
  • @boundaryfaces@ : corresponds to boundaryfaces(mesh)
  • @internalfaces@: corresponds to internalfaces(mesh)
  • ...

Another feature will be support also a small language that allows applying merge, intersect and difference operation.

*@merge(internalfaces,markedfaces("toto")@ : correspond to all internal faces and marked faces called "toto" *@intersect(boundaryfaces,markedfaces("toto")@ : correspond to boundary faces with marker called "toto" *@diff(boundaryfaces,markedfaces("toto")@ : correspond to all boundary faces except for markedfaces called "toto"

The delimiter keyword @will be a special character, i.e. a marker will can't have more than one @ character.

This feature will be very useful in Feel++-toolboxes in the json description.

vincentchabannes avatar Mar 03 '22 07:03 vincentchabannes

how about using |, in math it is often use to measure something ?

prudhomm avatar Mar 03 '22 08:03 prudhomm

Will "markers":["toto","titi"] still be accepted ? Also, will it really be elements(mesh) or will it be the elements of the support of the function space associated with the expression ?

romainhild avatar Mar 03 '22 08:03 romainhild

@romainhild it's not related to toolbox json format, so you can of course write "markers":["toto","titi"] but the idea is to write also "markers":["toto","@boundaryfaces@"].

And yes, it will support also mesh support (just developers must use the mesh support when we called markedelements), but need a little reflection if make sense

vincentchabannes avatar Mar 03 '22 08:03 vincentchabannes

@prudhomm I don't understand, why do you talk about measures?

vincentchabannes avatar Mar 03 '22 08:03 vincentchabannes

I would prefer |boundaryfaces| rather than @boundaryfaces@ my point was that | is used in math, eg |Omega|

prudhomm avatar Mar 03 '22 19:03 prudhomm

it's not a measure (or cardinality), it returns a set of entities. This keyword is a delimiter for a special syntax/language interpreted and I think @ is more visible than |

vincentchabannes avatar Mar 03 '22 21:03 vincentchabannes

Stale issue message

github-actions[bot] avatar Apr 15 '23 23:04 github-actions[bot]

Stale issue message

github-actions[bot] avatar Apr 10 '24 23:04 github-actions[bot]