Implementing FDM Boundary Conditions at a Red Point

In summary, the Finite Difference Method (FDM) uses the continuity of parallel component of magnetic field intensity to implement boundary conditions. At the interface of two areas, interpolation can be used to express the field at a point midway between the intersection point and the closest sample point along the boundary, and the boundary condition can be applied to this interpolated point. In this case, both $H_x$ and $H_y$ components must be continuous, which can be challenging when only one equation is required for each node. One solution is to use interpolation, as suggested by Mr. Colby, who also shares knowledge on using a half-way mesh sizing technique. However, the equations at the singular node may require further refinement, as the mesh size can
  • #1
Hosein Javanmardi
5
0
TL;DR Summary
confused about the boundary equation in the form of FDM at a node located right at the interface of three areas with different permeabilities.
in Finite Difference Method (FDM), the boundary conditions can be implemented by applying the continuity of parallel component of magnetic field intensity. when it comes to the interface of two areas, it is done at ease, but consider this case at the red point:
boundary.png

in FDM we exactly require on equation for each node. however in this case, both $H_x$ and $H_y$ components must be continous. although I am confused about the equation at this node, I cannot find one equation to satisfy all conditions at this point.
any suggestions? thanks.
 
Physics news on Phys.org
  • #2
One of the things I've done in the past is use interpolation to express the field at a point midway between the intersection point and the closest sample point along the boundary. The boundary condition is then applied to this interpolated point which by its definition resides between just two regions.
 
  • Like
Likes Hosein Javanmardi
  • #3
thank you Mr Colby for sharing knowledge. it seems genius to use interpolation, I don't know how to formulate. but thus far I have written this equation based on Ampere's circuit law around the singular node:
$$-2hH_x(x_b,y_b^-)+hH_y(x_b^-,y_b^+)+hH_x(x_b^-,y_b^+)+hH_x(x_b^+,y_b^+)-hH_y(x_b^+,y_b^+)=0$$
where ##H_x## and ##H_y## denote the x and y component of magnetic field intensity and ##x_b^-##and ##x_b^+## and ##y_b^-## and ##y_b^+## are the x and y coordinates of the singular node. the superscript (+) and (-) means for left and right derivatives when writing ##H## in terms of ##A_z## derivatives. and ##h## is the mesh size.
do you think it is correct? if not please tell me about the interpolation equation at this node.
 
  • #4
Two questions. What boundary conditions are you applying on the outer boundary? Away from all boundaries what are your equations exactly?
 
  • Like
Likes Hosein Javanmardi
  • #5
Hello again. the actual problem is more complicated. in order to realize a more realistic one, I will add a fourth area above (1) and (2).
1615712475535.png

in this example the equations are as following:
in area (1) and (3) and (4):
$$\nabla^2A_z=0$$
in area (2):
$$\nabla^2A_z=f$$
where ##f## is a given nonhomogeneous function due to permanent magnet.
materials in each area:
(1)=soft magnetic(##\mu_{r1}=2000##),
(2)=permanent magnet magnetized in x direction(##\mu_{r2}=1.05##),
(3) and (4)= non magnetic material(##\mu_{r3}=mu_{r4}=1.00##)
the boundary conditions on the left, above and bottom outer edges is dirichlet:
$$A_z=0$$
on the right outer edge it is symmetry condition:
$$A_z(x-h,y)=A_z(x+h,y)$$
 
  • #6
This is very close to the 2D problem I did so many years ago (##A_z=E_z## and ##f=0##). My suggestion is to select your grid so the interior boundaries are centered half way in between grid points[1]. Use interpolation between regions of continuous quantities to determine them on the boundary. As I recall there were points at which I used extrapolation to fill in points where interpolation wasn't an option (points at which ##E_z = 0## for example). Another difference I used square grid but allowed boundaries to be general lines.

[1] the reason to do this is so the center of every computational molecule is an interior point. For example if a point x is near a boundary at which ##E_z=0## then an extrapolation through x to a point on the boundary must yield 0. Adjust ##E_z## at x accordingly.
 
  • Informative
Likes Hosein Javanmardi
  • #7
thank you again Mr. Colby. to use linear interpolation, is it enough to say:
$$4A_z(x_b,y_b)=A_z(x_b-h,y_b)+A_z(x_b+h,y_b)+A_z(x_b,y_b-h)+A_z(x_b,y_b+h)$$
although I was wondering that this interpolation plot would lead to the same laplace equation. and it is in contrast with the magnetostatic boundary condition.
the half way mesh sizing technique is also interesting. but I am intentionally placing nodes on the interfaces to achieve the most accurate left and right derivatives for the boundary condition.
I'm really interested to find the physical boundary equation. however this answer really helped. thank you again.
 
  • #8
Recall that only interior points obey the differential equation, ##\nabla^2A_z = f##. If ##x_b## refers to a boundary or interface point, then I don't think your equation is what you want since it's treating the boundary as an interior point. Some of the derivatives are not continuous across the boundary. On the boundary the values are either fixed by the problem or you must express them in terms of values at points on the interior by applying the boundary condition (on tangent H for example).

As I recall I was doing a time stepping calculation, not an elliptic one like yours. There was a time step which updated values followed by a boundary condition correction step. To do this in your case requires the equations you are seeking be included in your system matrix.

In your case ##H_x = \frac{\partial A_z}{\partial y}## is continuous across a horizontal boundary but discontinuous across a vertical one. You know this discontinuity exactly from the constitutive relations. Similar situation for ##H_y##.

Some depends on your solution method. Is it iterative or direct for example. If it's iterative then it might be possible to split the iteration into one that updates the interior region assuming known boundary values followed by an interpolation step to fix the boundary conditions using the interior values.
 
  • #9
Yes, I know that the laplace equation is valid only on interior nodes. all that you mentioned is completely correct. but I was just wondering how come the linear interpolation method and the discrete laplace equation on the node will result the same equation(if my interpolation was correct).
by the way how can I accept your answer? it seems physics forum is a little different than other websites like stackexchange. thanks.:smile:
 
  • #10
Hosein Javanmardi said:
I was just wondering how come the linear interpolation method and the discrete laplace equation on the node will result the same equation(if my interpolation was correct).
I don't believe they will be the same. They can't be because not all second derivatives of ##A_z##
exist on the boundary.

Hosein Javanmardi said:
how can I accept your answer?
No worries. PF is more of a discussion than a here's your answer site. I haven't given any answers just ways I've done similar things in the past. Without working your problem completely, I don't know the answer. There is likely more than one for that matter.
 

FAQ: Implementing FDM Boundary Conditions at a Red Point

What is FDM and how is it used in boundary conditions?

FDM stands for Finite Difference Method and it is a numerical technique used to solve differential equations. In the context of boundary conditions, FDM is used to discretize the boundary and calculate the values of the solution variables at the boundary points.

Why is it important to implement FDM boundary conditions at a red point?

The red point, also known as the red boundary, is the point where the boundary conditions are applied. It is important to implement FDM at this point because it ensures that the solution at the boundary is accurate and consistent with the rest of the solution domain.

How do you determine the appropriate boundary conditions for a red point?

The appropriate boundary conditions for a red point depend on the specific problem being solved. They can be determined by analyzing the physical properties of the system and considering the behavior of the solution at the boundary.

What are some common challenges in implementing FDM boundary conditions at a red point?

One common challenge is ensuring that the boundary conditions are properly applied to the red point. This can be difficult if the boundary is complex or if there are multiple boundary conditions to be applied. Another challenge is selecting the appropriate discretization scheme for the boundary, as this can affect the accuracy of the solution.

Are there any alternative methods to FDM for implementing boundary conditions at a red point?

Yes, there are other numerical methods such as Finite Element Method (FEM) and Boundary Element Method (BEM) that can also be used to implement boundary conditions at a red point. These methods may be more suitable for certain types of problems, but FDM remains a popular and widely used technique.

Back
Top