[von_neumann_model] lecture improvements#533
Conversation
- Set the max-height of cells to none - Removed `object` after `class Nuemann` - Adopted `sphinx-proof` enviornments
There was a problem hiding this comment.
Pull Request Overview
This PR improves the von Neumann lecture by modernizing documentation formatting and fixing minor inconsistencies. The changes primarily focus on adopting sphinx-proof environments for better mathematical presentation and updating code cell configurations.
Key changes:
- Adoption of
sphinx-proofenvironments for assumptions, definitions, theorems, and proofs - Removal of
objectinheritance fromclass Neumann(Python 3 style) - Addition of CSS styling to remove cell height restrictions
lectures/von_neumann_model.md
Outdated
| Assumptions: | ||
| - AI: every column of B has a positive entry : {AI} | ||
| - AII: every row of A has a positive entry : {AII} | ||
| Assumptions:// TODO:change {AI} variable into A1? |
There was a problem hiding this comment.
The TODO comment should be removed or properly formatted. If this is a genuine TODO, it should be tracked in an issue rather than left in production code.
| Assumptions:// TODO:change {AI} variable into A1? | |
| Assumptions: |
lectures/von_neumann_model.md
Outdated
| Two key assumptions restrict economy $(A,B)$: | ||
|
|
||
| - **Assumption I:** (every good that is consumed is also produced) | ||
| ````{prf:assumption} every good that is consumed is also produced) |
There was a problem hiding this comment.
There is an extra closing parenthesis in the assumption title. It should be 'every good that is consumed is also produced' without the trailing parenthesis.
| ````{prf:assumption} every good that is consumed is also produced) | |
| ````{prf:assumption} every good that is consumed is also produced |
|
Thanks for the PR @xuanguang-li. I will take a look tomorrow. |
|
@jstac -- @xuanguang-li has asked a really nice style clarification question. In the case where there are two or more conditions are states, should a python variable name always use numbers such as What makes me pause is that in some documents |
That sounds like good reasoning to me @mmcky . |
|
Hi John and @mmcky, Thanks for your feedback. I understand your point that I should keep the variable names consistent with the docstrings. Should I still use If I use
|
|
thanks @xuanguang-li let me think this through, I take your point that we will have mixed systems in the lecture 👍 One option would be to enable roman numeral styles for |
- Kept roman numerals in `class nuemann`. - Deleted `<style>` setting which does not work
|
Thanks for your explanation. I kept the Roman numerals in the code while using the default Regarding the suggestion, "Only part of class Neumann(object): is showing --- show all", I tried adding a |
|
thanks @xuanguang-li we will always keep the css in The
@xuanguang-li can you make a new issue based on this issue for tracking? I would suggest using |
|
Thanks @mmcky. I have created a new issue QuantEcon/quantecon-book-theme#299 describing this problem. |
|
This PR is ready for review. @mmcky @HumphreyYang |
lectures/von_neumann_model.md
Outdated
| output matrices must have only non-negative entries!' | ||
|
|
||
| # (1) Check whether Assumption I is satisfied: | ||
| # (1) Check whether Assumption 1 is satisfied: |
There was a problem hiding this comment.
@xuanguang-li could you revert this to roman numerals? I think we have kept the code the same, so these should also be roman numeral. Is that right? Thanks.
mmcky
left a comment
There was a problem hiding this comment.
thanks @xuanguang-li. Just one minor pickup.
@HumphreyYang I think this is in pretty good shape.
HumphreyYang
left a comment
There was a problem hiding this comment.
Many thanks, @xuanguang-li! Great PR!
Just two very minor comments below.
Another small comment is that I think this lecture is not yet style-sheet compliant, as some paragraphs contain more than one sentence : )
| relationship between technological and valuation characteristics of | ||
| the economy: | ||
|
|
||
| **Definition:** The *technological expansion problem* (TEP) for the economy |
Co-authored-by: Humphrey Yang <39026988+HumphreyYang@users.noreply.github.com>
|
thanks @HumphreyYang. @xuanguang-li it would be great if you could read through https://manual.quantecon.org/styleguide/writing.html and see if you make some improvements re: style guide compatibility. |
|
Thanks for the comments @mmcky @HumphreyYang. I will correct some typos and check the style again with the guidance. |
|
thanks for your work on this @xuanguang-li -- this is getting close. |
|
Hi @mmcky @HumphreyYang, I have divided the paragraphs into one sentence and used bold font to emphasize the definitions. Do you have any suggestions or further improvements I could make? |
mmcky
left a comment
There was a problem hiding this comment.
Thanks @xuanguang-li this looks good to me.
@HumphreyYang when you have time could you do a final parse of the diff.
Merge target date: 26th August 2025.
|
Many thanks @xuanguang-li and @mmcky! These changes are great improvements! I just noticed that we might want to change I have collected them in one push above. Once it builds I will merge if @mmcky agrees |
|
Thanks for your help, @HumphreyYang. I will keep this point in mind next time. |
|
Hi @xuanguang-li, I think from previous conversation, we want |
|
Yes, generally it is. @HumphreyYang But in issue #478, John says he wants to show all the code of
|
Many thanks @xuanguang-li, roger that! |
|
@xuanguang-li as Humphrey suggests, let's show all for now (i.e. remove the collapse tag). I have an issue to look into the old behaviour where we could expand and show-all rather than scroll. |
|
Got it, @mmcky! I'll drop the |
|
Many thanks @xuanguang-li and @mmcky! Merging it now! |



Key changes
objectafterclass Nuemannsphinx-proofenvironmentsQuestion
sphinx-proof, assumptions numbered as "I, II" have been changed to "1, 2". But in the definition ofclass Neumann, some variables are named asAIandAII. Should I change the names of these variables toA1andA2? @mmckyFor example,
linked to #478