|
32 | 32 | as gnitstam) |
33 | 33 |
|
34 | 34 | from pytential.symbolic.primitives import (NodeCoordinateComponent, |
35 | | - hashable_kernel_args, IntG, as_dofdesc, TAG_WITH_DEFAULT_SOURCE) |
| 35 | + hashable_kernel_args, IntG, TAG_WITH_DEFAULT_SOURCE) |
36 | 36 | from pytential.symbolic.mappers import IdentityMapper |
37 | 37 | from pytential.utils import chop, lu_with_post_division_callback |
38 | 38 | import pytential |
@@ -103,7 +103,7 @@ def map_int_g(self, expr): |
103 | 103 | new_int_gs = convert_target_transformation_to_source(expr) |
104 | 104 | # Convert IntGs with different kernels to expressions containing |
105 | 105 | # IntGs with base_kernel or its derivatives |
106 | | - return sum(convert_int_g_to_base(new_int_g, |
| 106 | + return sum(rewrite_int_g_using_base_kernel(new_int_g, |
107 | 107 | self.base_kernel) for new_int_g in new_int_gs) |
108 | 108 |
|
109 | 109 |
|
@@ -273,22 +273,22 @@ def _multiply_int_g(int_g: IntG, expr_multiplier: sym.Basic, |
273 | 273 | return result |
274 | 274 |
|
275 | 275 |
|
276 | | -def convert_int_g_to_base(int_g: IntG, base_kernel: ExpressionKernel) \ |
| 276 | +def rewrite_int_g_using_base_kernel(int_g: IntG, base_kernel: ExpressionKernel) \ |
277 | 277 | -> ExpressionT: |
278 | | - """Converts an *IntG* to an expression with *IntG*s having the |
| 278 | + """Rewrite an *IntG* to an expression with *IntG*s having the |
279 | 279 | base kernel *base_kernel*. |
280 | 280 | """ |
281 | 281 | result = 0 |
282 | 282 | for knl, density in zip(int_g.source_kernels, int_g.densities): |
283 | | - result += _convert_int_g_to_base( |
| 283 | + result += _rewrite_int_g_using_base_kernel( |
284 | 284 | int_g.copy(source_kernels=(knl,), densities=(density,)), |
285 | 285 | base_kernel) |
286 | 286 | return result |
287 | 287 |
|
288 | 288 |
|
289 | | -def _convert_int_g_to_base(int_g: IntG, base_kernel: ExpressionKernel) \ |
| 289 | +def _rewrite_int_g_using_base_kernel(int_g: IntG, base_kernel: ExpressionKernel) \ |
290 | 290 | -> ExpressionT: |
291 | | - """Converts an *IntG* with only one source kernel to an expression with *IntG*s |
| 291 | + """Rewrites an *IntG* with only one source kernel to an expression with *IntG*s |
292 | 292 | having the base kernel *base_kernel*. |
293 | 293 | """ |
294 | 294 | target_kernel = int_g.target_kernel.replace_base_kernel(base_kernel) |
|
0 commit comments