Concentration is zero in some subdomains

Hi everyone.

I performed a simulation of hydrogen transport in W/Cu/CuCrZr in 2D. I used big mesh size to make the computation quick. The exported chemical_pot_conservation derived_quantities file show the result. As is seen in the picture below, the total retention in volume 7 and 8, the flux on surface 15 are missing. Can anyone tell me that what might cause this problem and how to solve it? Thank you!

Hi Xin,

It is a bit hard to tell without more information.

Are you certain that you have volumes 7 and 8 and surface 15 in your model?
To verify this, open your XDMF mesh files in Paraview.

If you are certain that one of the surfaces is tagged with the ID 15, then what boundary condition did you put on surface 15?
If you haven’t set any BC on this subdomain than the default is “no flux” which would explain why this column is zero.

Hi Remi,

Here is the image of my model after opening the mesh_domain and mesh _boundaries files in Paraview.

The boundary condition I put on 15 is:

F.RecombinationFlux(Kr_0=2.9e-14, E_Kr=1.92, order=2, surfaces=[id_CuCrZr_inner])

could you send the code to reproduce your issue? alongside the meshes (XDMF + h5 files)

Yes, of course. I’ll send you by email because it seems more convenient to attach the meshes.

Thank you very much!

import festim as F

my_model = F.Simulation()

my_model.mesh = F.MeshFromXDMF(
    volume_file="mesh_domains.xdmf",
    boundary_file="mesh_boundaries.xdmf",
)
my_model.materials = F.Material(D_0=1, E_D=0, id=[6, 7, 8])


my_model.boundary_conditions = [
    F.DirichletBC(field="solute", value=1, surfaces=[9]),
]

my_model.T = F.Temperature(823)

my_model.exports = [F.XDMFExport("solute")]


my_model.settings = F.Settings(
    chemical_pot=False,
    absolute_tolerance=1e-10,
    relative_tolerance=1e-10,
    transient=False,
)

my_model.initialise()

my_model.run()

This reproduces the behaviour:

mesh_boundaries.xdmf (587 Bytes)
mesh_domains.h5 (78.9 KB)
mesh_domains.xdmf (581 Bytes)
mesh_boundaries.h5 (52.4 KB)

1 Like

I think there may have been an issue when making the mesh. Would you be able to describe the process you underwent to create it?

1 Like

I compounded the volumes then did the mesh straightly.

Now I realized that I missed the partitioning. After the modification, the results are not zero anymore.

Thank you!

Thank you very much!