1 Pages (8 items)
Variable with subscript - Messages
#1 Posted: 11/17/2009 12:02:28 PM
Hi All
In Mathcad, I usually type a variable with subscript by using dot(.)
For example A.x then it will show A with a subscript x.
Is that possible in SMath? or similar?
I know in SMath there is a function index by pressing [
but this is different with .
Thanks for any information
Regards
Waluyo
In Mathcad, I usually type a variable with subscript by using dot(.)
For example A.x then it will show A with a subscript x.
Is that possible in SMath? or similar?
I know in SMath there is a function index by pressing [
but this is different with .
Thanks for any information
Regards
Waluyo
#2 Posted: 11/17/2009 1:03:58 PM
Hello.
My idea is to combine (.) and ([) in one ([). For example SMath Studio can differentiate expression like [MATH]diff((el(x;1;1)^2);el(x;1;1))[/MATH] using ([), but Mathcad cannot (because (.) required). In future I hope to make it possible to allow ([) everywhere instead of (.).
Hope this is understandable
My idea is to combine (.) and ([) in one ([). For example SMath Studio can differentiate expression like [MATH]diff((el(x;1;1)^2);el(x;1;1))[/MATH] using ([), but Mathcad cannot (because (.) required). In future I hope to make it possible to allow ([) everywhere instead of (.).
Hope this is understandable

#3 Posted: 11/17/2009 1:50:16 PM
Hello,
I was playing a bit with variable names.

It seems that it is advisable not to use these character in the variable names. Interesting to note that this variable could be also defined:
[MATH]diff(abc)←98[/MATH]
By typing "diff(" which will produce placeholder with prime
[MATH]diff(#)[/MATH]
In this placeholder we can put a variable name.
I do not know if all of this could cause some problems or not.
On the other hand, there is no problem of using characters in variable names from different languages. Mathcad could not do this for a long, long time (actually I do not know if this could do even now in the recent version).
Regards,
Radovan
EDIT: Actually my first intention for this post was to mention that literal subscript (.) and index ([) are mentioned here few times from Mathcad users. From my experience as a Professor, I found it very confusing sometimes and hard for explaining to my students. Maybe the solution is (as Andrey suggested) to have only one - and not both.
I was playing a bit with variable names.
It seems that it is advisable not to use these character in the variable names. Interesting to note that this variable could be also defined:
[MATH]diff(abc)←98[/MATH]
By typing "diff(" which will produce placeholder with prime
[MATH]diff(#)[/MATH]
In this placeholder we can put a variable name.
I do not know if all of this could cause some problems or not.
On the other hand, there is no problem of using characters in variable names from different languages. Mathcad could not do this for a long, long time (actually I do not know if this could do even now in the recent version).
Regards,
Radovan
EDIT: Actually my first intention for this post was to mention that literal subscript (.) and index ([) are mentioned here few times from Mathcad users. From my experience as a Professor, I found it very confusing sometimes and hard for explaining to my students. Maybe the solution is (as Andrey suggested) to have only one - and not both.
When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
#4 Posted: 11/17/2009 4:19:47 PM
to SMath
I think my question is similar with that has been posted by another user under the topic header "How to make a subscript".
I should have searched carefully.
I hope it can be implemented very soon.
Regards, Waluyo
I think my question is similar with that has been posted by another user under the topic header "How to make a subscript".
I should have searched carefully.
I hope it can be implemented very soon.
Regards, Waluyo
#5 Posted: 12/6/2009 6:10:28 AM
Glad to hear you are planning to implement variable subscripts. This would be an opportunity to one-up MathCAD; I have long wished to have the bar or dot above variable names to indicate average or time derivatives. My worksheets often have cumbersome variable names like Q.dot etc.
I just discovered this program today but I am very excited to use it and watch it develop. Great work to the devs!
I just discovered this program today but I am very excited to use it and watch it develop. Great work to the devs!
#6 Posted: 12/6/2009 10:29:49 AM
Hello,
It was long time my wish too (bar or dots over the variable, superscript in the variable name etc.) but I do not believe it could be performed. In Mathcad you can have exotic characters or even operators in variable names. SMath have rather good multilanguage suport, and you can name varaiables with really "exotic" characters. On the other hand, this is not advisable because of possible portability problems of SMath files. I am not quite sure about all of this, but the most secure way is to avoid special characters at the moment.
Regards,
Radovan
It was long time my wish too (bar or dots over the variable, superscript in the variable name etc.) but I do not believe it could be performed. In Mathcad you can have exotic characters or even operators in variable names. SMath have rather good multilanguage suport, and you can name varaiables with really "exotic" characters. On the other hand, this is not advisable because of possible portability problems of SMath files. I am not quite sure about all of this, but the most secure way is to avoid special characters at the moment.
Regards,
Radovan
When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
#7 Posted: 5/26/2010 9:19:25 AM
Hello,
(SMath Studio version 0.88 is current as I write this.)
About Andrey's statement:
It might be worthwhile to keep these separate. What the computer does with A.x (at least in Mathcad) is different than with A[x
That is, A[x uses x as an index to select one element from A, but A.x names a variable which has nothing to do with the variable (matrix) A.
* The (.) is just part of the variable name, so that there is hardly any difference between A.x and Abx. There can be a worksheet that refers just to A.x, without variables A or x existing at all.
* On the other hand, ([) can be thought of as a function with arguments A and x that "does something" with A and x to get or set a value. Arguments A and x are required to exist as separate variables in order for A[x to be valid.
The previous paragraph might help with Radovan's concern about explaining the difference between ([) and (.) to students / new users.
Furthermore, maybe future versions of SMath Studio could have the following 2 formatting features:
1. ([) could be formatted with parentheses and an arguments separator, similar to the following (depending on localization):

(.) would be formatted as ([) (with one argument) is today, that is, without the parentheses ().
2. The "(" character could be disallowed in variable names (if it is not already).
As a result, someone looking at an SMath Studio worksheet could tell at a glance whether each subscript was a ([) or a (.) That is, ([) would have parentheses and (.) would not.
I think that combining the 2 kinds of subscripts into one could cause problems. For example, suppose the user has a matrix called A but also wants to define a scalar called A.x:

If (.) were separate from ([), then (.) could be used in this example, and there would be no error.
It seems to me that an expression like the following (using the formatting features suggested above) could still be evaluated (differentiated) just fine if (.) were added to SMath Studio:

According to the formatting features suggested above, the subscripts in that expression would be ([)
I assume that Andrey mentioned this expression just to point out that SMath Studio has the potential to be more versatile than Mathcad when it comes to subscripts.
If I am misunderstanding, maybe someone can clarify for me.
(SMath Studio version 0.88 is current as I write this.)
About Andrey's statement:
WroteMy idea is to combine (.) and ([) in one ([).
It might be worthwhile to keep these separate. What the computer does with A.x (at least in Mathcad) is different than with A[x
That is, A[x uses x as an index to select one element from A, but A.x names a variable which has nothing to do with the variable (matrix) A.
* The (.) is just part of the variable name, so that there is hardly any difference between A.x and Abx. There can be a worksheet that refers just to A.x, without variables A or x existing at all.
* On the other hand, ([) can be thought of as a function with arguments A and x that "does something" with A and x to get or set a value. Arguments A and x are required to exist as separate variables in order for A[x to be valid.
The previous paragraph might help with Radovan's concern about explaining the difference between ([) and (.) to students / new users.
Furthermore, maybe future versions of SMath Studio could have the following 2 formatting features:
1. ([) could be formatted with parentheses and an arguments separator, similar to the following (depending on localization):

(.) would be formatted as ([) (with one argument) is today, that is, without the parentheses ().
2. The "(" character could be disallowed in variable names (if it is not already).
As a result, someone looking at an SMath Studio worksheet could tell at a glance whether each subscript was a ([) or a (.) That is, ([) would have parentheses and (.) would not.
I think that combining the 2 kinds of subscripts into one could cause problems. For example, suppose the user has a matrix called A but also wants to define a scalar called A.x:

If (.) were separate from ([), then (.) could be used in this example, and there would be no error.
It seems to me that an expression like the following (using the formatting features suggested above) could still be evaluated (differentiated) just fine if (.) were added to SMath Studio:

According to the formatting features suggested above, the subscripts in that expression would be ([)
I assume that Andrey mentioned this expression just to point out that SMath Studio has the potential to be more versatile than Mathcad when it comes to subscripts.
If I am misunderstanding, maybe someone can clarify for me.
#8 Posted: 6/24/2010 6:59:07 AM
Hello.
Thanks for your comments.
Subscript for variables, functions and units implemented. This feature will be available with a new version of SMath Studio. For now, you can test it using SMath Studio Live.
See also: How to make a subscript.
Regards.
Thanks for your comments.
Subscript for variables, functions and units implemented. This feature will be available with a new version of SMath Studio. For now, you can test it using SMath Studio Live.
See also: How to make a subscript.
Regards.
1 Pages (8 items)
-
New Posts
-
No New Posts