Closed HanyMKhalil closed 3 years ago
I am using UWgeodynmaics
Hi, Hany You may try with a self-defined temperature field, not just the boundary condition. which can follow the example here 1_31_User_defined_geotherm_and_TP_dependent_densities
Here is a 2D case example, 3D should be similar:
T_mp = (2250.+273.15) * u.degK
mp_geotherm = GEO.nd(T_mp)
condition_mp = ((Model.x-GEO.nd(center_x_plume))**2 + (-Model.y+GEO.nd(center_y_plume))**2) <= GEO.nd(R_plume)**2
geotherm_fn = fn.branching.conditional([(Model.y >= GEO.nd(0 * u.kilometer), GEO.nd(T0)),
(-Model.y <= GEO.nd(H_c), crust_geotherm),
(-Model.y <= GEO.nd(H_LAB), lithosphere_geotherm),
(-Model.y <= GEO.nd(H_Inma), mantle_geotherm1),
(condition_mp,GEO.nd(T_mp)),
(True, mantle_geotherm2)])
Model.temperature = True
Model.temperature.data[...] = geotherm_fn.evaluate(Model.mesh)
Model.set_temperatureBCs(top=T0, bottom=Tz,materials=[(mp, T_mp),(air,T0)])
That is a good approach for setting a geothermal gradient @NengLu
If you want a constant temperature for the material @HanyMKhalil you can use my approach below:
### set the plume material to a temperature of 2000 Kelvin
Model.temperature.data[:,0][Model.projMaterialField.data[:,0] == plume.index] = GEO.nd(2000 * u.degK)
Change plume.index to your material and then you can also change the temperature.
This will diffuse over time, if you want it to remain at the same temperature you can either set it in the BC as @NengLu does above for the air and mantle, or you could add a function in the pre or post solve loop that updates the temperature using the same line of code as above.
Cheers
I'm assuming this is resolved. Feel free to reopen if needed.
Dear Romain, all,
How can I add a thermal hemispherical weakness, e.g., plume head, in a middle of 3D model?
I tried to add spherical material and assign a temperature for it in the Temperature boundary conditions but did-not work. any work around this?? how can I alter the geothermal gradient so that I creates anomaly with hemispherical or linear shape?
Thanks alot