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

LINMA2380: Update exercise solutions for 2020--2021 #872

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Peiffap
Copy link
Collaborator

@Peiffap Peiffap commented Feb 2, 2021

No description provided.

@Jimvy
Copy link
Collaborator

Jimvy commented Feb 14, 2021

In the main file, lines 16-18, a command \exo is defined to put stars in the exo title (for the difficulty I guess?).
Notwithstanding the fact that this is ugly, it also causes many "Token not allowed in a PDF string" errors due to the \star in math mode.
You can replace that with

\newcommand{\exo}[1]{\subsection{\texorpdfstring{%
\LARGE\forloop{stars}{0}{\value{stars} < #1}{$\star$}
}{%
\ifnum#1=1 #1 star \else #1 stars \fi%
}}}

to suppress the error.

If you know better LaTeX programming commands, you can use them of course. ^^

Copy link
Collaborator

@Jimvy Jimvy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aside from this, nothing to say. I haven't checked the math so I assume that it is OK ;)

src/q7/matrix-INMA2380/exercises/ch1.tex Show resolved Hide resolved
src/q7/matrix-INMA2380/exercises/ch1.tex Outdated Show resolved Hide resolved
@Jimvy
Copy link
Collaborator

Jimvy commented Feb 14, 2021

En fait, j'ai un autre soucis : chez toi, quand tu compiles via le Makefile, ça compile sans problème les deux documents (version sans et avec sol) ?
Chez moi, la version avec Sol compile, la version sans Sol ne compile pas, avec un message d'erreur sur le comment "Bad space factor (0)". Et je ne comprends absolument pas d'où ça peut sortir...

@Jimvy
Copy link
Collaborator

Jimvy commented Feb 14, 2021

Ok, visiblement ce block comment est assez fragile niveau retours à la ligne etc, et lorsqu'on l'inclut dans l'environnement solution qui est parfois réduit à juste un \expandafter\comment \expandafter\endcomment, ça a vraiment l'air de péter le truc.
Vu que les anciennes réponses sont dans l'historique, ça va si on enlève simplement les blocs de commentaire ? :)

@Peiffap
Copy link
Collaborator Author

Peiffap commented May 7, 2021

I updated the \exo command and removed the comments. Everything compiles on my machine, including from make pdf. I also don't have any errors/warnings other than the perennial "You have requested ..." ones we can't get rid of as far as I know.

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

Successfully merging this pull request may close these issues.

2 participants