Convert units to String
Is there a way to convert compound units to string?For example, I have "Newtons"/"Meters"^2, how to I convert it to "N/m^2"?I know If I do the following QuantityForm[QuantityUnit[Quantity[1, "Newtons"/...
View ArticleGetting Molecular Weight for Stoichiometry Calculations
I love the units system in Mathematica, it's an extremely useful addition to the language. Unfortunately there are still some sharp corners that I run into on a daily basis. For example, if I want to...
View ArticleIncompatible Units Problem
I am trying to use quantities with physical units to calculate my result, but I encountered the "Incompatible units" problem. I don't know what is going on. Here is my code, could I have some...
View ArticlePlotting a function with units gives two different results
With the following code block, I plot a function with units in it in two different ways. Both ways should do the same in my understanding of the documentation.cm = Quantity["Centimeters"];f[x_] :=...
View ArticleWhere to see all Mathematica units [duplicate]
Is there a tutorial page that have all Mathematica units? I sometimes have hard time figuring out the correct unit spelling when using quantities
View ArticleStreamPlot "Part is not a Graphics primitive or directive."
I am trying to use StreamPlot with units. Here is a minimal example to produce the error "Part is not a Graphics primitive or directive." :g[x_] := UnitSimplify[UnitConvert[x...
View ArticleHow to convert units from percent per year to real number with CountryData?...
I have CountryData coming in via e.g.Entity["Country", "Australia"][ EntityProperty["Country", "GDP", {"CurrencyUnit" -> "Constant2000USDollar", "TimeSeriesOperator" -> "AnnualGrowthRate"}...
View ArticleMixedUnit in Fractions
Is there a way to have a more common output format on MixedUnit?Quantity[317.2,MixedUnit[{"Minutes"/"Kilometers", "Seconds"/"Kilometers"}]]givesI would love to have some unit like...
View ArticleAccuracy and precision control for a simple calculation [closed]
Consider a very simple calculation: $231 \times (2.54) ^ 3$, which is the number of cubic cm in a US gallon.On my phone app calculator I got the exact answer, which is $3785.411784$.On Mathematica,...
View ArticleA problem about the integration of blackbody radiation law using FormulaData....
I am trying to integrate blackbody radiation law under 1500 Kelvin using the FormulaData command.The integration seems not to work properly after I designate the integration range. Mathematica does not...
View Articlemesh / region creation in unit meters or mm:
How can we know the unit of mesh or create a mesh in specified length units:such as, for example I have: bmesh = ToBoundaryMesh["Coordinates" -> {{0, 0}, {1, 0}, {1, 1}, {0, 1}, {1/6, 1/6}, {5/6,...
View ArticleImporting scientific data with uncertainties and units
I want to import scientific data from a CSV file. The data are length measurements in centimeters with uncertainties. I want to import the data with uncertainties and units into a vector - please see...
View ArticleWhy does different nondimensionalizations give different results? Although...
I have some problems with the non-dimensionalization of the Hamiltonian of motion in a Coulomb field.The Hamiltonian has a following form:$$H=-\frac{\hbar^2}{2\mu^*} \Delta_r-\frac{e^2}{\epsilon_0...
View ArticleSolve not working with cross product with units
I recently asked this question about using Solve with cross product.Solve not working when doing cross-productWhen I use the units in the definition of the variables, I am not able to get an answer.x =...
View ArticleIssue with unit conversion
I am getting an error converting energy unit Pa*m^3 (Pascal * Meters^3) to J (Joules).pi = Quantity[2.00*10^5, "Pascals"];Vi = Quantity[4.00*10^-6, ("Meters")^3];Vf = Quantity[8.00*10^-6,...
View ArticleCurrency Interpretation for VND
Bug introduced in v12.2.0 or earlier, persisting through v13.2.1. Case number: 4973722As I was helping an OP with a question involving Vietnamese currency, I didn't realize at the time that the...
View ArticleDealing with exponents that contain units?
Many of the equations I deal with involve powers of quantities which contain units. However, when the exponent contains units (e.g., E^Quantity[3, "Joules"]), Mathematica will not evaluate it "fully."...
View ArticleToPolarCoordinates not working with units
I am trying to convert some quantities with units from rectangular to polar coordinates (to get the magnitude and angle). It seems that ToPolarCoordinates command does not calculate the angle when...
View ArticleHow can the units of the "AtomCoordinates" in a Molecule be changed while...
Mathematica provides the Molecule function that can be visualized with MoleculePlot3D since version 12.0. Before, importing "XYZ" files would produce a Graphics3D object immediately. In this object,...
View Articlequantity of `Around` with "DimensionlessUnit"
Quantity[1, "DimensionlessUnit"]gives pure number1However,Quantity[Around[1, 0.1], "DimensionlessUnit"]still givesQuantity[Around[0.01`, 0.001`], "DimensionlessUnit"]instead of pure Around expression....
View Article