Continuing an <ol>

25 views
Skip to first unread message

Jason Siefken

unread,
May 1, 2024, 2:07:59 PM5/1/24
to prete...@googlegroups.com
I have a case where I have an <ol> that is interrupted by a paragraph or two. Then the <ol> continues. Of course, I would want the number of the continued <ol> to pick up where the last one left off. I have not found a way to do this in PreTeXt.

So, barring that I haven't missed something, I propose adding a `start=..` attribute that accepts a number which is the start index of an <ol>. The name `start` was chosen to coincide with the HTML <ol>.

Consequences:
a `start` tag would be a list with `marker="0"` could be alternatively obtained by doing `marker="1" start="0"` (or you could make that be an error...). Important behavior, though, would be for `marker="0" start="4"` and `marker="1" start="4"` to both have the label "4." show up in the rendered document.

Steven Clontz

unread,
May 1, 2024, 4:34:35 PM5/1/24
to PreTeXt development
What about:

<ol xml:id="foo"><li/><li/></ol> <!-- 1, 2 -->
<ol continues="foo"><li/><li/></ol> <!-- 3, 4 -->

Mitch Keller

unread,
May 1, 2024, 4:38:07 PM5/1/24
to prete...@googlegroups.com
I like this suggestion because it connects the meaning (and doesn’t require you to update the @start if you change the number of items in the first portion of the ol). 

--
You received this message because you are subscribed to the Google Groups "PreTeXt development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pretext-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pretext-dev/16c517eb-a335-4e8c-a020-1f064213b253n%40googlegroups.com.


Steven Clontz

unread,
May 1, 2024, 4:51:49 PM5/1/24
to PreTeXt development
There could be a use for @start still (e.g. 0-indexing a list). But I believe that in general a @continue would be slicker for the (perhaps?) most common use-case of continuing a previous list.

Rob Beezer

unread,
May 2, 2024, 10:59:01 AM5/2/24
to prete...@googlegroups.com
Dear Jason,

> I have an <ol> that is interrupted by a paragraph or two.

That does not fit my conception of a component of a structured scholarly document.

Either it is two lists, or the intermediate paragraphs need to go within some
adjacent/nearby items, or the intermediate paragraphs should go before or after
the list.

A workaround would be to use the "paragraphs" element for the list items and
hard-code a number as part of their title. Then the intermediate paragraphs
could be bare, or also in a "paragraphs" with a title helping to separate them
and explain their purpose relative to the numbered items.

We've made Chapter 0 possible. I don't plan to support Item 0.

I recall discussing this long ago, but can't remember any particulars or who was
involved, and searching is not getting me any further.

Rob
> --
> You received this message because you are subscribed to the Google Groups
> "PreTeXt development" group.
> To unsubscribe from this group and stop receiving emails from it, send an email
> to pretext-dev...@googlegroups.com
> <mailto:pretext-dev...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pretext-dev/21b1812b-c37c-4f42-9a70-fe560b39fd57%40gmail.com <https://groups.google.com/d/msgid/pretext-dev/21b1812b-c37c-4f42-9a70-fe560b39fd57%40gmail.com?utm_medium=email&utm_source=footer>.

Jason Siefken

unread,
May 2, 2024, 11:38:34 AM5/2/24
to prete...@googlegroups.com
> That does not fit my conception of a component of a structured scholarly document.

Can you explain more? Why does it violate your conception?


We've made Chapter 0 possible.  I don't plan to support Item 0.

I think you already do...with `marker="0"`.

Here is an example of what I am trying to accomplish. The paragraph between items 5 and 6 is commentary about items 1-5. I think the document would become harder to read if that paragraph were moved to the end and one tried to explain "A matrix where steps 1-5 have been applied but before step 6 was applied is ...". In particular, from a pedagogical point of view, you shouldn't ask someone to understand a whole algorithm and then come back and ask them to chop their knowledge in pieces and ask them to understand and apply new labels to parts of an algorithm...





Jeremy Sylvestre

unread,
May 2, 2024, 11:46:08 AM5/2/24
to prete...@googlegroups.com
You already include the terminology pivot inside your algorithm, why not include the REF/RREF terminology inside as well?

5. Now, M has the form
M = [ matrix ]
called *pre-reduced row echelon form*. In this form, M' is a submatrix of M, and the algorithm should next be applied to M'.

6. Use row operations of the form [math] to zero above each pivot. When this is complete, the resulting matrix is called RREF.

Pedagogically, I think REF is dumb. Just tell them to zero *both* above and below each pivot as they go, to end up at RREF at the end. Yes, the calculations are a little more tedious this way, but it's 2024 --- no one is reducing matrices with pencil and paper any more.

Cheers,
Jeremy S



6. 

--
You received this message because you are subscribed to the Google Groups "PreTeXt development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pretext-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pretext-dev/9d7beed8-4f31-4c06-831e-266c8d0bb993%40gmail.com.

Jeremy Sylvestre

unread,
May 2, 2024, 11:46:54 AM5/2/24
to prete...@googlegroups.com
Whoops, I guess the REF terminology description should go after the "applied to M'" part in step 5. But you get the idea.

Jason Siefken

unread,
May 2, 2024, 11:53:19 AM5/2/24
to prete...@googlegroups.com
Dumbness of row reduction aside, I agree that the definition of a pivot should be in its own paragraph, interrupting the list, to make it consistent with pre-rref.

Jeremy Sylvestre

unread,
May 2, 2024, 11:58:25 AM5/2/24
to prete...@googlegroups.com
Might be better to tell them what REF/RREF "looks like" before even starting the description of the algorithm, so they know what the algorithm is aiming for. Defining those forms as "it's what you get after doing these steps" doesn't help them recognize it if someone else has done the steps.

Rob Beezer

unread,
May 2, 2024, 12:14:58 PM5/2/24
to prete...@googlegroups.com


On 5/2/24 08:38, Jason Siefken wrote:
> > That does not fit my conception of a component of a structured scholarly
> document.
>
> Can you explain more? Why does it violate your conception?

A list is a list. It does not get interrupted. I guess that is opinion. But
all of PreTeXt is an expression of an opinion. Some conventional. Some shared.
Some gleaned from extensive thoughtful discussions here. Some perhaps a bit
idiosyncratic.

>> We've made Chapter 0 possible.  I don't plan to support Item 0.
>
> I think you already do...with `marker="0"`.

Damn. ;-) I can't remember everything! Which is why we have code on GitHub. ;-)

> Here is an example of what I am trying to accomplish. The paragraph between
> items 5 and 6 is commentary about items 1-5. I think the document would become
> harder to read if that paragraph were moved to the end and one tried to explain
> "A matrix where steps 1-5 have been applied but before step 6 was applied is
> ...". In particular, from a pedagogical point of view, you shouldn't ask someone
> to understand a whole algorithm and then come back and ask them to chop their
> knowledge in pieces and ask them to understand and apply new labels to parts of
> an algorithm...


We have an "algorithm" block. You are not using that, it appears. Maybe it
needs work?

Put "The resulting matrix is in pre-reduced row echelon form." at the end of
Step 5, where it fits naturally. And say "Apply Steps 1 to 5 to M', not "the
algorithm".

Now Step 6 becomes "To put the matrix into reduced row echelon form use row
operations of the form ... on pre-reduced row echelon form to zero above each
pivot."

Which of the two matrices you have defined is this algorithm suppose to be for?
Your title doesn't help me with that.

OK, as I write I think you have two algorithms. Steps 1-5 is a recursive one.
Then the second algorithm is "Do Algorithm 6.3.89 (the first algorithm) to form
.... Do Step 6 (which is now named Step 2.)"

You can put as much stuff as you like between the two "algorithm".

Rob

David W. Farmer

unread,
May 2, 2024, 12:34:35 PM5/2/24
to 'Rob Beezer' via PreTeXt development

There may be a gray line between what is a list and what isn't,
but it seems pretty clear to me that the steps in a process/algorithm
are not a list in the ol/ul PreTeXt sense.

By now I think we all accept that the exercises at the end of a section
are not an ol list. It makes no sense to put a hint/answer/solution into
an element on an ol/ul list, for example.

You can fake a glossary with a ol/ul list (by putting the term
as the title of the list element), but a glossary is not a list in the
ol/ul PreTeXt sense. Again, I think we have become comfortable with that.

It may be that PreTeXt needs to provide better support (or better
documentation) for algorithms/procedures, but that is not an argument
for adding features to ol to enable it to do things beyond its
intended scope.

I'm tempted to suggest some general principles which indicate whether
a sequence of items should be an ol/ul, but maybe that would
unnecessarily prolong this discussion.

Regards,

David

Rob Beezer

unread,
May 2, 2024, 12:51:56 PM5/2/24
to prete...@googlegroups.com
On 5/2/24 09:34, David W. Farmer wrote:
> I'm tempted to suggest some general principles which indicate whether
> a sequence of items should be an ol/ul, but maybe that would
> unnecessarily prolong this discussion.

I'll take the bait.

1. A "ul" is a list where order doesn't matter. Duh. But the best example is
the ingredients for a recipe.

2. An "ol" has items whose order is important. Duh. But not so obvious, it
seems, to people who like to use a numbered list to organize their thoughts.
Best example is the steps (algorithm?) for a recipe.

3. This item is here in a desperate attempt to justify this being an ordered
list, since 1 and 2 are interchangeable.

I too often feel a list is a just a sloppy way to convey some structure, which
might be the converse of David's thoughtful reply. In my laTeX days, I used
them way too often.

Related: We expect an "algorirthm" to contain an "ol". But when created that
way, we can handle it differently than a bare "ol" in some random "p". But I
don't think we are doing that now. Or, we could have new markup, like a "step"
which extends existing code for "li".

Rob

Steven Clontz

unread,
May 2, 2024, 12:55:43 PM5/2/24
to PreTeXt development
My opinions here are not strong, but is it valid to use "ol" for the case that you want unique identifiers for each item in a list?

1. Here's an item.
2. Here's anohter.
3. And here is one more.

Oops, I made a typo in item #2!

David W. Farmer

unread,
May 2, 2024, 1:05:16 PM5/2/24
to PreTeXt development

Being able to refer to an item by number is a good reason
to use ol instead of ul.

The principle I have in mind is that it is the nature of the
items which tells you whether ol/ul is appropriate. Countries
in Europe, shapes of pasta, red fruit, commonly mis-spelled
words, colors on the rainbow (in the order they appear).
There is no structure to those items.
All of those are appropriate for ol/ul.

An exercise, or a step in an algorithm, or a word and its
definition, are structural components of the document and so
should not be in an ol/ul.
> --
> You received this message because you are subscribed to the Google Groups "PreTeXt development" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to pretext-dev...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/pretext-dev/2164d020-933e-4bfa-98b6-283d9c9aa703n%40googlegroups.com.
>
>

Andrew Scholer

unread,
May 2, 2024, 2:38:32 PM5/2/24
to prete...@googlegroups.com
I'm going to argue both sides...


In the general case, I see valuable uses for starting an ordered list at a non-default initial index. For example: showing part of a much longer list.
Restricting our attention to the bottom half of the NBA Eastern Conference standings, we see:
8) Heat
9) Bulls
...


That said, I do like the notion of not expanding ol to cover everything that might be numbered. In HTML there is a tendency to do that. Semantic meaning is added to those items via classes/ids. (e.g. to identify that this particular li is a step in an algorithm and that li is one of People's 10 sexiest STEM practitioners). But that same approach doesn't feel very pretext. It does feel like the items in the motivating example should be identified as "a step in an algorithm" and not just "an item in a list". Steps in an algorithm feel more meaningful - that should be reflected in things like a direct permalink for each one.


Andrew Scholer (he/him/his)
Computer Science Instructor/Program Chair
Chemeketa Community College


Sean Fitzpatrick

unread,
May 3, 2024, 12:17:43 PM5/3/24
to PreTeXt development
I just ran into an issue where I think interrupting a list is justified, which is a slideshow. 

You could have an ordered list that doesn't fit on one slide, and you'd like to pick up where you left off on the next slide.

Rob Beezer

unread,
May 3, 2024, 12:28:13 PM5/3/24
to prete...@googlegroups.com
Right, but that is different.

1. You are not proposing additional material (paragraphs) between items.

2. Some might say you are packing too much stuff on a slide. ;-)

3. This feels like a limitation of the output format, not a
semantic/content/markup thing.

We have "discretionary" breaks for very long hunks of display mathematics in
print. But that was easy to implement, since it is a supported LaTeX feature.
But I think having one list span several slides might be do-able if the author
prescribes the breaks via attributes on the items.

Rob

On 5/3/24 09:17, Sean Fitzpatrick wrote:
> I just ran into an issue where I think interrupting a list is justified, which
> is a slideshow.
>
> You could have an ordered list that doesn't fit on one slide, and you'd like to
> pick up where you left off on the next slide.
>
> On Thu, May 2, 2024, 12:38 p.m. Andrew Scholer <andrew....@chemeketa.edu
> <mailto:andrew....@chemeketa.edu>> wrote:
>
> I'm going to argue both sides...
>
>
> In the general case, I see valuable uses for starting an ordered list at a
> non-default initial index. For example: showing part of a much longer list.
> /Restricting our attention to the bottom half of the NBA Eastern Conference
> standings, we see:/
> /8) Heat
> 9) Bulls
> .../
> /
> /
> /
> /
> That said, I do like the notion of not expanding ol to cover everything that
> might be numbered. In HTML there is a tendency to do that. Semantic meaning
> is added to those items via classes/ids. (e.g. to identify that this
> particular li is a step in an algorithm and that li is one of People's 10
> sexiest STEM practitioners). But that same approach doesn't feel very
> pretext. It does feel like the items in the motivating example should be
> identified as "a step in an algorithm" and not just "an item in a list".
> Steps in an algorithm feel more meaningful - that should be reflected in
> things like a direct permalink for each one.
>
>
> Andrew Scholer (he/him/his)
> Computer Science Instructor/Program Chair
> Chemeketa Community College
> 503.589.7649
> computerscience.chemeketa.edu/people/andrew-scholer/
> <http://computerscience.chemeketa.edu/people/andrew-scholer/>
> <mailto:pretext-dev%2Bunsu...@googlegroups.com>.
> > To view this discussion on the web visit
> https://groups.google.com/d/msgid/pretext-dev/2164d020-933e-4bfa-98b6-283d9c9aa703n%40googlegroups.com <https://groups.google.com/d/msgid/pretext-dev/2164d020-933e-4bfa-98b6-283d9c9aa703n%40googlegroups.com>.
> >
> >
>
> --
> You received this message because you are subscribed to the Google
> Groups "PreTeXt development" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to pretext-dev...@googlegroups.com
> <mailto:pretext-dev%2Bunsu...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pretext-dev/3c776465-e2c8-6425-5bf6-22879109ff3%40aimath.org <https://groups.google.com/d/msgid/pretext-dev/3c776465-e2c8-6425-5bf6-22879109ff3%40aimath.org>.
>
> --
> You received this message because you are subscribed to the Google Groups
> "PreTeXt development" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to pretext-dev...@googlegroups.com
> <mailto:pretext-dev...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pretext-dev/CACm44N-EYqq%2BQEDDxcGrkQhi3f6_GvsXmwLV2me1X8cfsqwy_Q%40mail.gmail.com <https://groups.google.com/d/msgid/pretext-dev/CACm44N-EYqq%2BQEDDxcGrkQhi3f6_GvsXmwLV2me1X8cfsqwy_Q%40mail.gmail.com?utm_medium=email&utm_source=footer>.
>
> --
> You received this message because you are subscribed to the Google Groups
> "PreTeXt development" group.
> To unsubscribe from this group and stop receiving emails from it, send an email
> to pretext-dev...@googlegroups.com
> <mailto:pretext-dev...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pretext-dev/CAH%2BNcPZssRhzrGG8Pbs0yNAVYhJE5NwVX45PEMrMQup1A7qboA%40mail.gmail.com <https://groups.google.com/d/msgid/pretext-dev/CAH%2BNcPZssRhzrGG8Pbs0yNAVYhJE5NwVX45PEMrMQup1A7qboA%40mail.gmail.com?utm_medium=email&utm_source=footer>.

Sean Fitzpatrick

unread,
May 3, 2024, 7:35:45 PM5/3/24
to PreTeXt development
I was constrained by needing to fit work done by some others into a working group report ;-)

To unsubscribe from this group and stop receiving emails from it, send an email to pretext-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pretext-dev/MTAwMDAxMy5iZWV6ZXI.1714753691%40quikprotect.
Reply all
Reply to author
Forward
0 new messages