@@ -82,7 +82,9 @@ def xrange(self, location):
82
82
"node" : self .__class__ .get_node_loc ,
83
83
}
84
84
85
- return range_dict [location ](self .xmin , self .xmax , self .dx , self .nxb )
85
+ return range_dict [location ](
86
+ self .xmin , self .xmax , self .dx , self .nxb , self .xguard
87
+ )
86
88
87
89
def yrange (self , location ):
88
90
"""
@@ -93,7 +95,9 @@ def yrange(self, location):
93
95
"node" : self .__class__ .get_node_loc ,
94
96
}
95
97
96
- return range_dict [location ](self .ymin , self .ymax , self .dy , self .nyb )
98
+ return range_dict [location ](
99
+ self .ymin , self .ymax , self .dy , self .nyb , self .yguard
100
+ )
97
101
98
102
def zrange (self , location ):
99
103
"""
@@ -104,19 +108,29 @@ def zrange(self, location):
104
108
"node" : self .__class__ .get_node_loc ,
105
109
}
106
110
107
- return range_dict [location ](self .zmin , self .zmax , self .dz , self .nzb )
111
+ return range_dict [location ](
112
+ self .zmin , self .zmax , self .dz , self .nzb , self .zguard
113
+ )
108
114
109
115
@staticmethod
110
- def get_center_loc (min_val , max_val , delta , num_points ):
116
+ def get_center_loc (min_val , max_val , delta , num_points , num_guards ):
111
117
"""Private method for center location"""
112
- return numpy .linspace (min_val + delta / 2 , max_val - delta / 2 , num_points )
118
+ return numpy .linspace (
119
+ min_val + delta / 2 - num_guards * delta ,
120
+ max_val - delta / 2 + num_guards * delta ,
121
+ num_points + 2 * num_guards ,
122
+ )
113
123
114
124
@staticmethod
115
125
def get_node_loc (
116
- min_val , max_val , delta , num_points
126
+ min_val , max_val , delta , num_points , num_guards
117
127
): # pylint: disable=unused-argument
118
128
"""Private method for face location"""
119
- return numpy .linspace (min_val , max_val , num_points )
129
+ return numpy .linspace (
130
+ min_val - num_guards * delta ,
131
+ max_val + num_guards * delta ,
132
+ num_points + 2 * num_guards ,
133
+ )
120
134
121
135
def _set_attributes (self , attributes ):
122
136
"""
0 commit comments