4
$\begingroup$

N.B.: I've bolded the questions to make it easy to find them among the background verbiage.

1) Is there a way to generate a list of just the physical constants? [Note that I am not looking for a list of those in the deprecated physical constants package, but rather the current physical constants.] MSE member Mark Adler supplied this code, which gives a list of all units, including the physical constants, and then manually pulled out most (but not all) of the physical constants from it (http : // mathematica.stackexchange.com/questions/130049/physical - and - other - constants)

Quantity;
Sort@Keys@QuantityUnits`Private`$UnitReplacementRules

I tried finding characteristics that would distinguish the physical constants from the other units, and would thus allow me to extract the physical constants alone, but was unsuccessful.

The following code, modified from the documentation for QuantityVariablePhysicalQuantity, gives the number of physical quantities (including physical constants) in each of several categories, but only for those physical quantities present in MMA's built-in formulae. It might serve as a starting point:

formulas = FormulaLookup[All];
variables = Flatten[FormulaData[#, "QuantityVariables"] & /@ formulas];
quantities = Flatten[QuantityVariablePhysicalQuantity /@ variables];
SortBy[Tally[quantities], Last] // Reverse

2) What's supposed to be the difference between "AvogadroConstantFoxHill" and "AvogadroConstantValueFoxHill"? They both evaluate to 602214141070409084099072/mol. Based on the name, I would have expected "AvogadroConstantValueFoxHill" to be the dimensionless version of "AvogadroConstantFoxHill". But, in the absence of documentation, that's just an educated guess:

UnitConvert@Quantity@"AvogadroConstantFoxHill"
UnitConvert@Quantity@"AvogadroConstantValueFoxHill"

3) Several of the physical constants are available in alternate versions, as ratios of integers, which I assume is to allow exact calculations using physical constants. These are identified by the suffix "NewSI". Thus we have: "AvogadroConstantNewSI", "BoltzmannConstantNewSI", "ElementaryChargeNewSI", and "PlanckConstantNewSI". Thus, for instance:

UnitConvert@Quantity@"BoltzmannConstantNewSI"
Precision[%]
Quantity[300, 
"Joules"]/(Quantity@"BoltzmannConstantNewSI"*
Quantity[300, "Kelvins"])
Precision[%]

$\frac{27613}{2000000000000000000000000000}\:\text{kg}\, \text{m}^2 \text{/(}\text{s}^2\text{K})$

$\infty$

$\frac{2000000000000000000000000000}{27613}$

$\infty$

and

UnitConvert@Quantity@"BoltzmannConstant"
Precision[%]    
Quantity[300, 
"Joules"]/(Quantity@"BoltzmannConstant"*
Quantity[300, "Kelvins"])
Precision[%]

$1.38065 \times 10^{-23}\:\text{kg}\, \text{m}^2 \text{/(}\text{s}^2\text{K})$

$\infty$

$7.24297 \times 10^{22}$

$5.94143$

However, given that "BoltzmannConstant" clearly evaluates to a floating point number, and given that it also clearly behaves like a floating point in the last calculation, why does Precision@Quantity@"BoltzmannConstant" evaluate to $\infty$?

4) Has Wolfram ever explained why they don't provide documentation for the physical constants? And is there any non-offical documentation available?

[Edit: I am using 11.0.1, and I was just informed that "CoulombConstant" is now available in 11.1. But my point remains: it would be helpful if these were documented and cross-referenced.]

Such documentation would certainly be helpful. For instance, recently I needed Coulomb's constant (http://scienceworld.wolfram.com/physics/CoulombsConstant.html). The Help Documentation doesn't list any of the physical constants, and the auto-complete function isn't comprehensive (e.g., it doesn't recognize "AvogadroConstantFoxHill"*), so I searched the list of units I'd generated with the code above, and got no hits. I then searched Wolfram|Alpha, and it returned "Unable to interpret unit specification Coulomb Constant" ("show all results" now does give Coulomb's constant, perhaps because of the update to 11.1). Continuing, since Coulomb's constant is $1/(4 \pi \epsilon_{0})$, where $\epsilon_{0}$ is the vacuum permittivity, I then searched the units list for the latter. Still no hits. However, since the vacuum permittivity is also called the electric constant, I searched for that, and only then was I finally successful.

[*That's probably because it's a proposed constant. But I'd rather search a comprehensive list; that way, if something doesn't show up, I don't have to wonder if it's because it's considered proposed, or not available in the system at all.]

Plus there's also the semi-cryptic "AUsOfElectricPermittivity"; in the absence of documentation, it's not initially obvious what this is.

It would have been much easier if I could have entered Coulomb's constant into the Help search and been redirected to a page that provided the following information:

"Mathematica doesn't have a built-in value for Coulomb's constant , which is given by $1/(4 \pi \epsilon_{0})$, where $\epsilon_{0}$ is the vacuum permittivity, aka the electrical constant (see http://scienceworld.wolfram.com/physics/CoulombsConstant.html). However, in its place, you can use either 1/(4 Pi Quantity@"ElectricConstant"), or 1/Quantity@"AUsOfElectricPermittivity", where "AUsOf" means "angular units of", and where Quantity@"AUsOfElectricPermittivity" = 4*Pi*Quantity@"ElectricConstant". A key difference between the two is that "ElectricConstant" evaluates to a ratio of integers (which means it is treated as an "exact number" in Mathematica's internal calculations), while "AUsOfElectricPermittivity" evaluates to a floating point number, so if you would like only exact numbers in your calculation, you should use the former. For a discussion of the relative utility of performing calculations with exact vs. floating-point numbers, see ....."

N.B.: There is a tag for the deprecated "physicalconstants-package". However this question, and several others over the past few years, specifically concern the current physical constants functionality. As there is no tag for the latter, I created the tag "physical-constants".

$\endgroup$
  • 1
    $\begingroup$ UnitConvert["CoulombsConstant"] evaluates to the same quantity as UnitConvert[1/(4 Pi Quantity@"ElectricConstant")] $\endgroup$ – Bob Hanlon Apr 2 '17 at 17:13
  • $\begingroup$ @BobHanlon What version of MMA are you using? I'm using 11.0.1, and when I try to evaluate UnitConvert["CoulombsConstant"], I get Quantity::unkunit: Unable to interpret unit specification CoulombsConstant. $\endgroup$ – theorist Apr 2 '17 at 17:20
  • 1
    $\begingroup$ I used "11.1.0 for Mac OS X x86 (64-bit) (March 16, 2017)" $\endgroup$ – Bob Hanlon Apr 2 '17 at 17:22
  • $\begingroup$ Thanks, I've updated my question to reflect this. $\endgroup$ – theorist Apr 2 '17 at 17:28
  • 1
    $\begingroup$ I suppose first we would need a definition of what is and is not a physical constant. I think I can recognize a physical constant when I see one, but a cogent definition is not coming to mind right away. Kinda like porn. $\endgroup$ – Mark Adler Apr 3 '17 at 5:29
2
$\begingroup$

From the documentation for Unit Discovery, "You can use both WolframAlpha and Quantity to discover different units and physical constants using their various common names and abbreviations."

WolframAlpha["Coulomb's Constant"]

enter image description here

$\endgroup$
  • $\begingroup$ I was aware of this, but was looking for actual documentation (as seen for functions in the help menu), not merely Wolfram|Alpha results, which can be hit-or miss, and whose quality of exposition doesn't compare to that of the help docs. For instance, unless you know the exact spelling, you can miss things. E.g., there's a built-in function called "AUsOfElectricPermittivity". Yet if I enter Quantity@"angular units of electric permittivity", I get no results. If I enter WolframAlpha@"angular units of electric permittivity", I get a result, but it doesn't give me the above built-in constant. $\endgroup$ – theorist Apr 2 '17 at 19:31
  • $\begingroup$ If I were to use Wolfram|Alpha for unit discovery, I'd want it to return something I could then use as an input, which means I'd need to use the syntax WolframAlpha["some_unit", "MathematicaResult"]. But is there ever any reason I'd want to use that instead of Quantity@"some_unit"? I ask because they seem to return identical results, yet the latter's syntax is much lighter. $\endgroup$ – theorist Apr 2 '17 at 19:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.