aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Tools/CodeGen/KrancThorn.m13
1 files changed, 11 insertions, 2 deletions
diff --git a/Tools/CodeGen/KrancThorn.m b/Tools/CodeGen/KrancThorn.m
index 4fde955..97cfc1f 100644
--- a/Tools/CodeGen/KrancThorn.m
+++ b/Tools/CodeGen/KrancThorn.m
@@ -55,6 +55,16 @@ DefFn[
Append[#, GridType -> "array"],
#] &, groups]];
+Options[ODEProcessCode] = ThornOptions;
+
+DefFn[
+ ODEProcessCode[cIn_Code, opts:OptionsPattern[]] :=
+ Module[
+ {c = cIn},
+ c = SetObjectField[c, "Groups", processODEGroups[GetObjectField[c, "ODEGroups"],
+ GetObjectField[c, "Groups"]]];
+ c]];
+
DefFn[
coordinatesProcessCode[cIn_Code, opts___] :=
Module[
@@ -224,8 +234,7 @@ CreateKrancThorn[groupsOrig_, parentDirectory_, thornName_, opts:OptionsPattern[
ODEs
------------------------------------------------------------------------ *)
- c = SetObjectField[c, "Groups", processODEGroups[GetObjectField[c, "ODEGroups"],
- GetObjectField[c, "Groups"]]];
+ c = ODEProcessCode[c, opts];
c = SetObjectField[
c, "DeclaredGroups",