Welcome Guest! To enable all features please Login. New Registrations are disabled.

Notification

Icon
Error

Login


Options
Go to last post Go to first unread
Offline Guy Payeur  
#1 Posted : 09 May 2019 18:27:56(UTC)
Guy Payeur


Rank: Member

Groups: Registered
Joined: 15/09/2012(UTC)
Posts: 20
Man
Canada
Location: Quebec

Was thanked: 2 time(s) in 2 post(s)
Hello,

I was writing an example of Fourier series when I encounter a misleading display with the sum() function. Here is the setup:
2019-05-09 11_30_56-SMath Studio - [ISERROR QUESTION MARK_B.sm_].png

Look at the attached file for full setup and findings.
ISERROR QUESTION MARK_B.sm (18kb) downloaded 18 time(s).

I understand the case, and I don't have a solution for that. I just wanted others to save time finding what is happening here.

One way I discovered this behavior was by trying to select only the right part of the formula, the action always selected this part:
2019-05-09 11_32_22-SMath Studio - [ISERROR QUESTION MARK_B.sm].png

Best regards
Guy

Edited by user 09 May 2019 18:32:18(UTC)  | Reason: Not specified

Wanna join the discussion?! Login to your SMath Studio Forum forum account. New Registrations are disabled.

Offline Jean Giraud  
#2 Posted : 09 May 2019 19:07:45(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,866
Canada

Was thanked: 981 time(s) in 809 post(s)
S(0)≡S1(0)≡S2(0)≡0 ... No error wrt the 3 different constructions.
Try save under another name, close PC, open new session.
As you report it looks there is shadow in the construction context.

ISERROR QUESTION MARK_B.sm (19kb) downloaded 11 time(s).
Offline Jean Giraud  
#3 Posted : 09 May 2019 19:20:11(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,866
Canada

Was thanked: 981 time(s) in 809 post(s)
Originally Posted by: Jean Giraud Go to Quoted Post
As you report it looks there is shadow in the construction context.

Shadow during the construction context is often encountered wrt SUM.
Fourier integral is more generally understood as a fitting method
for discontinuous functions as exemplified in there.

Jean

Fourier Integral.sm (46kb) downloaded 15 time(s).

Offline Davide Carpi  
#4 Posted : 10 May 2019 12:39:09(UTC)
Davide Carpi


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 13/01/2012(UTC)
Posts: 2,647
Man
Italy
Location: Italy

Was thanked: 1329 time(s) in 875 post(s)
It's a quite common problem. One solution software-side is to add automated parenthesis (and we are able to do it, look for example at booleans); enforcing this approach however has as drawback that in quite simple math you might end to have an huge amount of useless or unwanted parenthesis due to the interaction of enforced rules to different operators and functions. It's something quite delicate to handle; don't force them leave the doors open to some mistake, but even the choice to the user to handle them. Umnik
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects
thanks 1 user thanked Davide Carpi for this useful post.
on 10/05/2019(UTC)
Offline Guy Payeur  
#5 Posted : 10 May 2019 14:41:30(UTC)
Guy Payeur


Rank: Member

Groups: Registered
Joined: 15/09/2012(UTC)
Posts: 20
Man
Canada
Location: Quebec

Was thanked: 2 time(s) in 2 post(s)
Thank you Jean and Davide. I understand that is difficult to really make everyone happy. Nevertheless, without adding automated parenthesis (personally I prefer to add them myself), certain things could be done. For example, in Excel when you are in a formula, the corresponding parenthesis flashes on the other side of the formula:
2019-05-10 07_17_41-Fourier_Dynamic.xls  -  Compatibility Mode - Excel.png
2019-05-10 07_17_21-Fourier_Dynamic.xls  -  Compatibility Mode - Excel.png
Look after "sum", in Excel, moving the cursor over the first (or the last) parenthesis highlight the other one for a moment.

In sMath, one solution could be to flash a set of parenthesis that is not apparent while your are not editing formulas. So that something like this:
2019-05-10 07_27_13-SMath Studio - [ISERROR QUESTION MARK_B.sm].png

could look like this for a brief moment when you enter in edit mode (similar behavior as in Excel):
2019-05-10 07_28_16-SMath Studio - [ISERROR QUESTION MARK_B.sm].png

The user then see visually (WYSIWYG) how sMath is himself seeing the formula.

Best regards
Guy

Offline Guy Payeur  
#6 Posted : 10 May 2019 14:54:18(UTC)
Guy Payeur


Rank: Member

Groups: Registered
Joined: 15/09/2012(UTC)
Posts: 20
Man
Canada
Location: Quebec

Was thanked: 2 time(s) in 2 post(s)
There is a behavior that I realized while playing with sMath. When you place the cursor in front of the operator, sMath underlined the operator and all of its operants:
2019-05-10 07_45_56-SMath Studio - [ISERROR QUESTION MARK_B.sm].png

2019-05-10 07_46_25-SMath Studio - [ISERROR QUESTION MARK_B.sm].png

If I were attentive enough, I could of found what was happening a lot faster... Sad

When you are inside a operator, sMath underline only the inside operator:
2019-05-10 07_47_22-SMath Studio - [ISERROR QUESTION MARK_B.sm].png

For the sake of intuitivity, I guest adding the "Excel parenthesis" behavior would of enlightened me Blush

Best regards
Guy
thanks 1 user thanked Guy Payeur for this useful post.
on 10/05/2019(UTC)
Offline Jean Giraud  
#7 Posted : 10 May 2019 16:31:12(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,866
Canada

Was thanked: 981 time(s) in 809 post(s)
Originally Posted by: Guy Payeur Go to Quoted Post
In sMath, one solution could be to flash a set of parenthesis

Oh ! NEVER-ever that, Smath is as it must be, you will soon get used.
No possible mistake, as you open ( it closes as well, then plug-in stuff.
Mathematica 4.0 opens ( and shows were to close in color.
Never used Excel for last 20 years.
Mathcad only opens ( then close anywhere even in the blue.
OriginLab like Mathcad, open ( close were desired

The document I returned: does it work ?
Don't hesitate for any question. Often, doctoring is few clicks.

Cheers ... Jean
Offline Guy Payeur  
#8 Posted : 10 May 2019 18:48:06(UTC)
Guy Payeur


Rank: Member

Groups: Registered
Joined: 15/09/2012(UTC)
Posts: 20
Man
Canada
Location: Quebec

Was thanked: 2 time(s) in 2 post(s)
Hello Jean,

Yes I did download your file. The file worked fine.

You are right, S(0)=S1(0)=S2(0)=0

2019-05-10 11_44_19-SMath Studio - [ISERROR QUESTION MARK_B.sm_].jpg

Best regards
Guy
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.