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 Andrey Ivashov  
#1 Posted : 01 October 2010 02:11:34(UTC)
Andrey Ivashov


Rank: Administration

Groups: Developers, Registered, Knovel Developers, Administrators, Advanced Member
Joined: 11/07/2008(UTC)
Posts: 1,616
Man
Russian Federation

Was thanked: 1978 time(s) in 666 post(s)
Hey! I have really good news today! Clap Biggrinancing:


Hint 1: Local variable and functions are really local now.
Hint 2: Line as a body of definition (right part of equation) is required.
Hint 3: Last element of line(..) function returns an answer to the left part.

Seems SMath Studio 0.90 will be really powerful tool! Thanks to all for helping me with a project!

Best regards, Andrey Ivashov.

Related topics:
  • Operators behavior?
  • User defined functions
  • and others...

    Edited by user 01 October 2010 02:16:40(UTC)  | Reason: Not specified

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

    Offline Andrey Ivashov  
    #2 Posted : 01 October 2010 02:37:33(UTC)
    Andrey Ivashov


    Rank: Administration

    Groups: Developers, Registered, Knovel Developers, Administrators, Advanced Member
    Joined: 11/07/2008(UTC)
    Posts: 1,616
    Man
    Russian Federation

    Was thanked: 1978 time(s) in 666 post(s)
    SMath Studio Live updated with the latest sources, so anyone can test new features:
    Open in SMath Cloud

    Regards.
    Offline oscampo  
    #3 Posted : 01 October 2010 02:51:33(UTC)
    oscampo


    Rank: Advanced Member

    Groups: Registered
    Joined: 10/12/2009(UTC)
    Posts: 246
    Man
    Colombia
    Location: Cali, Colombia

    Was thanked: 85 time(s) in 65 post(s)
    Thanks a lot!! It's really a wonderful improvement.
    Offline omorr  
    #4 Posted : 01 October 2010 08:54:06(UTC)
    omorr


    Rank: Administration

    Groups: Registered, Advanced Member
    Joined: 23/06/2009(UTC)
    Posts: 1,740
    Man
    Serbia

    Was thanked: 318 time(s) in 268 post(s)
    Dance Biggrinancing: Dance
    I will test it these days - of course Good

    Many thanks Andrey Good
    When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
    Offline omorr  
    #5 Posted : 01 October 2010 10:13:05(UTC)
    omorr


    Rank: Administration

    Groups: Registered, Advanced Member
    Joined: 23/06/2009(UTC)
    Posts: 1,740
    Man
    Serbia

    Was thanked: 318 time(s) in 268 post(s)
    Hello Andrey,

    Test 1 Good
    Open in SMath Cloud
    in the 0.89_6, variable "n" will have the same value and variable "y" will be undefined ("i" will be just i -imaginary unit).

    Am I missing something? I've thought that variables "n", "y" and "i" should not be known here. i.e. being local to the function g(x,f(x)).

    Hint 1: Local variable and functions are really local now.
    Please explain what does this mean. I might be misleading.

    Regards,
    Radovan

    Edited by user 01 October 2010 10:16:41(UTC)  | Reason: Not specified

    When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
    Offline omorr  
    #6 Posted : 01 October 2010 10:31:25(UTC)
    omorr


    Rank: Administration

    Groups: Registered, Advanced Member
    Joined: 23/06/2009(UTC)
    Posts: 1,740
    Man
    Serbia

    Was thanked: 318 time(s) in 268 post(s)
    Hello Andrey

    Test 2 Good
    Open in SMath Cloud
    This is nice Good

    Regards,
    Radovan

    Edited by user 01 October 2010 10:35:22(UTC)  | Reason: Not specified

    When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
    Offline Andrey Ivashov  
    #7 Posted : 01 October 2010 13:05:49(UTC)
    Andrey Ivashov


    Rank: Administration

    Groups: Developers, Registered, Knovel Developers, Administrators, Advanced Member
    Joined: 11/07/2008(UTC)
    Posts: 1,616
    Man
    Russian Federation

    Was thanked: 1978 time(s) in 666 post(s)
    Radovan, thank you for testing!

    omorr wrote:
    Am I missing something? I've thought that variables "n", "y" and "i" should not be known here. i.e. being local to the function g(x,f(x)).

    Hint 1: Local variable and functions are really local now.
    Please explain what does this mean. I might be misleading.

    It is an error that I should fix. Variables defined in the right part of expression will not be visible outside of this expression.

    Regards.
    Offline omorr  
    #8 Posted : 01 October 2010 13:47:23(UTC)
    omorr


    Rank: Administration

    Groups: Registered, Advanced Member
    Joined: 23/06/2009(UTC)
    Posts: 1,740
    Man
    Serbia

    Was thanked: 318 time(s) in 268 post(s)
    Wish you good luck Andrey,

    This is one of the greatest feature needed for SMath IMHO.

    Regards,
    Radovan
    When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
    Offline omorr  
    #9 Posted : 03 October 2010 17:12:41(UTC)
    omorr


    Rank: Administration

    Groups: Registered, Advanced Member
    Joined: 23/06/2009(UTC)
    Posts: 1,740
    Man
    Serbia

    Was thanked: 318 time(s) in 268 post(s)
    This is also working now Good
    Assignment inside matrix! Matrix has the value and the variables inside as matrix elements.
    Open in SMath Cloud
    Regards,
    Radovan
    When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
    Offline Andrey Ivashov  
    #10 Posted : 04 October 2010 01:02:42(UTC)
    Andrey Ivashov


    Rank: Administration

    Groups: Developers, Registered, Knovel Developers, Administrators, Advanced Member
    Joined: 11/07/2008(UTC)
    Posts: 1,616
    Man
    Russian Federation

    Was thanked: 1978 time(s) in 666 post(s)
    Hello.

    Interesting thing - line(..) function on the right part of equation means now that SMath Studio will not even parse all stuff of the line before left part will be called by someone. And here is a side effect:


    This is not the error, but some interesting way to work with functions. In other words it is like one more option of Optimization. Numeric optimization means, that program will try to evaluate right part of equation numerically, symbolic optimization - evaluate symbolically, no optimization means, that program will substitute all previous definitions to the right part of equation and line(..) function at right means that program will not substitute previous definitions to the right part at all.

    Best regards.

    Edited by user 04 October 2010 01:06:53(UTC)  | Reason: Not specified

    Offline omorr  
    #11 Posted : 04 October 2010 15:37:13(UTC)
    omorr


    Rank: Administration

    Groups: Registered, Advanced Member
    Joined: 23/06/2009(UTC)
    Posts: 1,740
    Man
    Serbia

    Was thanked: 318 time(s) in 268 post(s)
    smath wrote:
    ... line(..) function at right means that program will not substitute previous definitions to the right part at all.

    This is also a nice one Good . The solution when you want to see how the function was actually defined - without replacing things.

    BTW., just tried 0.89_8. I am not sure but there might be a minor issue. If you have the file "somefile.sm" and in the same folder save as HTML, there would be "somefile.htm" file and "somefile" folder with pictures. Now, if you try to save the compressed SMath studio file with the name "somefile" as the compressed SMath type "*.smz", it will not be saved unless you explicitly type in the file name box "somefile.smz".

    Regards,
    Radovan
    When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
    Offline adiaz  
    #12 Posted : 01 October 2012 14:05:48(UTC)
    adiaz


    Rank: Member

    Groups: Registered
    Joined: 03/06/2009(UTC)
    Posts: 25

    Was thanked: 5 time(s) in 5 post(s)
    Originally Posted by: smath Go to Quoted Post
    This is not the error, but some interesting way to work with functions. In other words it is like one more option of Optimization. Numeric optimization means, that program will try to evaluate right part of equation numerically, symbolic optimization - evaluate symbolically, no optimization means, that program will substitute all previous definitions to the right part of equation and line(..) function at right means that program will not substitute previous definitions to the right part at all.
    Best regards.


    I'm not comftable with this. As shown in the picture, when write 'g', 'a' appears as 'a = 2'. Others programs have a warning message for the use of global variables locally. I think that you must to introduce a global command to catch the value of a in g(x).

    Regards.

    Alvaro.
    adiaz attached the following image(s):
    Clipboard02.gif
    Offline omorr  
    #13 Posted : 01 October 2012 16:15:31(UTC)
    omorr


    Rank: Administration

    Groups: Registered, Advanced Member
    Joined: 23/06/2009(UTC)
    Posts: 1,740
    Man
    Serbia

    Was thanked: 318 time(s) in 268 post(s)
    Hello Alvaro,

    I could not get the same results as you did.
    See the picture please.

    Regards,
    Radovan
    omorr attached the following image(s):
    symbnum.png
    When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
    Offline adiaz  
    #14 Posted : 01 October 2012 16:44:55(UTC)
    adiaz


    Rank: Member

    Groups: Registered
    Joined: 03/06/2009(UTC)
    Posts: 25

    Was thanked: 5 time(s) in 5 post(s)
    Hi. In my example it is (|a*x)*1, but yours is (|a*x*1)

    Regards.
    Offline omorr  
    #15 Posted : 01 October 2012 17:03:28(UTC)
    omorr


    Rank: Administration

    Groups: Registered, Advanced Member
    Joined: 23/06/2009(UTC)
    Posts: 1,740
    Man
    Serbia

    Was thanked: 318 time(s) in 268 post(s)
    Hello Alvaro,
    Originally Posted by: adiaz Go to Quoted Post
    Hi. In my example it is (|a*x)*1, but yours is (|a*x*1)

    You are right. This might be sometimes quite frustrating. Everything looks the same but the result is different. SMath can not deal with braces correctly and satisfactory quite often Sad

    This one is one of the examples of that problem I mentioned few times here on the Forum.

    range(1,6*2)=mat(1,2,3,4,5,6,7,8,9,10,11,12,12,1) range(1,6)*2=mat(2,4,6,8,10,12,6,1)

    Regards,
    Radovan

    Edited by user 01 October 2012 17:05:09(UTC)  | Reason: Not specified

    When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
    thanks 1 user thanked omorr for this useful post.
    on 01/10/2012(UTC)
    Offline adiaz  
    #16 Posted : 01 October 2012 18:05:07(UTC)
    adiaz


    Rank: Member

    Groups: Registered
    Joined: 03/06/2009(UTC)
    Posts: 25

    Was thanked: 5 time(s) in 5 post(s)
    Well, as I see, this the price for obtain clarity in others expression. Mathematica have a lot of this problems with TraditionalNotation, Maple too. But at the end, this give less mistakes that working with parenthesis and text notations.

    Defining a function as f(x) := 1*(| ... ) make all variables in line(...) as globals.

    Regards.
    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.