Changes between Version 9 and Version 10 of u/NewUsers
- Timestamp:
- 08/10/11 15:00:46 (13 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
u/NewUsers
v9 v10 18 18 refineVariableFactor = 1.d-21,0d0,0d0,0d0,0d0,0d0,0d0,0d0,0d0,0d0,0d0,0d0,0d0 19 19 20 The input here controls the variable to which refinement is triggered. By setting a slot = 0 means that refinement will not be triggered for this variable. The smaller the number, the less the refinement. The max value for input to this array is 1, and if this line is not included in your physics.data, all the vector components will be initialized to 1. 20 The input here controls the variable to which refinement is triggered. By setting a slot = 0 means that refinement will not be triggered for this variable. The smaller the number, the less the refinement. The max value for input to this array is 1, and if this line is not included in your physics.data, all the vector components will be initialized to 1. That is, refinement will occur for gradients in any of the flow variables, and hence, you can focus refinement to certain variables by setting others to zero. 21 21 22 refineVariableFactor is defined in module_control.f90, in the subroutine !SetErrFlag. 22 This control refineVariable works with other controls in physics.data for controlling AMR: 1. qTolerance and 2. fillingRatios. Essentially, qTolerance defines how sensitive the code is to gradients, whereas filling ratios tell the code the degree to which new grids should contain areas of refinement. Small values of qtolerance lead to increased refinement and small values for fill ratios leads to smaller regions within sub grids that are to be refined. The input to each of these arrays DOES NOT represent the flow variables. Instead they are linked to the different levels - 0, 1, 2,.., n. It is important to learn how each of these variables work together. 23 24 For instance, refineVariableFactor is called in module_control.f90, in the subroutine !SetErrFlag, which cycles over the cells and looks for gradients in each of the flow variables. If the gradient exceeds some threshold, refinement is triggered. However, there is a section of the module which takes qTolerance/refineVariable. If, these two values are equal -- there will be no change to the refinement criterion. Note, too, that refineVariable must not equal zero, else there will be a divide by zero. So you can take refineVariable close to zero, just never equal to zero. 23 25 24 26 Additionally, one can modify the !SetErrFlags subroutine in problem.f90 to indicate precise ''regions'' of refinement.