Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

possible bug with recent contextFraction.pl changes #1166

Open
Alex-Jordan opened this issue Dec 19, 2024 · 2 comments
Open

possible bug with recent contextFraction.pl changes #1166

Alex-Jordan opened this issue Dec 19, 2024 · 2 comments

Comments

@Alex-Jordan
Copy link
Contributor

The problem below will render on 2.19, but not on develop. On develop there is an error about not finding enough test points.

I suspect it has to do with the changes to contextFraction.pl but I haven't been able to track it down.

DOCUMENT();

loadMacros(
  "PGstandard.pl",
  "MathObjects.pl",
  "PGML.pl",
  "contextFraction.pl",
  "parserAssignment.pl",
  "bizarroArithmetic.pl",
);

Context("Fraction")->variables->add(y => 'Real');
parser::Assignment->Allow;
Context()->operators->set(
  '*' => {class => 'bizarro::BOP::multiply', isCommand => 1},
  '/' => {class => 'bizarro::BOP::divide', isCommand => 1},
);
$f = Formula("y =  2x + 1")->reduce;

ENDDOCUMENT();
@Alex-Jordan
Copy link
Contributor Author

Note, this is an MWE. There is an exercise that this came from with much more going on.

@dpvc
Copy link
Member

dpvc commented Dec 21, 2024

This issue is due to mishandling the implied multiplication in the new fraction context. I've made a PR (#1167) to resolve the issue.

drgrice1 added a commit that referenced this issue Jan 7, 2025
Fix problem with implied multiplication in fraction context, and some typos. (#1166)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants