Message Boards Message Boards

3 Replies
1 Total Likes
View groups...
Share this post:

Mathematica 10: Problem with inserting values in formulas via FormulaData

Posted 10 years ago


FormulaData[] is really great. But I did't find out, how to insert values for some variables.

formula = {"DistanceSpeedTime", "Acceleration", "InitialSpeed"};
given = {"d" -> Quantity[100, "Meters"],  "t" -> Quantity[10, "Seconds"],"v_i" ->Quantity[5, "Meters"/"Seconds"]};
FormulaData[formula, given]

I'm not able to insert values for variables with an intex in the notation, in my example above for the "InitialSpeed" v_i. I always get the Message "Unknown physical quantity specification" (see also Link).

Any idea how this works?

POSTED BY: Juerg Baertsch
3 Replies
Posted 10 years ago

You should use

given = {"d" -> Quantity[100, "Meters"], "t" -> Quantity[10, "Seconds"], Subscript["v", "i"] -> Quantity[5, "Meters"/"Seconds"]} 

or type "v" Ctrl+_ "i" as the short form

POSTED BY: Karsten 7.

Thanks a lot Karsten!

This helped me! I tried always "v Ctrl+_ i", didn't have the Idea, that "v" and "i" have to be two different Strings!

POSTED BY: Juerg Baertsch
Posted 10 years ago

You can read Blanck(_) for more information about the meaning of _ in Mma.

POSTED BY: Karsten 7.
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
or Discard

Group Abstract Group Abstract