Post Reply 
(Free42) matrix copy/paste bug
02-09-2018, 03:06 PM
Post: #21
RE: (Free42) matrix copy/paste bug
Strange, because that's what I did.. in Firefox.
Anyway - found another anomaly ;-)
If I try and create a Nx2 matrix with a "J" in the (1,1) position, I get a complex matrix? So I change the "J" into something else and then it works.
Can't guarantee the tabs will show up here:

Code:
J    1
erg    1ᴇ-7
Kcal    4186.8
cal    4.1868
Btu    1055.05585262
ft×lbf    1.35581794833
therm    105506ᴇ3
MeV    160219ᴇ-18
eV    160219ᴇ-24

Cheers, Werner

41CV†,42S,48GX,49G,DM42,DM41X,17BII,15CE,DM15L,12C,16CE
Find all posts by this user
Quote this message in a reply
02-09-2018, 04:24 PM
Post: #22
RE: (Free42) matrix copy/paste bug
"J" / "j" is accepted as an alternative spelling of "I" / "i", so your Joule unit turns into (0, 1).

Hmmm, maybe I should make it accept only lowercase i and j as the imaginary unit. Does anyone actually use uppercase I or J for this? I don't remember why I coded it that way...
Visit this user's website Find all posts by this user
Quote this message in a reply
02-09-2018, 05:26 PM
Post: #23
RE: (Free42) matrix copy/paste bug
Yes, that’s what I figured - but the 42 does not know i or I or j, it’s always a string?
Werner

41CV†,42S,48GX,49G,DM42,DM41X,17BII,15CE,DM15L,12C,16CE
Find all posts by this user
Quote this message in a reply
02-09-2018, 05:39 PM
Post: #24
RE: (Free42) matrix copy/paste bug
I don't understand the question. Are you saying there is an inconsistency? If so, where?
Visit this user's website Find all posts by this user
Quote this message in a reply
02-09-2018, 05:49 PM
Post: #25
RE: (Free42) matrix copy/paste bug
I was wrong - it does know i of course, but not a lone i, and not a j or J.
It’s not a big deal, you know..
Werner

41CV†,42S,48GX,49G,DM42,DM41X,17BII,15CE,DM15L,12C,16CE
Find all posts by this user
Quote this message in a reply
02-09-2018, 06:11 PM
Post: #26
RE: (Free42) matrix copy/paste bug
(02-09-2018 05:49 PM)Werner Wrote:  I was wrong - it does know i of course, but not a lone i, and not a j or J.
It’s not a big deal, you know..
Werner

Do you mean how it displays and copies numbers, vs. the formats it accepts when pasting?
I'm having trouble making sense of your first sentence.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-09-2018, 06:42 PM
Post: #27
RE: (Free42) matrix copy/paste bug
You cannot enter i in the 42. It displays it in complex numbers, that is all.
i is shown as ‘0 i1’ - that’s what I mean with it not being a lone i.
I have no idea what formats the copy/paste accepts for complex numbers? Apparently it interprets J,j,I,i as 0 i1.
One way to solve this is to allow defining strings between double quotes. Then I can put “J” for a string and J for a complex number.
Cheers, Werner

41CV†,42S,48GX,49G,DM42,DM41X,17BII,15CE,DM15L,12C,16CE
Find all posts by this user
Quote this message in a reply
02-09-2018, 07:14 PM
Post: #28
RE: (Free42) matrix copy/paste bug
Paste recognizes complex numbers is these formats:

NUMBER ANGLE_SYMBOL NUMBER
NUMBER SIGN UNSIGNED_NUMBER IMAGINARY_UNIT
NUMBER SIGN IMAGINARY_UNIT
( NUMBER , NUMBER )

Where ANGLE_SYMBOL is ∠ or ∡ (U+2220 "angle" or U+2221 "measured angle")
SIGN is + or -
IMAGINARY_UNIT is I, i, J, or j
Also, in the vector notation, : or ; may be used instead of comma. If comma is used, it must be separated from the numbers preceding and following it by spaces.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-10-2018, 06:15 AM
Post: #29
RE: (Free42) matrix copy/paste bug
Thanks, Thomas.
Why
NUMBER SIGN UNSIGNED_NUMBER IMAGINARY_UNIT
And not
NUMBER NUMBER IMAGINARY_UNIT


moreover, it seems IMAGINARY_UNIT must always be preceded by a number, so why does a lone J get interpreted as a complex number?

Cheers, Werner

41CV†,42S,48GX,49G,DM42,DM41X,17BII,15CE,DM15L,12C,16CE
Find all posts by this user
Quote this message in a reply
02-10-2018, 06:53 AM
Post: #30
RE: (Free42) matrix copy/paste bug
(02-10-2018 06:15 AM)Werner Wrote:  Why
NUMBER SIGN UNSIGNED_NUMBER IMAGINARY_UNIT
And not
NUMBER NUMBER IMAGINARY_UNIT

Because the latter would allow, say, "2 3i". I think there should always be a + or a - between the real and imaginary parts in this kind of notation.

(02-10-2018 06:15 AM)Werner Wrote:  moreover, it seems IMAGINARY_UNIT must always be preceded by a number, so why does a lone J get interpreted as a complex number?

I goofed and missed that case in my list of accepted formats. The code does, in fact, handle this.
The imaginary unit does not have to be preceded by a number; 1+i and 1-i are valid, and so are i and -i.
Visit this user's website Find all posts by this user
Quote this message in a reply
02-10-2018, 09:11 AM
Post: #31
RE: (Free42) matrix copy/paste bug
Thanks for the detailed explanation!
Werner

41CV†,42S,48GX,49G,DM42,DM41X,17BII,15CE,DM15L,12C,16CE
Find all posts by this user
Quote this message in a reply
02-11-2018, 08:50 AM
Post: #32
RE: (Free42) matrix copy/paste bug
In 2.0.14, I and J are no longer recognized as the imaginary unit; only i and j are.
Regarding the use of quote signs to force a cell to be interpreted as a string: I hope the 2.0.14 change makes that issue mostly moot. Smile
Visit this user's website Find all posts by this user
Quote this message in a reply
02-11-2018, 09:13 AM
Post: #33
RE: (Free42) matrix copy/paste bug
Well, yes and no ;-) The day I need to copy a string "i" or "j", I'll be back ;-)
Thanks, Thomas !

Werner

41CV†,42S,48GX,49G,DM42,DM41X,17BII,15CE,DM15L,12C,16CE
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 4 Guest(s)