Log of /trunk/pg/macros/contextLimitedPolynomial.pl
Parent Directory
Revision
4298 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Jul 26 02:54:01 2006 UTC (6 years, 9 months ago) by
dpvc
File length: 10993 byte(s)
Diff to
previous 4121
Extended this context to handle multivariable polynomials. So you can
use things like
loadMacros("contextLimitedPolynomial.pl");
Context("LimitedPolynomial")->variables->are(x => 'Real', y => 'Real');
Context()->flags->set(singlePowers=>1);
$f = Formula("1 + x + y + 2xy + x^2 + y^2");
Revision
4121 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Jun 5 20:43:22 2006 UTC (6 years, 11 months ago) by
dpvc
File length: 8803 byte(s)
Diff to
previous 3383
Fixed a problem where things like x+4x would be accepted even in
single-power mode (the initial x was not being identified as a single
power of x correctly).
Revision
3371 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Jul 12 22:39:56 2005 UTC (7 years, 10 months ago) by
dpvc
File length: 8751 byte(s)
Diff to
previous 3294
Make error messages potentially localizable (by making them use
sprintf-style strings rather than variable subtitution).
Revision
3294 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Added
Wed Jun 15 23:55:17 2005 UTC (7 years, 11 months ago) by
dpvc
File length: 8747 byte(s)
Implements a Parser context in which only polynomials (of a single
variable) can be entered. Only sums of multiples of powers of the
variable are allowed to be entered (though the coefficients can
contain mathematical operations). An optional flag lets you specify
that only one term of each degree is allowed, so the student would
have to combine 1+x+x+x^2 to get 1+2x+x^2 in that case.
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
enter a numeric revision.