[Solved] Closing parenthesis problem

Discuss the formula editor

[Solved] Closing parenthesis problem

Postby r4zoli » Fri Nov 16, 2012 11:12 am

I try to convert a document from docx. to odt with Math objects.
I found one problem which I can't resolve.
Code: Select all   Expand viewCollapse view
\( r + r_+a\)
works correctly, but I needs + indstead a.
If I use
Code: Select all   Expand viewCollapse view
\( r + r_+ \)
the closing parenthesis is after a + sign in lower position, not a correct.

Any suggestion?
Attachments
correct.JPG
correct.JPG (1.25 KiB) Viewed 4889 times
rplus.JPG
rplus.JPG (8.3 KiB) Viewed 4889 times
Last edited by r4zoli on Fri Nov 16, 2012 1:54 pm, edited 1 time in total.
AOO 4.0 and LibO 4 on Win 8
Hungarian forum co-admin
User avatar
r4zoli
Volunteer
 
Posts: 2882
Joined: Mon Nov 19, 2007 8:23 pm
Location: Budapest, Hungary

Re: Closing parenthesis problem

Postby RoryOF » Fri Nov 16, 2012 11:21 am

I've never used Math before, but \( r + r_a \) gives me your correct result. You may need to Escape your + if the + (or -) sign is important. Hope that helps.
Apache OpenOffice 4.1.7 on Xubuntu 18.04.4 (mostly 64 bit version) and very infrequently on Win2K/XP
User avatar
RoryOF
Moderator
 
Posts: 30430
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Closing parenthesis problem

Postby r4zoli » Fri Nov 16, 2012 11:29 am

I'm editing a nonprofit magazine, and get an article with lot of math equations, I can not avoid this +.
AOO 4.0 and LibO 4 on Win 8
Hungarian forum co-admin
User avatar
r4zoli
Volunteer
 
Posts: 2882
Joined: Mon Nov 19, 2007 8:23 pm
Location: Budapest, Hungary

Re: Closing parenthesis problem

Postby floris v » Fri Nov 16, 2012 11:55 am

This bad code seems to work: \( r + r_+ }\), sort of. Definitely a bug.
AOO 4.1.6 op Linux Mint
If your problem has been solved or your question has been answered, please edit the first post in this thread and add [Solved] to the title bar.
Nederlandstalig forum
User avatar
floris v
Moderator
 
Posts: 4192
Joined: Wed Nov 28, 2007 1:21 pm
Location: Netherlands

Re: Closing parenthesis problem

Postby keme » Fri Nov 16, 2012 12:20 pm

This good code works too.
Code: Select all   Expand viewCollapse view
\( r + r_"+"\)

Remember that + is an operator, so it's not really surprising that leaving it in a limbo (with parentheses etc as "halfway operands") yields strange results.

That "good code" is not much help if you still have to edit a large number of formulas manually. Sorry that I can't help more.
Too bad Find/replace does not work in Math, and neither in embedded objects. You may need to delve into the nitty gritty of ODF to devise an automated solution.
Last edited by keme on Fri Nov 16, 2012 12:24 pm, edited 1 time in total.
Apache OO 3.4.1/4.1.2/4.1.3, on Ms Windows 7/10 and Mac OS-X 10.8.5 and 10.11.
LibreOffice 4.3.3.2 on Mepis Antix MX 14
User avatar
keme
Volunteer
 
Posts: 3296
Joined: Wed Nov 28, 2007 10:27 am
Location: Egersund, Norway

Re: Closing parenthesis problem

Postby floris v » Fri Nov 16, 2012 12:22 pm

Of course, so stupid of me not to think of that. :lol:
AOO 4.1.6 op Linux Mint
If your problem has been solved or your question has been answered, please edit the first post in this thread and add [Solved] to the title bar.
Nederlandstalig forum
User avatar
floris v
Moderator
 
Posts: 4192
Joined: Wed Nov 28, 2007 1:21 pm
Location: Netherlands

Re: Closing parenthesis problem

Postby r4zoli » Fri Nov 16, 2012 1:54 pm

Thanks, it works.
I tried lot other tricks not this one. :crazy:
AOO 4.0 and LibO 4 on Win 8
Hungarian forum co-admin
User avatar
r4zoli
Volunteer
 
Posts: 2882
Joined: Mon Nov 19, 2007 8:23 pm
Location: Budapest, Hungary

Re: [Solved] Closing parenthesis problem

Postby RGB » Sat Nov 17, 2012 1:52 am

Note, you do not need the backslash for the brackets:

Code: Select all   Expand viewCollapse view
(r + r_{"+"} )


will work too.

Code: Select all   Expand viewCollapse view
left(r + r_{"+"} right)


will work better and

Code: Select all   Expand viewCollapse view
left(r + r_{{}+{}} right)


even better ;)
There are two types of people: those who believe that there are two types of people and those who do not.

openSUSE Leap with KDE Plasma / LibreOffice
User avatar
RGB
 
Posts: 1455
Joined: Mon Oct 08, 2007 1:34 am

Re: [Solved] Closing parenthesis problem

Postby r4zoli » Sat Nov 17, 2012 1:55 pm

My further observations:
I get the .docx file with integrals with lower and upper limits, and this r + r_+ math objects, saved as OpenDocument in MS Word 2007 SP3, and the saved the saved math objects scrambled when I opened in AOO 3.4.1
The r +r_+ corrected as suggested by you.
These all problems in MSO needs to be corrected in AOO, I changed it manually, because the document contained only 25 equations.
The integral example:
Code: Select all   Expand viewCollapse view
int_t_0^t_2 {Q  \(  t  \)  d t}
created in MSO and it works when I transformed to
Code: Select all   Expand viewCollapse view
int csub {t_"0"} csup {t_"2"} Q( t)  d t
AOO 4.0 and LibO 4 on Win 8
Hungarian forum co-admin
User avatar
r4zoli
Volunteer
 
Posts: 2882
Joined: Mon Nov 19, 2007 8:23 pm
Location: Budapest, Hungary


Return to Math

Who is online

Users browsing this forum: No registered users and 1 guest