(Free42) matrix copy/paste bug - Printable Version +- HP Forums (https://www.hpmuseum.org/forum) +-- Forum: Not HP Calculators (/forum-7.html) +--- Forum: Not quite HP Calculators - but related (/forum-8.html) +--- Thread: (Free42) matrix copy/paste bug (/thread-10113.html) Pages: 1 2 |
RE: (Free42) matrix copy/paste bug - Werner - 02-09-2018 03:06 PM 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 Cheers, Werner RE: (Free42) matrix copy/paste bug - Thomas Okken - 02-09-2018 04:24 PM "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... RE: (Free42) matrix copy/paste bug - Werner - 02-09-2018 05:26 PM Yes, that’s what I figured - but the 42 does not know i or I or j, it’s always a string? Werner RE: (Free42) matrix copy/paste bug - Thomas Okken - 02-09-2018 05:39 PM I don't understand the question. Are you saying there is an inconsistency? If so, where? RE: (Free42) matrix copy/paste bug - Werner - 02-09-2018 05:49 PM 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 RE: (Free42) matrix copy/paste bug - Thomas Okken - 02-09-2018 06:11 PM (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. 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. RE: (Free42) matrix copy/paste bug - Werner - 02-09-2018 06:42 PM 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 RE: (Free42) matrix copy/paste bug - Thomas Okken - 02-09-2018 07:14 PM 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. RE: (Free42) matrix copy/paste bug - Werner - 02-10-2018 06:15 AM 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 RE: (Free42) matrix copy/paste bug - Thomas Okken - 02-10-2018 06:53 AM (02-10-2018 06:15 AM)Werner Wrote: Why 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. RE: (Free42) matrix copy/paste bug - Werner - 02-10-2018 09:11 AM Thanks for the detailed explanation! Werner RE: (Free42) matrix copy/paste bug - Thomas Okken - 02-11-2018 08:50 AM 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. RE: (Free42) matrix copy/paste bug - Werner - 02-11-2018 09:13 AM Well, yes and no ;-) The day I need to copy a string "i" or "j", I'll be back ;-) Thanks, Thomas ! Werner |