- Thank you received: 0
Defining HCurl space of type 1 for specific degrees of freedom
5 years 4 months ago - 5 years 4 months ago #1680
by Elsakori
Hello,
I am using NGSolve to solve Maxwell’s equations in time-harmonic form. I created a finite element space as:
fes = HCurl(mesh, order=1, type1=True, dirichlet="outer"),
fes.SetOrder(TRIG,2)
fes.SetOrder(TET,3)
fes.Update()
Can I define HCurl space with just face degrees of freedom of order 2, HCurl space with just cell degrees of freedom of order 3, or HCurl space with both face degrees of freedom of order 2 and cell degrees of freedom of order 3?
I am grateful for any help
I am using NGSolve to solve Maxwell’s equations in time-harmonic form. I created a finite element space as:
fes = HCurl(mesh, order=1, type1=True, dirichlet="outer"),
fes.SetOrder(TRIG,2)
fes.SetOrder(TET,3)
fes.Update()
Can I define HCurl space with just face degrees of freedom of order 2, HCurl space with just cell degrees of freedom of order 3, or HCurl space with both face degrees of freedom of order 2 and cell degrees of freedom of order 3?
I am grateful for any help
Last edit: 5 years 4 months ago by Elsakori.
- mneunteufel
- Offline
- Premium Member
Less
More
- Thank you received: 59
5 years 4 months ago #1686
by mneunteufel
Replied by mneunteufel on topic Defining HCurl space of type 1 for specific degrees of freedom
Hi Elsakori,
you will always have the lowest order degrees of freedom at the edges.
With your example you create an HCurl space with face degrees of freedom of order 2 and cell degrees of freedom of order 3 + the lowest order edge degrees of freedom.
Attached you'll find a minimal example creating different kind of HCurl spaces and the number of degrees of freedom.
If you really want to neglect the lowest order edge dofs you need to work with BitArrays, or set them as unused_dofs.
Best
Michael
you will always have the lowest order degrees of freedom at the edges.
With your example you create an HCurl space with face degrees of freedom of order 2 and cell degrees of freedom of order 3 + the lowest order edge degrees of freedom.
Attached you'll find a minimal example creating different kind of HCurl spaces and the number of degrees of freedom.
If you really want to neglect the lowest order edge dofs you need to work with BitArrays, or set them as unused_dofs.
Best
Michael
Attachments:
The following user(s) said Thank You: Elsakori
5 years 4 months ago #1692
by Elsakori
Replied by Elsakori on topic Defining HCurl space of type 1 for specific degrees of freedom
Hello Michael,
Thank you for your response and clarification.
As you mentioned in the last line, I want to neglect the lowest order edge dofs. I want HCurl space just with face degrees of freedom of order 2 and cell degrees of freedom of order 3. Can you explain more about setting them as "unused_dofs" in my case?, I couldn't find more information about "unused_dofs" in the website.
Thanks,
Ahmed
Thank you for your response and clarification.
As you mentioned in the last line, I want to neglect the lowest order edge dofs. I want HCurl space just with face degrees of freedom of order 2 and cell degrees of freedom of order 3. Can you explain more about setting them as "unused_dofs" in my case?, I couldn't find more information about "unused_dofs" in the website.
Thanks,
Ahmed
- mneunteufel
- Offline
- Premium Member
Less
More
- Thank you received: 59
5 years 4 months ago #1693
by mneunteufel
Replied by mneunteufel on topic Defining HCurl space of type 1 for specific degrees of freedom
Hi Elsakori,
I managed to "neglect" the lowest order dofs by using bitarrays and setting them as UNUSED_DOF.
It is important that the lowest order dofs are saved before all other dofs.
Attached you find both approaches .
Best
Michael
I managed to "neglect" the lowest order dofs by using bitarrays and setting them as UNUSED_DOF.
It is important that the lowest order dofs are saved before all other dofs.
Attached you find both approaches .
Best
Michael
Attachments:
The following user(s) said Thank You: Elsakori
5 years 4 months ago - 5 years 4 months ago #1694
by Elsakori
Replied by Elsakori on topic Defining HCurl space of type 1 for specific degrees of freedom
Hi Michael,
Thank you so much.
It is much clear now, I will try using these approaches in my code.
Thanks,
Ahmed
Thank you so much.
It is much clear now, I will try using these approaches in my code.
Thanks,
Ahmed
Last edit: 5 years 4 months ago by Elsakori.
Time to create page: 0.106 seconds