Forum Message

 

 

We have moved the forum to https://forum.ngsolve.org . This is an archived version of the topics until 05/05/23. All the topics were moved to the new forum and conversations can be continued there. This forum is just kept as legacy to not invalidate old links. If you want to continue a conversation just look for the topic in the new forum.

Notice

The forum is in read only mode.

Normalization of Grid-function on a single region

More
1 year 10 months ago #4364 by ajf367
Hello, 

I'm trying to figure out the "best" way to normalize a resulting grid function on a subsection of the mesh. For the purposes of this topic I'm considering an Eigenvalue-Problem similar to 1.7.1 in the tutorial ( docu.ngsolve.org/nightly/i-tutorials/uni...7-helmholtz/pml.html ).

The geometry is as follows: 
Code:
geo = SplineGeometry() geo.AddCircle( (0.0, 0.0), r=1.0, leftdomain=1, rightdomain=2, bc = "scatterer") geo.AddCircle ( (0.0, 0.0), r=2.0, leftdomain=2, rightdomain=3) geo.AddCircle ( (0.0, 0.0), r=3.0, leftdomain=3, rightdomain=0,bc = "dir")

I've modified the Arnoldi solver to output only the eigenvalue I want and have the resulting gridfunction u associated with it. However, I want to normalize u only on region 1. 
Do I need to define a new mesh that only covers region 1 to integrate it or is there a way to restrict the integral only to the first region?

Thanks, 
AJ 
More
1 year 10 months ago #4365 by joachim
you can integrate over a region, see

help (Integrate)

 
The following user(s) said Thank You: ajf367
Time to create page: 0.140 seconds