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 sinneD  
#1 Posted : 17 August 2018 18:11:17(UTC)
sinneD


Rank: Advanced Member

Groups: Registered
Joined: 12/03/2011(UTC)
Posts: 101
Location: Chicago

Was thanked: 16 time(s) in 7 post(s)
Is there a way to initiate the step calculation (F11) at a specific place in the worksheet?

When ever I try to use it, it always goes to the begining.

Is there a way to go backwards a step or two?

I am trying to debug a for-next loop and it takes a LONG time to get to the place I need to be doing it step at a time.

Is there a doc or page that describes this sort of thing? I have not been able to find anything yet.

Thanks in advance
Dennis
Join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW

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

Offline Jean Giraud  
#2 Posted : 17 August 2018 20:48:37(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: sinneD Go to Quoted Post
Is there a way to initiate the step calculation (F11) at a specific place in the worksheet?

When ever I try to use it, it always goes to the begining.


Once the document is working, you can set "Auto-calc".
That may have no effect for debugging a for loop.
If you want to calculate sin(30) at the end of a greedy work sheet,
and "Auto-calc" ON, it will just calculate sin(45)=

You can attach your document for doctoring

Jean

Offline Davide Carpi  
#3 Posted : 18 August 2018 11:09:33(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)
As for now I think the only way it's to insert a dummy operation in the point you want the debug starts (f.e. you can define test:1 and everything will be recalculated from that point onwards)
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects
Offline Jean Giraud  
#4 Posted : 20 August 2018 01:15:29(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: Davide Carpi Go to Quoted Post
As for now I think the only way it's to insert a dummy operation in the point you want the debug starts (f.e. you can define test:1 and everything will be recalculated from that point onwards)

More simply: copy/paste on new page what belongs to debugging,
or disable all stuff that does not belong to debugging.
Modular programs are easier to debug piece wise.
Offline sinneD  
#5 Posted : 08 September 2018 02:30:48(UTC)
sinneD


Rank: Advanced Member

Groups: Registered
Joined: 12/03/2011(UTC)
Posts: 101
Location: Chicago

Was thanked: 16 time(s) in 7 post(s)
Originally Posted by: Davide Carpi Go to Quoted Post
As for now I think the only way it's to insert a dummy operation in the point
you want the debug starts (f.e. you can define test:1 and everything will be recalculated from that
point onwards)


Davide-

I am trying to understand how to do this. Here are some screens- there are a bunch of linked pages.
Even though we are a bit of a 'family' here and we freely share things, one of the pages uses data and
equations from an ANSI/model code that I am not supposed to redistribute so I don't want to toe that line.
There are some of those proprietary equations in here too, but I will try to move them out later.
But MY top level page is attached.

I want to inspect the sections/lines below the arrows I inserted.

As I understand it, in order to get there, I have to step-wise evaluate to that point. When I want to make
an edit, I have to interrupt the processing and restart it from the beginning. In this case, the processing
jumps around a LOT because of the way i set it all up.

If I put test:1 in there, I am not sure how to jump to that point. I use the Step Into (F11) button and the
Continue button to get to where I want to get to.

Whole page-
Wind Loads-COC.sm (122kb) downloaded 16 time(s).

Screen at a time-
debug-Capture-1.PNG

debug-Capture-2.PNG

debug-Capture-3.PNG

debug-Capture-4.PNG

Edited by user 08 September 2018 02:34:28(UTC)  | Reason: Not specified

Join the SMath Studio Users Discord Channel: https://discord.gg/PayZpJW
Offline Davide Carpi  
#6 Posted : 08 September 2018 02:59:38(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)
Step 1 is to evaluate the whole worksheet
2018-09-08 01_54_17-SMath Studio - [Page3_].png
Step 2 is to set the breakpoint
2018-09-08 01_54_33-SMath Studio - [Page3_].png
Step 3 is to trigger the evaluation of the block, by defining something before that block
2018-09-08 01_56_04-SMath Studio - [Page3_].png

Once you find something wrong, edit it and set the breakpoint, then define again something before the block
2018-09-08 01_56_42-SMath Studio - [Page3_].png

(and repeat... anything above the yellow variables is kept from the first evaluation)

Edited by user 08 September 2018 03:01:26(UTC)  | Reason: Not specified

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 08/09/2018(UTC)
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.