Re: Inline math: one ERT compiles, the other doesn't

2024-03-15 Thread Paul Rubin




On 3/15/24 16:14, Rich Shepard wrote:

On Fri, 15 Mar 2024, Rich Shepard wrote:


Apparently so. Careful re-entering the ERT allowed the doc to compile.


I was wrong. I cannot get an simple equation to compile via the menus or
ERT.

I copied the real doc.lyx to mwe.lyx and deleted everything above and 
below
the paragraph with the equation. That non-printable character shows up 
even

with a minimal entry in the ERT, regardless of whether the backslash is
entered.

I'm totally lost and need advice on what might cause this issue.

mwe.lyx attached.

Rich

In your latest MWE, the backslash before x causes an unrelated 
compilation error, because \x is not a known function.


As for the mystery non-printing character between the ERT box and the 
following comma, I cannot reproduce that. When you insert the ERT box, 
do you type ctrl-L? Assuming so, after filling in the equation in the 
box do you just cursor out of the box and type the comma?


Paul

--
lyx-users mailing list
lyx-users@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-users


Re: Inline math: one ERT compiles, the other doesn't

2024-03-15 Thread José Matos
On Fri, 2024-03-15 at 13:14 -0700, Rich Shepard wrote:
> I was wrong. I cannot get an simple equation to compile via the menus
> or
> ERT.
> 
> I copied the real doc.lyx to mwe.lyx and deleted everything above and
> below
> the paragraph with the equation. That non-printable character shows
> up even
> with a minimal entry in the ERT, regardless of whether the backslash
> is
> entered.
> 
> I'm totally lost and need advice on what might cause this issue.
> 
> mwe.lyx attached.
> 
> Rich

The unprintable character is FFFC. You can see it opening the lyx file
using gvim (for example).

That character is placed after the math inset and before the next
comma.

-- 
José Abílio
-- 
lyx-users mailing list
lyx-users@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-users


Re: Inline math: one ERT compiles, the other doesn't

2024-03-15 Thread Rich Shepard

On Fri, 15 Mar 2024, Rich Shepard wrote:


Apparently so. Careful re-entering the ERT allowed the doc to compile.


I was wrong. I cannot get an simple equation to compile via the menus or
ERT.

I copied the real doc.lyx to mwe.lyx and deleted everything above and below
the paragraph with the equation. That non-printable character shows up even
with a minimal entry in the ERT, regardless of whether the backslash is
entered.

I'm totally lost and need advice on what might cause this issue.

mwe.lyx attached.

Rich#LyX 2.3 created this file. For more info see http://www.lyx.org/
\lyxformat 544
\begin_document
\begin_header
\save_transient_properties true
\origin unavailable
\textclass scrreprt
\begin_preamble
\date{}
\renewcommand\bibname{References}
\usepackage{mathpazo,amssymb}
\usepackage{graphicx,relsize}
\usepackage{scrlayer-scrpage}
\usepackage{xcolor,colortbl}
\usepackage{chngcntr}
\usepackage{xurl}
\counterwithout{figure}{section}
\definecolor{lightgray}{gray}{0.8}
\pagestyle{scrheadings}
\lehead{CERCLA Data Analysis}
\rohead{CERCLA Data Analysis}
\refoot{Applied Ecosystem Services, LLC}
\lofoot{Applied Ecosystem Services, LLC}
\end_preamble
\use_default_options true
\maintain_unincluded_children false
\language english
\language_package default
\inputencoding utf8
\fontencoding global
\font_roman "palatino" "default"
\font_sans "cmss" "default"
\font_typewriter "cmtt" "default"
\font_math "auto" "auto"
\font_default_family default
\use_non_tex_fonts false
\font_sc false
\font_osf false
\font_sf_scale 100 100
\font_tt_scale 100 100
\use_microtype false
\use_dash_ligatures false
\graphics default
\default_output_format pdf2
\output_sync 0
\bibtex_command biber
\index_command default
\paperfontsize 11
\spacing single
\use_hyperref false
\papersize executivepaper
\use_geometry true
\use_package amsmath 1
\use_package amssymb 1
\use_package cancel 1
\use_package esint 0
\use_package mathdots 1
\use_package mathtools 1
\use_package mhchem 1
\use_package stackrel 1
\use_package stmaryrd 1
\use_package undertilde 1
\cite_engine biblatex-natbib
\cite_engine_type authoryear
\biblio_style plain
\biblatex_bibstyle authoryear
\biblatex_citestyle authoryear
\use_bibtopic false
\use_indices false
\paperorientation portrait
\suppress_date true
\justification true
\use_refstyle 0
\use_minted 0
\index Index
\shortcut idx
\color #008000
\end_index
\paperwidth 6.5in
\paperheight 9.5in
\leftmargin 0.75in
\topmargin 0.5in
\rightmargin 0.5in
\bottommargin 1in
\secnumdepth 5
\tocdepth 5
\paragraph_separation indent
\paragraph_indentation default
\is_math_indent 0
\math_numbering_side default
\quotes_style english
\dynamic_quotes 0
\papercolumns 1
\papersides 2
\paperpagestyle plain
\tracking_changes false
\output_changes false
\html_math_output 0
\html_css_as_file 0
\html_be_strict false
\end_header

\begin_body

\begin_layout Standard
The arithmetic mean (or simply mean or average) of a list of numbers, is
 the sum of all of the numbers divided by the number of numbers.
 Similarly, the mean of a sample, 
\begin_inset ERT
status open

\begin_layout Plain Layout

$
\backslash
x_1,$
\end_layout

\end_inset

, usually denoted by 
\begin_inset Formula $\bar{x}$
\end_inset

, is the sum of the sampled values divided by the number of items in the
 sample.
\end_layout

\end_body
\end_document
-- 
lyx-users mailing list
lyx-users@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-users


Re: Inline math: one ERT compiles, the other doesn't (fwd)

2024-03-15 Thread Rich Shepard

On Fri, 15 Mar 2024, Rich Shepard wrote:


I'll see with the display version if it's my fingers mis-typing a
backslash that creates the unprintable character.


Apparently so. Careful re-entering the ERT allowed the doc to compile.

Thanks again,

Rich
--
lyx-users mailing list
lyx-users@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-users


Re: Inline math: one ERT compiles, the other doesn't (fwd)

2024-03-15 Thread Rich Shepard

On Fri, 15 Mar 2024, Paul Rubin wrote:

There's nothing inherent in the content causing this. I opened your mwe.lyx 
file in LyX and, after confirming the error, deleted the second ERT box and 
trailing comma, confirmed what was left compiled without error, then typed 
the ERT box and content (and trailing comma) back in. The document compiled 
without problem.


Paul,

Thanks for confirming.

So the question is, how did you create the second part of the example file? 
Most likely something you did inadvertently inserted the problem character.


In the actual document I had originally entered the inline equation using
Insert -> Math -> Inline. This morning I deleted that yellow box and used
ERT to enter the string. Error committed.

Now, in the actual document I had to re-enter the ERT several times to get
it to compile. It may be that when entering the ERT content I tended to type
], backspace to delete, then type \. Perhaps correcting the typo was the
cause.

I'll see with the display version if it's my fingers mis-typing a backslash
that creates the unprintable character.

Carpe weekend,

Rich

--
lyx-users mailing list
lyx-users@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-users


Re: Inline math: one ERT compiles, the other doesn't (fwd)

2024-03-15 Thread Paul Rubin



On 3/15/24 10:59, Rich Shepard wrote:

On Fri, 15 Mar 2024, Rich Shepard wrote:

What's the difference causing this discrepancy? How do I write the 
second

line so it builds without complaint?


Looking at the mwe.lyx file in emacs I see that control character on line
137. It's not at line 118 which is the same position for the first line.

Why?

Rich
There's nothing inherent in the content causing this. I opened your 
mwe.lyx file in LyX and, after confirming the error, deleted the second 
ERT box and trailing comma, confirmed what was left compiled without 
error, then typed the ERT box and content (and trailing comma) back in. 
The document compiled without problem.


So the question is, how did you create the second part of the example 
file? Most likely something you did inadvertently inserted the problem 
character.


Paul

--
lyx-users mailing list
lyx-users@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-users


Re: Inline math: one ERT compiles, the other doesn't (fwd)

2024-03-15 Thread Rich Shepard

On Fri, 15 Mar 2024, Rich Shepard wrote:


What's the difference causing this discrepancy? How do I write the second
line so it builds without complaint?


Looking at the mwe.lyx file in emacs I see that control character on line
137. It's not at line 118 which is the same position for the first line.

Why?

Rich
--
lyx-users mailing list
lyx-users@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-users


Inline math: one ERT compiles, the other doesn't (fwd)

2024-03-15 Thread Rich Shepard

I've read the math section in the User Guide and am working my way through
the separate math manual.

Attached is a MWE. The first line (if the only one in the document) compiles
using pdflatex. The second line causes a build error because a code point
(0xfffc) is detected. The font encoding is unicode utf8.

What's the difference causing this discrepancy? How do I write the second
line so it builds without complaint?

TIA,

Rich#LyX 2.3 created this file. For more info see http://www.lyx.org/
\lyxformat 544
\begin_document
\begin_header
\save_transient_properties true
\origin unavailable
\textclass scrreprt
\begin_preamble
\date{}
%\usepackage{ftnxtra}
\usepackage{mathpazo,amssymb}
\usepackage{graphicx,relsize}
\usepackage{scrlayer-scrpage}
\usepackage{xcolor,colortbl}
\usepackage{chngcntr,xurl}
\counterwithout{figure}{section}
\definecolor{lightgray}{gray}{0.8}
\pagestyle{scrheadings}
\lehead{Biological Evaluation}
\rohead{Biological Evaluation}
\refoot{Applied Ecosystem Services, LLC}
\lofoot{Applied Ecosystem Services, LLC}
%\automark*{sections}
\end_preamble
\use_default_options true
\maintain_unincluded_children false
\language english
\language_package default
\inputencoding auto
\fontencoding global
\font_roman "palatino" "default"
\font_sans "avant" "default"
\font_typewriter "libertine-mono" "default"
\font_math "auto" "auto"
\font_default_family default
\use_non_tex_fonts false
\font_sc false
\font_osf false
\font_sf_scale 100 100
\font_tt_scale 100 100
\use_microtype false
\use_dash_ligatures true
\graphics default
\default_output_format default
\output_sync 0
\bibtex_command biber
\index_command default
\paperfontsize 11
\spacing single
\use_hyperref false
\papersize letterpaper
\use_geometry true
\use_package amsmath 1
\use_package amssymb 1
\use_package cancel 1
\use_package esint 0
\use_package mathdots 0
\use_package mathtools 1
\use_package mhchem 1
\use_package stackrel 1
\use_package stmaryrd 1
\use_package undertilde 1
\cite_engine biblatex-natbib
\cite_engine_type authoryear
\biblatex_bibstyle authoryear
\biblatex_citestyle authoryear
\use_bibtopic false
\use_indices false
\paperorientation portrait
\suppress_date false
\justification true
\use_refstyle 0
\use_minted 0
\index Index
\shortcut idx
\color #008000
\end_index
\leftmargin 0.75in
\topmargin 0.5in
\rightmargin 0.5in
\bottommargin 0.5in
\secnumdepth 2
\tocdepth 2
\paragraph_separation indent
\paragraph_indentation default
\is_math_indent 0
\math_numbering_side default
\quotes_style english
\dynamic_quotes 0
\papercolumns 1
\papersides 1
\paperpagestyle plain
\tracking_changes false
\output_changes false
\html_math_output 0
\html_css_as_file 0
\html_be_strict false
\end_header

\begin_body

\begin_layout Standard
For example, 
\begin_inset ERT
status open

\begin_layout Plain Layout

$
\backslash
bar x = x_1, x_2, 
\backslash
dots, x_n$
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Similarly, the mean of a sample 
\begin_inset ERT
status open

\begin_layout Plain Layout

$
\backslash
bar x = x_1, x_2, 
\backslash
dots, x_n$
\end_layout

\end_inset

,
\end_layout

\end_body
\end_document
#LyX 2.3 created this file. For more info see http://www.lyx.org/
\lyxformat 544
\begin_document
\begin_header
\save_transient_properties true
\origin unavailable
\textclass scrreprt
\begin_preamble
\date{}
%\usepackage{ftnxtra}
\usepackage{mathpazo,amssymb}
\usepackage{graphicx,relsize}
\usepackage{scrlayer-scrpage}
\usepackage{xcolor,colortbl}
\usepackage{chngcntr,xurl}
\counterwithout{figure}{section}
\definecolor{lightgray}{gray}{0.8}
\pagestyle{scrheadings}
\lehead{Biological Evaluation}
\rohead{Biological Evaluation}
\refoot{Applied Ecosystem Services, LLC}
\lofoot{Applied Ecosystem Services, LLC}
%\automark*{sections}
\end_preamble
\use_default_options true
\maintain_unincluded_children false
\language english
\language_package default
\inputencoding utf8
\fontencoding global
\font_roman "palatino" "default"
\font_sans "avant" "default"
\font_typewriter "libertine-mono" "default"
\font_math "auto" "auto"
\font_default_family default
\use_non_tex_fonts false
\font_sc false
\font_osf false
\font_sf_scale 100 100
\font_tt_scale 100 100
\use_microtype false
\use_dash_ligatures true
\graphics default
\default_output_format default
\output_sync 0
\bibtex_command biber
\index_command default
\paperfontsize 11
\spacing single
\use_hyperref false
\papersize letterpaper
\use_geometry true
\use_package amsmath 1
\use_package amssymb 1
\use_package cancel 1
\use_package esint 0
\use_package mathdots 0
\use_package mathtools 1
\use_package mhchem 1
\use_package stackrel 1
\use_package stmaryrd 1
\use_package undertilde 1
\cite_engine biblatex-natbib
\cite_engine_type authoryear
\biblatex_bibstyle authoryear
\biblatex_citestyle authoryear
\use_bibtopic false
\use_indices false
\paperorientation portrait
\suppress_date false
\justification true
\use_refstyle 0
\use_minted 0
\index Index
\shortcut idx
\color #008000
\end_index