Changes between Version 9 and Version 10 of AstroBearProjects/multiphysics
- Timestamp:
- 01/07/14 19:16:44 (11 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
AstroBearProjects/multiphysics
v9 v10 1 = =================================== = 2 = Viscosity and Resistivity in AstroBEAR = 3 = =================================== = 4 5 '''Viscosity''' [[BR]][[BR]] 6 1 == Viscosity == 2 [[BR]] 7 3 The viscosity term in the Navier-Stokes Equation can be separated as:[[BR]][[BR]] 8 4 [[latex($dv/dt = \nabla \cdot T$)]][[BR]] … … 16 12 Notice that this equation already counts the effect of all the elements in a viscosity tensor, assuming the fluid itself is isotropic.[[BR]] 17 13 [[BR]][[BR]] 18 19 '''Resistivity''' [[BR]][[BR]]20 21 The resistivity equation can be written as:[[BR]]22 [[latex($\frac{\partial \textbf{B}}{\partial t}=\nabla \times (\eta \nabla \times \textbf{B})$)]][[BR]][[BR]]23 Here, the magnetic field are located at face centers. Using the face centered magnetic field, we can calculate the edge centered currents, which then give a source term.[[BR]]24 The curl of the edge centered source term gives a face centered [[latex($\delta B$)]], which can then be applied to the face centered magnetic field.25 26 = =================================== =27 = Implementation =28 = =================================== =29 '''Viscosity''' [[BR]][[BR]]30 14 31 15 The viscous source term is calculated rigorously by first finding the tensor elements at the surrounding face centers of a cell center considered: … … 50 34 The viscosity module is tested to be working compatibly with implicit thermal conduction module and uniform gravity module.''[[BR]][[BR]] 51 35 52 '''Resistivity''' [[BR]][[BR]] 53 54 '''Implicit Implementation of Resistivity''' [[BR]][[BR]] 36 == Resistivity == 37 [[BR]] 38 39 The resistivity equation can be written as:[[BR]] 40 [[latex($\frac{\partial \textbf{B}}{\partial t}=\nabla \times (\eta \nabla \times \textbf{B})$)]][[BR]][[BR]] 41 Here, the magnetic field are located at face centers. Using the face centered magnetic field, we can calculate the edge centered currents, which then give a source term.[[BR]] 42 The curl of the edge centered source term gives a face centered [[latex($\delta B$)]], which can then be applied to the face centered magnetic field. 55 43 56 44 The resistive equation can be written as:[[BR]] … … 175 163 (D1) Computationally much more intense while still requires subcycling. The CFL is instead given by [[latex($\eta dt/l^2$)]][[BR]][[BR]] 176 164 177 '''Microphysical Resistivity as Explicit Source Term''' 178 165 == Microphysical Resistivity as Explicit Source Term == 166 [[BR]] 179 167 For each cell, the resistive source term is calculated by taking the curl of face centered magnetic field. This results in a 12 dimension array that stores the current source terms running over the 12 edges of a cell in 3-D. This array is then used to calculate the new face centered magnetic field. The stencil for this explicit solver is a 3 by 3 cube surrounding the cell we want to update. See the following diagram:[[BR]][[BR]] 180 168 [[Image(http://www.pas.rochester.edu/~shuleli/res_dia1.png, 25%)]][[BR]][[BR]] … … 207 195 or, the gyro frequency to be much greater than the mean electron ion collision frequency. [[BR]] 208 196 This effect is not considered currently. [[BR]][[BR]] 209 210 '''Resistivity Interface'''211 197 212 198 Currently in the code, the microphysical resistivity gets calculated at each cell edges by averaging the temperatures and density information surrounding that edge. [[BR]][[BR]] … … 220 206 If ResType = 3, the resistivity is microphysical and is automatically calculated using the scaling parameters. the "resistivity" parameter will be ignored [[BR]] 221 207 The [[latex($F(Z_{eff})$)]] function gets calculated automatically via and is a global const.[[BR]] 222 If ResType = 3, The microphysical resistivity automatically scales with the input scaling parameter.[[BR]] 223 224 '' 225 226 '''Thermal Conduction''' [[BR]][[BR]] 227 208 If ResType = 3, The microphysical resistivity automatically scales with the input scaling parameter.[[BR]][[BR]] 209 210 211 == Thermal Conduction == 212 [[BR]] 228 213 The anisotropic thermal conduction is determined by the following equations: [[BR]][[BR]] 229 214 [[latex($\kappa_{align} = 5.6 \times 10^{-7} T^{5/2}$)]][[BR]] … … 254 239 [[Image(saturationflux.png, 40%)]][[BR]][[BR]] 255 240 256 '''Thermal Conduction Interface''' [[BR]]257 241 The anisotropic thermal conduction can be turned on by putting: [[BR]] 258 242 '''lresistive = .true.'''[[BR]] … … 262 246 '''conductivity''': effective only when the conductivity is computational. [[BR]] 263 247 '''lisodiffusion''': a bool that controls whether there is artificial thermal diffusion. This diffusion is isotropic.[[BR]] 264 '''isodiffusionratio''': controls the ratio between artificial diffusion and actual diffusion. For instance, setting this ratio to 0.01 will add an artificial isotropic thermal diffusion [[BR]] 248 '''isodiffusionratio''': controls the ratio between artificial diffusion and actual diffusion. For instance, setting this ratio to 0.01 will add an artificial isotropic thermal diffusion [[BR]][[BR]] 265 249 that is 100 times weaker than the minimal actual diffusion on the grid. [[BR]] 266 250 267 268 269 270 = =================================== = 271 = Multiphysics Integration = 272 = =================================== = 273 251 == Multiphysics Integration == 252 [[BR]] 274 253 Taking viscosity as an example. The goal for the multiphysics modules is to calculate a change of velocisty inside a grid, using the known hydro vars. [[BR]] 275 254 This integration can be done before any hyperbolic updates. We denote the hyperbolic update, integrated source term calculation and explicit source term calculation as H, S and E. [[BR]] … … 298 277 1) each complete update requires two more ghost zones on parent-child boundaries which does not fit into the source term subcyclilng. (N subcycling requires 2N ghost zones) [[BR]] 299 278 2) for internal boundary to direct neighbors, the two grids need to communicate in order to . This again does not fit into the source term subcycling. (there is no communications happening during subcycling in the current code)[[BR]] 300 301 302 303 304