Both these options could be handled: - Allow r = 0 for P elements and handle the switch from continuous to discontinuous inside the form compiler, which will anyway need a lot of if-else checking since many of the names are different in FIAT.
- Introduce shortcuts in some cases, but note that both the "Q" elements and the "S" elements are essentially different from the "P" elements so it doesn't make sense that "P" should work for all of them. In the case of discontinuous elements, we would need to introduce an alias for "DP" --> "DPC". -- Anders On Mon, Mar 03, 2014 at 12:30:50PM +0100, Garth N. Wells wrote: > > On 3 Mar 2014, at 12:09, Martin Sandve Alnæs <[email protected]> wrote: > > > I prefer the second option here over the first. > > > > But I don't like not being able to switch between (continuous) piecewise > > linear and piecewise constant elements with just the degree. There's a lot > > of code snippets a'la 'family = lamda degree: "DG" if degree == 0 else > > "CG"' around in user code. > > > > Agree. This can be annoying. > > > For similar reasons, I don't like having to select e.g. P,Q,S depending on > > the cell type, when we already have the cell type specified otherwise. That > > will make writing mesh-type independent code more difficult when we get > > support for quads. > > > > Agree. > > Garth > > > I'm pretty sure a family alias which maps to P/Q/S depending on the cell > > for degree>0 and DP/DQ/DS for degree==0 would quickly become the most > > popular one. > > > > Martin > > > > > > On 3 March 2014 09:47, Anders Logg <[email protected]> wrote: > > I would like the names to be as consistent with the poster as > > possible. After all, we are printing the UFL names in the poster next > > to the element names. > > > > I see two options: > > > > 1. Either we keep the UFL names as suggested: > > > > P dP > > P RTe/RTf dP > > P N1e N1f dP > > > > P dP > > P BDMe/BDMf dP > > P N2e N2f dP > > > > Q dQ > > Q RTce/RTcf dQ > > Q Nce Ncf dQ > > > > S dPc > > S BDMce/BDMcf dPc > > S AAe AAf dPc > > > > 2. Or, as suggested but all uppercase: > > > > P DP > > P RTE/RTF DP > > P N1E N1F DP > > > > P DP > > P BDME/BDMF DP > > P N2E N2F DP > > > > Q DQ > > Q RTCE/RTCF DQ > > Q NCE NCF DQ > > > > S DPC > > S BDMCE/BDMCF DPC > > S AAE AAF DPC > > > > I think I would vote for the second option. > > > _______________________________________________ fenics mailing list [email protected] http://fenicsproject.org/mailman/listinfo/fenics
