Message Boards Message Boards

0
|
10719 Views
|
1 Reply
|
1 Total Likes
View groups...
Share
Share this post:

WolframAlpha results to array

Posted 10 years ago

You could always make a function such as:

f[n_]:=WolframAlpha["air density" <> ToString[n] <> " meters",{{"Result",1},"NumberData"}]

But there is a function in a package for this data, which will be easier to use and quicker:

http://reference.wolfram.com/language/StandardAtmosphere/ref/MeanDensity.html

Needs["StandardAtmosphere`"]
Table[MeanDensity[Quantity[i, "Meters"]], {i, 1, 1000, 100}]

If you want to remove the units from the data, use QuantityMagnitude:

Table[QuantityMagnitude[MeanDensity[Quantity[i, "Meters"]]], {i, 1, 1000, 100}]
POSTED BY: Sean Clarke
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract