From 3eb78a1ddb0ac78c4306f4b6d2f81f62d097179a Mon Sep 17 00:00:00 2001 From: "Dobbertin, Niclas" Date: Mon, 14 Oct 2024 23:19:55 +0200 Subject: bugfixes --- modeling/prod_multi.py | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) (limited to 'modeling/prod_multi.py') diff --git a/modeling/prod_multi.py b/modeling/prod_multi.py index e93eda0..69e29b2 100644 --- a/modeling/prod_multi.py +++ b/modeling/prod_multi.py @@ -36,6 +36,7 @@ def multiplication(Model): arg1 =arg1 arg2 =arg2 result =arg2 + ~retrieval> """ ) mul_arg2_1 = Model.productionstring( @@ -58,6 +59,7 @@ def multiplication(Model): arg1 =arg1 arg2 =arg2 result =arg1 + ~retrieval> """ ) mul_arg1_0 = Model.productionstring( @@ -80,6 +82,7 @@ def multiplication(Model): arg1 =arg1 arg2 =arg2 result 0 + ~retrieval> """ ) mul_arg2_0 = Model.productionstring( @@ -102,6 +105,7 @@ def multiplication(Model): arg1 =arg1 arg2 =arg2 result 0 + ~retrieval> """ ) @@ -123,6 +127,7 @@ def multiplication(Model): ==> =g> isa math_goal + op mul_try_retrieve +retrieval> isa math_op op mul @@ -132,12 +137,27 @@ def multiplication(Model): ) prods.append(mul_start) + # mul_start_failure = Model.productionstring( + # name="mul_start_failure", + # string=""" + # =g> + # isa math_goal + # op mul_try_retrieve + # arg1 =arg1 + # arg2 =arg2 + # ?retrieval> + # state error + # ==> + # isa math_goal + # op mul_step + # """ + mul_start_success = Model.productionstring( name="mul_start_success", string=""" =g> isa math_goal - op mul + op mul_try_retrieve arg1 =arg1 arg2 =arg2 =retrieval> @@ -166,7 +186,7 @@ def multiplication(Model): string=""" =g> isa math_goal - op mul + op mul_try_retrieve arg1 ~0 arg1 ~1 arg2 ~0 @@ -182,6 +202,7 @@ def multiplication(Model): ==> =g> isa math_goal + op mul mul_counter 1 result =arg +retrieval> -- cgit v1.2.3