Open cousteaulecommandant opened 14 years ago
Attachment: trac_9778_latex_prefixes_units.patch.gz
Adds LaTeX
symbols and SI
prefixes to the units module
Is the "todo" necessary, or could it be postponed to another ticket?
Well, latexdict
only contains a few units (10) and prefixes (5) so that it worked as an example; it would need to be completed with the names of all SI units and prefixes, at least for the LaTeX representation part.
By the way, I made this patch 2 years ago so I remember pretty little of it.
This supersedes #9759.
If someone wanted to complete this, they'd just have to make sure they implemented all the SI units etc. that Sage supports (see the 'todo' above).
Changed keywords from latex, SI prefixes, units to latex, SI prefixes, units, sd40.5
Since maybe the developers are reluctant to implement the "metrology" module I submitted in #9763, when there's already a "units" module that has the same purpose, I'm trying to port the
LaTeX
capabilities to the already existing "units" module.TO DO: Complete the latexdict list of units and
LaTeX
representation (if a unit isn't there, its symbol will be replaced by its name)Also, I'm implementing an easier way to use
SI
prefixes on the units module. The patch I submitted in #9759 wasn't very intuitive (you had to type "units.length.meter.kilo"), partly because I didn't know very well how did that module work. This new version allows you to simply type "units.length.kilometer" (even if it's not tab-completed) and it will do the rest.CC: @williamstein @eviatarbach
Component: symbolics
Keywords: latex, SI prefixes, units, sd40.5
Author: Javier Mora
Issue created by migration from https://trac.sagemath.org/ticket/9778