ويكي الجامعة
arwikiversity
https://ar.wikiversity.org/wiki/%D8%A7%D9%84%D8%B5%D9%81%D8%AD%D8%A9_%D8%A7%D9%84%D8%B1%D8%A6%D9%8A%D8%B3%D9%8A%D8%A9
MediaWiki 1.39.0-wmf.23
first-letter
ميديا
خاص
نقاش
مستخدم
نقاش المستخدم
ويكي الجامعة
نقاش ويكي الجامعة
ملف
نقاش الملف
ميدياويكي
نقاش ميدياويكي
قالب
نقاش القالب
مساعدة
نقاش المساعدة
تصنيف
نقاش التصنيف
مدرسة
نقاش المدرسة
بوابة
نقاش البوابة
موضوع
نقاش الموضوع
مجموعة
نقاش المجموعة
TimedText
TimedText talk
وحدة
نقاش الوحدة
إضافة
نقاش الإضافة
تعريف الإضافة
نقاش تعريف الإضافة
موضوع
التناقص الإشعاعي/التناقص الإشعاعي
0
28388
118022
118020
2022-08-10T19:16:30Z
ForzaGreen
14525
/* قانون التناقص الإشعاعي */
wikitext
text/x-wiki
__فهرس__
== التناقص الإشعاعي ==
=== الصبغة العشوائية للنشاط الإشعاعي ===
{{خاصية|محتوى=النشاط الإشعاعي ظاهرة عشوائية تحدث تلقائيا، إذ لا يمكن التنبؤ باللحظة التي يحدث فيها التفتت ولا يمكن تغيير خاصيات هذه الظاهرة.|عنوان=خاصية|عرض=70%|align=right}}
إن الدراسة الإحصائية لهذه الظاهرة العشوائية، تُمَكِّن من التنبؤ بالتطور الزمني لعينة تحتوي على عدد كبير من النوى المشعة.
وتخضع هذه العينة لقانون إحصائي يسمى قانون التناقص الإشعاعي.
=== قانون التناقص الإشعاعي ===
نعتبر عينة تحتوي على <math>N_0</math> من النوى المشعة في اللحظة <math>t=0</math> ، ونعتبر <math>N(t)</math> عدد النوى التي لم تتفتت بعد في اللحظة <math>t</math> ، أي النوى المتبقية في العينة.
<math>N(t) + \mathrm{d}N(t)</math> هو عدد النى المتبقة في العينة عند اللحظة <math>t + \mathrm{d}t</math> .
<math>\mathrm{d}N(t) < 0</math> لأن <math>N(t)</math> يتناقص.
عدد النوى المتفتتة بين اللحظتين <math>t</math> و <math>t + \mathrm{d}t</math> هو: <math>N(t) - (N(t) + \mathrm{d}N(t)) = -\mathrm{d}N(t)</math>
تبين الدراسة الإحصائية لعينة أن عدد النوى المتفتتة <math>-\mathrm{d}N(t)</math> يتناسب مع:
* <math>N(t)</math> عدد النوى المتبقية في العينة (لم تشع بعد)
* <math>\mathrm{d}t</math> المدة الزمنية
ويُعبر عن هذا رياضيا بالعلاقة: <math>-\mathrm{d}N(t) = \lambda N(t) \mathrm{d}t</math>
ويُمكن كتابة هذه العلاقة كالتالي: <math>\frac{\mathrm{d}N(t)}{N(t)} = -\lambda \mathrm{d}t</math>
وهي معادلة تفاضلية من الدرجة الأولى حلها يُكتب على شكل: <math>N(t) = K e^{-\lambda t}</math>
تُحدد الثابتة <math>K</math> حسب الشروط البدئية: <math>N(t=0)=N_0=K</math>
الجداء <math>\lambda t</math> لا بُعْد له <math>\left( [\lambda ] = \frac{1}{[t]} \right)</math> ، وبالتالي فإن وحدة <math>\lambda</math> هي {{Val|ul=s-1}}
=== ثابتة الزمن - عمر النصف ===
{{ تطوير مقالة }}
=== نشاط عينة مشعة ===
{{ تطوير مقالة }}
{{
ذيل الصفحة
|الرئيسية={{#titleparts: {{ FULLPAGENAME }} | 1 }}
|السابق=التناقص الإشعاعي/التحولات النووية التلقائية - النشاط الإشعاعي
|التالي=التناقص الإشعاعي/التأريخ بالنشاط الإشعاعي}}
[[تصنيف:علم الفيزياء الذرية]]
[[تصنيف:كلية علوم الفيزياء]]
k6kfikmz8yqb374n2kksdefh2h0skpz
118023
118022
2022-08-10T19:23:15Z
ForzaGreen
14525
/* قانون التناقص الإشعاعي */
wikitext
text/x-wiki
__فهرس__
== التناقص الإشعاعي ==
=== الصبغة العشوائية للنشاط الإشعاعي ===
{{خاصية|محتوى=النشاط الإشعاعي ظاهرة عشوائية تحدث تلقائيا، إذ لا يمكن التنبؤ باللحظة التي يحدث فيها التفتت ولا يمكن تغيير خاصيات هذه الظاهرة.|عنوان=خاصية|عرض=70%|align=right}}
إن الدراسة الإحصائية لهذه الظاهرة العشوائية، تُمَكِّن من التنبؤ بالتطور الزمني لعينة تحتوي على عدد كبير من النوى المشعة.
وتخضع هذه العينة لقانون إحصائي يسمى قانون التناقص الإشعاعي.
=== قانون التناقص الإشعاعي ===
نعتبر عينة تحتوي على <math>N_0</math> من النوى المشعة في اللحظة <math>t=0</math> ، ونعتبر <math>N(t)</math> عدد النوى التي لم تتفتت بعد في اللحظة <math>t</math> ، أي النوى المتبقية في العينة.
<math>N(t) + \mathrm{d}N(t)</math> هو عدد النى المتبقة في العينة عند اللحظة <math>t + \mathrm{d}t</math> .
<math>\mathrm{d}N(t) < 0</math> لأن <math>N(t)</math> يتناقص.
عدد النوى المتفتتة بين اللحظتين <math>t</math> و <math>t + \mathrm{d}t</math> هو: <math>N(t) - (N(t) + \mathrm{d}N(t)) = -\mathrm{d}N(t)</math>
تبين الدراسة الإحصائية لعينة أن عدد النوى المتفتتة <math>-\mathrm{d}N(t)</math> يتناسب مع:
* <math>N(t)</math> عدد النوى المتبقية في العينة (لم تشع بعد)
* <math>\mathrm{d}t</math> المدة الزمنية
ويُعبر عن هذا رياضيا بالعلاقة: <math>-\mathrm{d}N(t) = \lambda N(t) \mathrm{d}t</math>
ويُمكن كتابة هذه العلاقة كالتالي: <math>\frac{\mathrm{d}N(t)}{N(t)} = -\lambda \mathrm{d}t</math>
وهي معادلة تفاضلية من الدرجة الأولى حلها يُكتب على شكل: <math>N(t) = K e^{-\lambda t}</math>
تُحدد الثابتة <math>K</math> حسب الشروط البدئية: <math>N(t=0)=N_0=K</math>
الجداء <math>\lambda t</math> لا بُعْد له <math>\left( [\lambda ] = \frac{1}{[t]} \right)</math> ، وبالتالي فإن وحدة <math>\lambda</math> هي {{Val|ul=s-1}}
{{مبرهنة|محتوى=
يخضع <math>N(t)</math> عدد النوى المتبقية في عينة مشعة لقانون التناقص الإشعاعي التالي:
{{Equation box 1|equation=<math>N(t) = N_0 e^{-\lambda t}</math>|border colour=black|background colour=white}}
<math>\lambda</math> تُسمى ثابتة النشاط الإشعاعي، أو ثابتة التفتت، وهي تُميز طبيعة النويدة المشعة. و<math>N_0</math> عدد النوى في اللحظة <math>t=0</math>
|عنوان=قانون التناقص الإشعاعي|عرض=70%|align=right}}
=== ثابتة الزمن - عمر النصف ===
{{ تطوير مقالة }}
=== نشاط عينة مشعة ===
{{ تطوير مقالة }}
{{
ذيل الصفحة
|الرئيسية={{#titleparts: {{ FULLPAGENAME }} | 1 }}
|السابق=التناقص الإشعاعي/التحولات النووية التلقائية - النشاط الإشعاعي
|التالي=التناقص الإشعاعي/التأريخ بالنشاط الإشعاعي}}
[[تصنيف:علم الفيزياء الذرية]]
[[تصنيف:كلية علوم الفيزياء]]
1b0d7i36eovsjh9mib2ghg66fd9d8du
118024
118023
2022-08-10T19:26:49Z
ForzaGreen
14525
/* ثابتة الزمن - عمر النصف */
wikitext
text/x-wiki
__فهرس__
== التناقص الإشعاعي ==
=== الصبغة العشوائية للنشاط الإشعاعي ===
{{خاصية|محتوى=النشاط الإشعاعي ظاهرة عشوائية تحدث تلقائيا، إذ لا يمكن التنبؤ باللحظة التي يحدث فيها التفتت ولا يمكن تغيير خاصيات هذه الظاهرة.|عنوان=خاصية|عرض=70%|align=right}}
إن الدراسة الإحصائية لهذه الظاهرة العشوائية، تُمَكِّن من التنبؤ بالتطور الزمني لعينة تحتوي على عدد كبير من النوى المشعة.
وتخضع هذه العينة لقانون إحصائي يسمى قانون التناقص الإشعاعي.
=== قانون التناقص الإشعاعي ===
نعتبر عينة تحتوي على <math>N_0</math> من النوى المشعة في اللحظة <math>t=0</math> ، ونعتبر <math>N(t)</math> عدد النوى التي لم تتفتت بعد في اللحظة <math>t</math> ، أي النوى المتبقية في العينة.
<math>N(t) + \mathrm{d}N(t)</math> هو عدد النى المتبقة في العينة عند اللحظة <math>t + \mathrm{d}t</math> .
<math>\mathrm{d}N(t) < 0</math> لأن <math>N(t)</math> يتناقص.
عدد النوى المتفتتة بين اللحظتين <math>t</math> و <math>t + \mathrm{d}t</math> هو: <math>N(t) - (N(t) + \mathrm{d}N(t)) = -\mathrm{d}N(t)</math>
تبين الدراسة الإحصائية لعينة أن عدد النوى المتفتتة <math>-\mathrm{d}N(t)</math> يتناسب مع:
* <math>N(t)</math> عدد النوى المتبقية في العينة (لم تشع بعد)
* <math>\mathrm{d}t</math> المدة الزمنية
ويُعبر عن هذا رياضيا بالعلاقة: <math>-\mathrm{d}N(t) = \lambda N(t) \mathrm{d}t</math>
ويُمكن كتابة هذه العلاقة كالتالي: <math>\frac{\mathrm{d}N(t)}{N(t)} = -\lambda \mathrm{d}t</math>
وهي معادلة تفاضلية من الدرجة الأولى حلها يُكتب على شكل: <math>N(t) = K e^{-\lambda t}</math>
تُحدد الثابتة <math>K</math> حسب الشروط البدئية: <math>N(t=0)=N_0=K</math>
الجداء <math>\lambda t</math> لا بُعْد له <math>\left( [\lambda ] = \frac{1}{[t]} \right)</math> ، وبالتالي فإن وحدة <math>\lambda</math> هي {{Val|ul=s-1}}
{{مبرهنة|محتوى=
يخضع <math>N(t)</math> عدد النوى المتبقية في عينة مشعة لقانون التناقص الإشعاعي التالي:
{{Equation box 1|equation=<math>N(t) = N_0 e^{-\lambda t}</math>|border colour=black|background colour=white}}
<math>\lambda</math> تُسمى '''ثابتة النشاط الإشعاعي'''، أو '''ثابتة التفتت'''، وهي تُميز طبيعة النويدة المشعة. و<math>N_0</math> عدد النوى في اللحظة <math>t=0</math>
|عنوان=قانون التناقص الإشعاعي|عرض=70%|align=right}}
=== ثابتة الزمن - عمر النصف ===
==== ثابتة الزمن <math>\tau</math> ====
{{تعريف|محتوى=تمكن|عنوان=تعريف|عرض=70%|align=right}}
تُ
==== عمر النصف <math>t_{1/2}</math> لنويدة مشعة ====
=== نشاط عينة مشعة ===
{{ تطوير مقالة }}
{{
ذيل الصفحة
|الرئيسية={{#titleparts: {{ FULLPAGENAME }} | 1 }}
|السابق=التناقص الإشعاعي/التحولات النووية التلقائية - النشاط الإشعاعي
|التالي=التناقص الإشعاعي/التأريخ بالنشاط الإشعاعي}}
[[تصنيف:علم الفيزياء الذرية]]
[[تصنيف:كلية علوم الفيزياء]]
jfdbqaw1w63hg0ubors0q35hw265dps
118032
118024
2022-08-10T21:11:16Z
ForzaGreen
14525
s-1
wikitext
text/x-wiki
__فهرس__
== التناقص الإشعاعي ==
=== الصبغة العشوائية للنشاط الإشعاعي ===
{{خاصية|محتوى=النشاط الإشعاعي ظاهرة عشوائية تحدث تلقائيا، إذ لا يمكن التنبؤ باللحظة التي يحدث فيها التفتت ولا يمكن تغيير خاصيات هذه الظاهرة.|عنوان=خاصية|عرض=70%|align=right}}
إن الدراسة الإحصائية لهذه الظاهرة العشوائية، تُمَكِّن من التنبؤ بالتطور الزمني لعينة تحتوي على عدد كبير من النوى المشعة.
وتخضع هذه العينة لقانون إحصائي يسمى قانون التناقص الإشعاعي.
=== قانون التناقص الإشعاعي ===
نعتبر عينة تحتوي على <math>N_0</math> من النوى المشعة في اللحظة <math>t=0</math> ، ونعتبر <math>N(t)</math> عدد النوى التي لم تتفتت بعد في اللحظة <math>t</math> ، أي النوى المتبقية في العينة.
<math>N(t) + \mathrm{d}N(t)</math> هو عدد النى المتبقة في العينة عند اللحظة <math>t + \mathrm{d}t</math> .
<math>\mathrm{d}N(t) < 0</math> لأن <math>N(t)</math> يتناقص.
عدد النوى المتفتتة بين اللحظتين <math>t</math> و <math>t + \mathrm{d}t</math> هو: <math>N(t) - (N(t) + \mathrm{d}N(t)) = -\mathrm{d}N(t)</math>
تبين الدراسة الإحصائية لعينة أن عدد النوى المتفتتة <math>-\mathrm{d}N(t)</math> يتناسب مع:
* <math>N(t)</math> عدد النوى المتبقية في العينة (لم تشع بعد)
* <math>\mathrm{d}t</math> المدة الزمنية
ويُعبر عن هذا رياضيا بالعلاقة: <math>-\mathrm{d}N(t) = \lambda N(t) \mathrm{d}t</math>
ويُمكن كتابة هذه العلاقة كالتالي: <math>\frac{\mathrm{d}N(t)}{N(t)} = -\lambda \mathrm{d}t</math>
وهي معادلة تفاضلية من الدرجة الأولى حلها يُكتب على شكل: <math>N(t) = K e^{-\lambda t}</math>
تُحدد الثابتة <math>K</math> حسب الشروط البدئية: <math>N(t=0)=N_0=K</math>
الجداء <math>\lambda t</math> لا بُعْد له <math>\left( [\lambda ] = \frac{1}{[t]} \right)</math> ، وبالتالي فإن وحدة <math>\lambda</math> هي {{Val|u=s-1}}
{{مبرهنة|محتوى=
يخضع <math>N(t)</math> عدد النوى المتبقية في عينة مشعة لقانون التناقص الإشعاعي التالي:
{{Equation box 1|equation=<math>N(t) = N_0 e^{-\lambda t}</math>|border colour=black|background colour=white}}
<math>\lambda</math> تُسمى '''ثابتة النشاط الإشعاعي'''، أو '''ثابتة التفتت'''، وهي تُميز طبيعة النويدة المشعة. و<math>N_0</math> عدد النوى في اللحظة <math>t=0</math>
|عنوان=قانون التناقص الإشعاعي|عرض=70%|align=right}}
=== ثابتة الزمن - عمر النصف ===
==== ثابتة الزمن <math>\tau</math> ====
{{تعريف|محتوى=تمكن|عنوان=تعريف|عرض=70%|align=right}}
تُ
==== عمر النصف <math>t_{1/2}</math> لنويدة مشعة ====
=== نشاط عينة مشعة ===
{{ تطوير مقالة }}
{{
ذيل الصفحة
|الرئيسية={{#titleparts: {{ FULLPAGENAME }} | 1 }}
|السابق=التناقص الإشعاعي/التحولات النووية التلقائية - النشاط الإشعاعي
|التالي=التناقص الإشعاعي/التأريخ بالنشاط الإشعاعي}}
[[تصنيف:علم الفيزياء الذرية]]
[[تصنيف:كلية علوم الفيزياء]]
7pdyuvc98795k9eyjy1w4udcsu4aobf
وحدة:Convert/data
828
28894
118021
2022-08-10T19:14:47Z
ForzaGreen
14525
أنشأ الصفحة ب'-- Conversion data used by [[Module:Convert]] which uses mw.loadData() for -- read-only access to this module so that it is loaded only once per page. -- See [[:en:Template:Convert/Transwiki guide]] if copying to another wiki. -- -- These data tables follow: -- all_units all properties for a unit, including default output -- default_exceptions exceptions for default output ('kg' and 'g' have different defaults) -- link_exceptions exceptions for...'
Scribunto
text/plain
-- Conversion data used by [[Module:Convert]] which uses mw.loadData() for
-- read-only access to this module so that it is loaded only once per page.
-- See [[:en:Template:Convert/Transwiki guide]] if copying to another wiki.
--
-- These data tables follow:
-- all_units all properties for a unit, including default output
-- default_exceptions exceptions for default output ('kg' and 'g' have different defaults)
-- link_exceptions exceptions for links ('kg' and 'g' have different links)
--
-- These tables are generated by a script which reads the wikitext of a page that
-- documents the required properties of each unit; see [[:en:Module:Convert/doc]].
---------------------------------------------------------------------------
-- Do not change the data in this table because it is created by running --
-- a script that reads the wikitext from a wiki page (see note above). --
---------------------------------------------------------------------------
local all_units = {
["Gy"] = {
_name1 = "جراي",
_name1_us= "Gray",
_symbol = "جراي",
_sym_us = "Gy",
utype = "absorbed radiation dose",
scale = 1,
prefixes = 1,
default = "rad",
link = "جراي (وحدة)",
},
["rad"] = {
_name1 = "راد",
_name1_us= "Rad",
_symbol = "ر",
_sym_us = "rad",
utype = "absorbed radiation dose",
scale = 0.01,
prefixes = 1,
default = "Gy",
link = "راد (وحدة)",
},
["cm/s2"] = {
name1 = "سنتيمتر لكل ثانية مربعة",
name2 = "سنتيمتر لكل ثانية مربعة",
name2_us = "centimeters per second squared",
symbol = "سم/ث<sup>2</sup>",
sym_us = "cm/s<sup>2</sup>",
utype = "acceleration",
scale = 0.01,
default = "ft/s2",
link = "غال (وحدة)",
},
["ft/s2"] = {
name1 = "قدم لكل ثانية مربعة",
name2 = "قدم لكل ثانية مربعة",
symbol = "قدم/ث<sup>2</sup>",
sym_us = "ft/s<sup>2</sup>",
utype = "acceleration",
scale = 0.3048,
default = "m/s2",
},
["g0"] = {
name1 = "standard gravity",
name2 = "standard gravities",
symbol = "''g<sub>0</sub>''",
utype = "acceleration",
scale = 9.80665,
default = "m/s2",
link = "جاذبية معيارية",
},
["km/hs"] = {
name1 = "كيلومتر في الساعة في الثانية",
name2 = "كيلومتر في الساعة في الثانية",
name2_us = "kilometers per hour per second",
symbol = "كم/(س·ث)",
sym_us = "km/(h·s)",
utype = "acceleration",
scale = 0.27777777777777779,
default = "mph/s",
link = "تسارع",
},
["km/s2"] = {
name1 = "كيلومتر في الثانية المربعة",
name2 = "كيلومتر في الثانية المربعة",
name2_us = "kilometers per second squared",
symbol = "كم/ث<sup>2</sup>",
sym_us = "km/s<sup>2</sup>",
utype = "acceleration",
scale = 1000,
default = "mph/s",
link = "تسارع",
},
["m/s2"] = {
name1 = "متر في الثانية المربعة",
name2 = "متر في الثانية المربعة",
name2_us = "meters per second squared",
symbol = "م/ث<sup>2</sup>",
sym_us = "m/s<sup>2</sup>",
utype = "acceleration",
scale = 1,
default = "ft/s2",
},
["mph/s"] = {
name1 = "ميل في الساعة في الثانية",
name2 = "ميل في الساعة في الثانية",
symbol = "ميل.س/ث",
sym_us = "mph/s",
utype = "acceleration",
scale = 0.44704,
default = "km/hs",
link = "تسارع",
},
["km/h/s"] = {
target = "km/hs",
},
["standard gravity"] = {
target = "g0",
},
["1000sqft"] = {
name1 = "ألف قدم مربع",
symbol = "1000قدم<sup>2</sup>",
sym_us = "1000sqft",
utype = "area",
scale = 92.90304,
default = "m2",
link = "قدم مربع",
},
["a"] = {
_name1 = "آر",
_symbol = "آر",
_sym_us = "a",
utype = "area",
scale = 100,
prefixes = 1,
default = "sqft",
link = "آر (وحدة)",
},
["acre"] = {
name1 = "أكر",
symbol = "acre",
sym_us = "~acre",
usename = 1,
utype = "area",
scale = 4046.8564224,
default = "ha",
subdivs = { ["rood"] = { 4, default = "ha" }, ["sqperch"] = { 160, default = "ha" } },
},
["acre-sing"] = {
target = "acre",
},
["arpent"] = {
name1 = "أربنت",
name1_us = "arpent",
symbol = "arpent",
sym_us = "~arpent",
usename = 1,
utype = "area",
scale = 3418.89,
default = "ha",
},
["cda"] = {
symbol = "حبل",
utype = "area",
scale = 3930.395625,
default = "acre ha",
},
["daa"] = {
name1 = "ديكار",
name1_us = "decare",
symbol = "دا.ها",
sym_us = "daa",
utype = "area",
scale = 1000,
default = "km2 sqmi",
link = "هكتار",
},
["dunam"] = {
name1 = "دونم",
symbol = "dunam",
sym_us = "~dunam",
usename = 1,
utype = "area",
scale = 1000,
default = "km2 sqmi",
},
["dunum"] = {
name1 = "دونم",
symbol = "dunum",
sym_us = "~dunum",
usename = 1,
utype = "area",
scale = 1000,
default = "km2 sqmi",
},
["ha"] = {
name1 = "هكتار",
symbol = "ها",
sym_us = "ha",
utype = "area",
scale = 10000,
default = "acre",
},
["hectare"] = {
name1 = "هكتار",
symbol = "ha",
sym_us = "~ha",
usename = 1,
utype = "area",
scale = 10000,
default = "acre",
},
["Irish acre"] = {
name1_us = "Irish acre",
symbol = "أكر إيرلندي",
sym_us = "Irish acres",
utype = "area",
scale = 6555.2385024,
default = "ha",
link = "Acre (Irish)",
},
["m2"] = {
_name1 = "متر مربع",
_symbol = "م<sup>2</sup>",
_sym_us = "m<sup>2</sup>",
utype = "area",
scale = 1,
prefixes = 2,
default = "sqft",
link = "متر مربع",
},
["pondemaat"] = {
name1_us = "pondemaat",
name2_us = "pondemaat",
symbol = "pond",
utype = "area",
scale = 3674.363358816,
default = "m2",
link = ":nl:pondemaat",
},
["pyeong"] = {
name1 = "بيونغ",
symbol = "pyeong",
sym_us = "~pyeong",
usename = 1,
utype = "area",
scale = 3.3057851239669422,
default = "m2",
},
["rai"] = {
name2 = "rai",
symbol = "rai",
utype = "area",
scale = 1600,
default = "m2",
link = "Rai (unit)",
},
["rood"] = {
symbol = "rood",
sym_us = "~rood",
usename = 1,
utype = "area",
scale = 1011.7141056,
default = "sqft sqm",
subdivs = { ["sqperch"] = { 40, default = "m2" } },
link = "Rood (unit)",
},
["sqfoot"] = {
name1 = "قدم مربع",
symbol = "قدم<sup>2</sup>",
utype = "area",
scale = 0.09290304,
default = "m2",
},
["sqft"] = {
name1 = "قدم مربع",
symbol = "قدم<sup>2</sup>",
utype = "area",
scale = 0.09290304,
default = "m2",
},
["sqin"] = {
name1 = "بوصة مربعة",
symbol = "بوصة<sup>2</sup>",
utype = "area",
scale = 0.00064516,
default = "cm2",
},
["sqmi"] = {
name1 = "ميل مربع",
symbol = "ميل<sup>2</sup>",
utype = "area",
scale = 2589988.110336,
default = "km2",
},
["sqnmi"] = {
name1 = "ميل بحري مربع",
symbol = "sq nmi",
utype = "area",
scale = 3429904,
default = "km2 sqmi",
link = "ميل بحري",
},
["sqperch"] = {
name1 = "قصبة",
symbol = "perch",
sym_us = "~perch",
usename = 1,
utype = "area",
scale = 25.29285264,
default = "sqm",
link = "قصبة (وحدة قياس)",
},
["sqverst"] = {
name1 = "فرستا مربعة",
symbol = "square verst",
sym_us = "~square verst",
usename = 1,
utype = "area",
scale = 1138062.24,
default = "km2 sqmi",
link = "فرستا (وحدة قياس)",
},
["sqyd"] = {
name1 = "ياردة مربعة",
symbol = "ياردة<sup>2</sup>",
sym_us = "sqyd",
utype = "area",
scale = 0.83612736,
default = "m2",
},
["tsubo"] = {
name1 = "توسبو",
symbol = "tsubo",
sym_us = "~tsubo",
usename = 1,
utype = "area",
scale = 3.3057851239669422,
default = "m2",
link = "Japanese units of measurement#Area",
},
["Cypriot donum"] = {
name1 = "دونم",
symbol = "donum",
sym_us = "~donum",
usename = 1,
utype = "area",
scale = 1337.803776,
default = "km2 sqmi",
},
["Cypriot dunam"] = {
name1 = "دونم",
symbol = "dunam",
sym_us = "~dunam",
usename = 1,
utype = "area",
scale = 1337.803776,
default = "km2 sqmi",
},
["Cypriot dunum"] = {
name1 = "دونم",
symbol = "dunum",
sym_us = "~dunum",
usename = 1,
utype = "area",
scale = 1337.803776,
default = "km2 sqmi",
},
["Cypriot dönüm"] = {
name1 = "دونم",
symbol = "dönüm",
sym_us = "~dönüm",
usename = 1,
utype = "area",
scale = 1337.803776,
default = "km2 sqmi",
},
["Libn"] = {
symbol = "لبنة",
sym_us = "Libn",
utype = "area",
scale = 44.44,
default = "m2",
link = "لبنة (مساحة)",
},
["لبنة"] = {
target = "Libn",
},
["Feddan"] = {
symbol = "فدان",
sym_us = "Feddan",
utype = "area",
scale = 4200.83,
default = "m2",
},
["فدان"] = {
target = "Feddan",
},
["Mead"] = {
symbol = "معاد",
sym_us = "Mead",
utype = "area",
scale = 4444,
default = "m2",
link = "معاد (مساحة)",
},
["donum"] = {
name1 = "دونم",
symbol = "donum",
sym_us = "~donum",
usename = 1,
utype = "area",
scale = 1000,
default = "km2 sqmi",
},
["dönüm"] = {
name1 = "دونم",
symbol = "dönüm",
sym_us = "~donum",
usename = 1,
utype = "area",
scale = 1000,
default = "km2 sqmi",
},
["Iraqi donum"] = {
name1 = "دونم",
symbol = "donum",
sym_us = "~donum",
usename = 1,
utype = "area",
scale = 2500,
default = "km2 sqmi",
},
["Iraqi dunam"] = {
name1 = "دونم",
symbol = "dunam",
sym_us = "~dunam",
usename = 1,
utype = "area",
scale = 2500,
default = "km2 sqmi",
},
["Iraqi dunum"] = {
name1 = "دونم",
symbol = "dunum",
sym_us = "~dunum",
usename = 1,
utype = "area",
scale = 2500,
default = "km2 sqmi",
},
["Iraqi dönüm"] = {
name1 = "دونم",
symbol = "dönüm",
sym_us = "~dönüm",
usename = 1,
utype = "area",
scale = 2500,
default = "km2 sqmi",
},
["old donum"] = {
name1 = "دونم",
symbol = "donum",
sym_us = "~donum",
usename = 1,
utype = "area",
scale = 919.3,
default = "km2 sqmi",
},
["old dunam"] = {
name1 = "دونم",
symbol = "dunam",
sym_us = "~dunam",
usename = 1,
utype = "area",
scale = 919.3,
default = "km2 sqmi",
},
["old dunum"] = {
name1 = "دونم",
symbol = "dunum",
sym_us = "~dunum",
usename = 1,
utype = "area",
scale = 919.3,
default = "km2 sqmi",
},
["old dönüm"] = {
name1 = "دونم",
symbol = "dönüm",
sym_us = "~dönüm",
usename = 1,
utype = "area",
scale = 919.3,
default = "km2 sqmi",
},
["معاد"] = {
target = "Mead",
},
["acres"] = {
target = "acre",
},
["أكر"] = {
target = "acre",
},
["are"] = {
target = "a",
},
["Cypriot donum diaeresis"] = {
target = "Cypriot dönüm",
},
["Cypriot donum dots"] = {
target = "Cypriot dönüm",
},
["decare"] = {
target = "daa",
},
["donum diaeresis"] = {
target = "dönüm",
},
["donum dots"] = {
target = "dönüm",
},
["foot2"] = {
target = "sqfoot",
},
["قدم2"] = {
target = "sqfoot",
},
["ft2"] = {
target = "sqft",
},
["in2"] = {
target = "sqin",
},
["Iraqi donum diaeresis"] = {
target = "Iraqi dönüm",
},
["Iraqi donum dots"] = {
target = "Iraqi dönüm",
},
["km²"] = {
target = "km2",
},
["كم2"] = {
target = "km2",
},
["metric donum"] = {
target = "donum",
},
["metric donum diaeresis"] = {
target = "dönüm",
},
["metric donum dots"] = {
target = "dönüm",
},
["metric dunam"] = {
target = "dunam",
},
["metric dönüm"] = {
target = "dönüm",
},
["mi2"] = {
target = "sqmi",
},
["ميل2"] = {
target = "sqmi",
},
["million acre"] = {
target = "e6acre",
},
["million acres"] = {
target = "e6acre",
},
["million hectares"] = {
target = "e6ha",
},
["m²"] = {
target = "m2",
},
["م²"] = {
target = "m2",
},
["م2"] = {
target = "m2",
},
["nmi2"] = {
target = "sqnmi",
},
["old donum diaeresis"] = {
target = "old dönüm",
},
["old donum dots"] = {
target = "old dönüm",
},
["pond"] = {
target = "pondemaat",
},
["sq arp"] = {
target = "arpent",
},
["sqkm"] = {
target = "km2",
},
["sqm"] = {
target = "m2",
},
["square verst"] = {
target = "sqverst",
},
["verst2"] = {
target = "sqverst",
},
["yd2"] = {
target = "sqyd",
},
["ياردة2"] = {
target = "sqyd",
},
["m2/ha"] = {
name1 = "متر مربع لكل هكتار",
name2 = "متر مربع لكل هكتار",
name2_us = "square meters per hectare",
symbol = "م<sup>2</sup>/هكتار",
utype = "area per unit area",
scale = 0.0001,
default = "sqft/acre",
link = "Basal area",
},
["sqft/acre"] = {
name1 = "قدم مربع لكل فدان",
name2 = "قدم مربع لكل فدان",
symbol = "قدم<sup>2</sup>/هكتار",
utype = "area per unit area",
scale = 2.295684113865932e-5,
default = "m2/ha",
},
["cent"] = {
name1 = "سنت",
symbol = "¢",
utype = "cent",
scale = 1,
default = "cent",
link = "سنت (عملة)",
},
["¢"] = {
target = "cent",
},
["A.h"] = {
name1 = "أمبير-ساعة",
name2 = "أمبير-ساعة",
symbol = "أ.س",
sym_us = "A.h",
utype = "charge",
scale = 3600,
default = "coulomb",
},
["coulomb"] = {
_name1 = "كولوم",
_name2 = "كولوم",
_symbol = "كل",
_sym_us = "C",
utype = "charge",
scale = 1,
prefixes = 1,
default = "e",
link = "كولوم",
},
["e"] = {
name1 = "شحنة أولية",
name2 = "شحنة أولية",
symbol = "''ش<sub>e</sub>''",
sym_us = "''<sub>e</sub>''",
utype = "charge",
scale = 1.602176487e-19,
default = "coulomb",
},
["A·h"] = {
target = "A.h",
},
["g-mol"] = {
name1 = "غرام مول",
symbol = "غ-مول",
utype = "chemical amount",
scale = 1,
default = "lbmol",
link = "مول",
},
["gmol"] = {
name1 = "جرام مول",
symbol = "غ.مول",
utype = "chemical amount",
scale = 1,
default = "lbmol",
link = "مول",
},
["kmol"] = {
name1 = "كيلومول",
symbol = "ك.مول",
utype = "chemical amount",
scale = 1000,
default = "lbmol",
link = "مول",
},
["lb-mol"] = {
name1 = "رطل-مول",
symbol = "lb-mol",
utype = "chemical amount",
scale = 453.59237,
default = "mol",
link = "مول",
},
["lbmol"] = {
name1 = "رطل-مول",
symbol = "lbmol",
utype = "chemical amount",
scale = 453.59237,
default = "mol",
link = "مول",
},
["mol"] = {
symbol = "مول",
utype = "chemical amount",
scale = 1,
default = "lbmol",
},
["kgCO2/L"] = {
name1 = "كيلوغرام لكل لتر",
name1_us = "kilogram per liter",
name2 = "كيلوغرام لكل لتر",
name2_us = "kilograms per liter",
symbol = "kg(CO<sub>2</sub>)/L",
utype = "co2 per unit volume",
scale = 1000,
default = "lbCO2/USgal",
link = "غاز عادم",
},
["lbCO2/USgal"] = {
name1_us = "pound per US gallon",
name2 = "رطل لكل جالون أمريكي",
symbol = "lbCO2/US gal",
utype = "co2 per unit volume",
scale = 119.82642731689663,
default = "kgCO2/L",
link = "غاز عادم",
},
["oz/lb"] = {
per = { "oz", "lb" },
utype = "concentration",
default = "mg/kg",
},
["mg/kg"] = {
per = { "mg", "kg" },
utype = "concentration",
default = "oz/lb",
},
["$/acre"] = {
per = { "$", "acre" },
utype = "cost $ per unit area",
default = "$/ha",
},
["$/ha"] = {
per = { "$", "ha" },
utype = "cost $ per unit area",
default = "$/acre",
},
["$/m2"] = {
per = { "$", "m2" },
utype = "cost $ per unit area",
default = "$/sqft",
},
["$/sqft"] = {
per = { "$", "sqft" },
utype = "cost $ per unit area",
default = "$/m2",
},
["$/km"] = {
per = { "$", "km" },
utype = "cost $ per unit length",
default = "$/mi",
},
["$/mi"] = {
per = { "$", "mi" },
utype = "cost $ per unit length",
default = "$/km",
},
["$/kg"] = {
per = { "$", "kg" },
utype = "cost $ per unit mass",
default = "$/lb",
},
["$/g"] = {
per = { "$", "g" },
utype = "cost $ per unit mass",
default = "$/lb",
},
["$/lb"] = {
per = { "$", "lb" },
utype = "cost $ per unit mass",
default = "$/kg",
},
["$/oz"] = {
per = { "$", "oz" },
utype = "cost $ per unit mass",
default = "$/g",
},
["$/ozt"] = {
per = { "$", "ozt" },
utype = "cost $ per unit mass",
default = "$/kg",
},
["$/m3"] = {
per = { "$", "m3" },
utype = "cost $ per unit volume",
default = "$/oilbbl",
},
["$/oilbbl"] = {
per = { "$", "oilbbl" },
utype = "cost $ per unit volume",
default = "$/m3",
},
["£/acre"] = {
per = { "£", "acre" },
utype = "cost £ per unit area",
default = "£/ha",
},
["£/ha"] = {
per = { "£", "ha" },
utype = "cost £ per unit area",
default = "£/acre",
},
["g/dm3"] = {
name1 = "غرام لكل ديسي متر مكعب",
name1_us = "grams per cubic decimeter",
name2 = "غرام لكل ديسي متر مكعب",
symbol = "غ/دم<sup>3</sup>",
sym_us = "g/dm<sup>3</sup>",
utype = "density",
scale = 1,
default = "kg/m3",
link = "كثافة",
},
["g/L"] = {
name1 = "غرام لكل لتر",
name1_us = "grams per liter",
name2 = "غرام لكل لتر",
symbol = "غ/ل",
sym_us = "g/L",
utype = "density",
scale = 1,
default = "lb/cuin",
link = "كثافة",
},
["g/mL"] = {
name1 = "غرام لكل مليلتر",
name1_us = "grams per milliliter",
name2 = "غرام لكل مليلتر",
symbol = "ج/مـل",
sym_us = "g/mL",
utype = "density",
scale = 1000,
default = "lb/cuin",
link = "كثافة",
},
["g/ml"] = {
name1 = "غرام لكل مليلتر",
name1_us = "grams per milliliter",
name2 = "غرام لكل مليلتر",
symbol = "ج/مـل",
sym_us = "g/ml",
utype = "density",
scale = 1000,
default = "lb/cuin",
link = "كثافة",
},
["kg/dm3"] = {
name1 = "كيلوغرام لكل ديسي متر مكعب",
name1_us = "kilograms per cubic decimeter",
name2 = "كيلوغرام لكل ديسي متر مكعب",
symbol = "كجم/دم<sup>3</sup>",
sym_us = "kg/dm<sup>3</sup>",
utype = "density",
scale = 1000,
default = "lb/cuft",
link = "كثافة",
},
["kg/L"] = {
name1 = "كيلوغرام لكل لتر",
name1_us = "kilograms per liter",
name2 = "كيلوغرام لكل لتر",
symbol = "كجم/ل",
sym_us = "kg/L",
utype = "density",
scale = 1000,
default = "lb/USgal",
link = "كثافة",
},
["kg/l"] = {
name1 = "كيلوغرام لكل لتر",
name1_us = "kilograms per liter",
name2 = "كيلوغرام لكل لتر",
symbol = "كجم/ل",
sym_us = "kg/l",
utype = "density",
scale = 1000,
default = "lb/USgal",
link = "كثافة",
},
["kg/m3"] = {
name1 = "كيلوغرام لكل متر مكعب",
name1_us = "kilograms per cubic meter",
name2 = "كيلوغرام لكل متر مكعب",
symbol = "كجم/م<sup>3</sup>",
sym_us = "kg/m<sup>3</sup>",
utype = "density",
scale = 1,
default = "lb/cuyd",
link = "كثافة",
},
["lb/cuft"] = {
name1 = "رطل لكل قدم مكعب",
name1_us = "pound per cubic foot",
name2 = "رطل لكل قدم مكعب",
symbol = "lb/cu ft",
utype = "density",
scale = 16.018463373960142,
default = "g/cm3",
link = "كثافة",
},
["lb/cuin"] = {
name1 = "رطل لكل بوصة مكعبة",
name2 = "رطل لكل بوصة مكعبة",
symbol = "lb/cu in",
utype = "density",
scale = 27679.904710203122,
default = "g/cm3",
link = "كثافة",
},
["lb/cuyd"] = {
name1 = "رطل لكل ياردة مربعة",
name1_us = "pound per cubic yard",
name2 = "رطل لكل ياردة مربعة",
symbol = "lb/cu yd",
utype = "density",
scale = 0.5932764212577829,
default = "kg/m3",
link = "كثافة",
},
["lb/impgal"] = {
name1 = "رطل لكل جالون إمبراطوري",
name1_us = "pound per imperial gallon",
name2 = "رطل لكل جالون إمبراطوري",
symbol = "lb/imp gal",
utype = "density",
scale = 99.776372663101697,
default = "kg/L",
link = "كثافة",
},
["lb/in3"] = {
name1 = "رطل لكل بوصة مكعبة",
name1_us = "pound per cubic inch",
name2 = "رطل لكل بوصة مكعبة",
symbol = "lb/cu&#thinsp;in",
utype = "density",
scale = 27679.904710203122,
default = "g/cm3",
link = "كثافة",
},
["lb/U.S.gal"] = {
name1 = "رطل لكل جالون أمريكي",
name1_us = "pound per U.S. gallon",
name2 = "رطل لكل جالون أمريكي",
symbol = "lb/U.S. gal",
utype = "density",
scale = 119.82642731689663,
default = "kg/L",
link = "كثافة",
},
["lb/USbu"] = {
name1 = "رطل لكل بوشل أمريكي",
name1_us = "pound per US bushel",
name2 = "رطل لكل بوشل أمريكي",
symbol = "lb/US bu",
utype = "density",
scale = 12.871859780974471,
default = "kg/m3",
link = "بوشل",
},
["lb/USgal"] = {
name1 = "رطل لكل جالون أمريكي",
name1_us = "pound per US gallon",
name2 = "رطل لكل جالون أمريكي",
symbol = "lb/US gal",
utype = "density",
scale = 119.82642731689663,
default = "kg/L",
link = "كثافة",
},
["lbm/cuin"] = {
name1_us = "pound mass per cubic inch",
symbol = "lbm/cu&#thinsp;in",
utype = "density",
scale = 27679.904710203122,
default = "g/cm3",
link = "كثافة",
},
["mg/L"] = {
name1 = "ملليغرام لكل لتر",
name1_us = "milligram per litre",
name2 = "ميلي غرام لكل لتر",
name2_us = "milligrams per liter",
symbol = "مـغ/ل",
sym_us = "mg/L",
utype = "density",
scale = 0.001,
default = "lb/cuin",
link = "كثافة",
},
["oz/cuin"] = {
name1 = "أوقية لكل بوصة مكعبة",
name1_us = "ounce per cubic inch",
name2 = "أوقية لكل بوصة مكعبة",
symbol = "أوقية/بوصة<sup>3</sup>",
sym_us = "oz/cu in",
utype = "density",
scale = 1729.9940443876951,
default = "g/cm3",
link = "كثافة",
},
["g/cm3"] = {
per = { "g", "cm3" },
utype = "density",
default = "lb/cuin",
},
["g/m3"] = {
per = { "g", "m3" },
utype = "density",
default = "lb/cuyd",
link = "كثافة",
},
["Mg/m3"] = {
per = { "Mg", "m3" },
utype = "density",
default = "lb/cuft",
},
["mg/l"] = {
per = { "mg", "l" },
utype = "density",
default = "oz/cuin",
},
["μg/dL"] = {
per = { "μg", "dL" },
utype = "density",
default = "lb/cuin",
},
["μg/l"] = {
per = { "μg", "l" },
utype = "density",
default = "oz/cuin",
},
["lb/ft3"] = {
target = "lb/cuft",
},
["غ/ل"] = {
target = "g/L",
},
["lb/yd3"] = {
target = "lb/cuyd",
},
["lbm/in3"] = {
target = "lbm/cuin",
},
["mcg/dL"] = {
target = "μg/dL",
},
["oz/in3"] = {
target = "oz/cuin",
},
["ug/dL"] = {
target = "μg/dL",
},
["ug/l"] = {
target = "μg/l",
},
["B.O.T.U."] = {
name1 = "Board of Trade Unit",
symbol = "B.O.T.U.",
utype = "energy",
scale = 3600000,
default = "MJ",
link = "كيلوواط ساعي",
},
["bboe"] = {
name1 = "برميل من مكافئ نفطي",
name1_us = "barrel of oil equivalent",
name2 = "barrels of oil equivalent",
symbol = "bboe",
utype = "energy",
scale = 6117863200,
default = "GJ",
link = "مكافئ برميل النفط",
},
["BOE"] = {
name1 = "برميل من مكافئ نفطي",
name1_us = "barrel of oil equivalent",
name2 = "barrels of oil equivalent",
symbol = "BOE",
utype = "energy",
scale = 6117863200,
default = "GJ",
link = "مكافئ برميل النفط",
},
["BTU"] = {
name1 = "وحدة حرارية بريطانية",
name1_us = "British thermal unit",
symbol = "و.ح.ب.",
sym_us = "BTU",
utype = "energy",
scale = 1055.05585262,
default = "kJ",
},
["Btu"] = {
name1 = "وحدة حرارية بريطانية",
name1_us = "British thermal unit",
symbol = "و.ح.ب.",
sym_us = "Btu",
utype = "energy",
scale = 1055.05585262,
default = "kJ",
},
["BTU-39F"] = {
name1 = "وحدة حرارية بريطانية (39°ف)",
symbol = "و.ح.ب.<sub>39°ف</sub>",
sym_us = "BTU<sub>39 °F</sub>",
utype = "energy",
scale = 1059.67,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Btu-39F"] = {
name1 = "وحدة حرارية بريطانية (39°ف)",
symbol = "و.ح.ب.<sub>39°ف</sub>",
sym_us = "Btu<sub>39 °F</sub>",
utype = "energy",
scale = 1059.67,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["BTU-59F"] = {
name1 = "وحدة حرارية بريطانية (59°ف)",
symbol = "و.ح.ب.<sub>59°ف</sub>",
sym_us = "BTU<sub>59 °F</sub>",
utype = "energy",
scale = 1054.804,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Btu-59F"] = {
name1 = "وحدة حرارية بريطانية (59°ف)",
symbol = "و.ح.ب.<sub>59°ف</sub>",
sym_us = "Btu<sub>59 °F</sub>",
utype = "energy",
scale = 1054.804,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["BTU-60F"] = {
name1 = "وحدة حرارية بريطانية (60°ف)",
symbol = "و.ح.ب.<sub>60°ف</sub>",
sym_us = "BTU<sub>60 °F</sub>",
utype = "energy",
scale = 1054.68,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Btu-60F"] = {
name1 = "وحدة حرارية بريطانية (60°ف)",
symbol = "و.ح.ب.<sub>60°ف</sub>",
sym_us = "Btu<sub>60 °F</sub>",
utype = "energy",
scale = 1054.68,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["BTU-63F"] = {
name1 = "وحدة حرارية بريطانية (63°ف)",
symbol = "و.ح.ب.<sub>63°ف</sub>",
sym_us = "BTU<sub>63 °F</sub>",
utype = "energy",
scale = 1054.6,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Btu-63F"] = {
name1 = "وحدة حرارية بريطانية (63°ف)",
symbol = "و.ح.ب.<sub>63°ف</sub>",
sym_us = "Btu<sub>63 °F</sub>",
utype = "energy",
scale = 1054.6,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["BTU-ISO"] = {
name1 = "وحدة حرارية بريطانية (ISO)",
symbol = "و.ح.ب.<sub>ISO</sub>",
sym_us = "BTU<sub>ISO</sub>",
utype = "energy",
scale = 1055.056,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Btu-ISO"] = {
target = "BTU-ISO",
},
["BTU-IT"] = {
name1 = "وحدة حرارية بريطانية (IT)",
symbol = "و.ح.ب.<sub>IT</sub>",
sym_us = "BTU<sub>IT</sub>",
utype = "energy",
scale = 1055.05585262,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Btu-IT"] = {
name1 = "وحدة حرارية بريطانية (IT)",
symbol = "و.ح.ب.<sub>IT</sub>",
sym_us = "Btu<sub>IT</sub>",
utype = "energy",
scale = 1055.05585262,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["BTU-mean"] = {
name1 = "وحدة حرارية بريطانية (mean)",
symbol = "و.ح.ب.<sub>mean</sub>",
sym_us = "BTU<sub>mean</sub>",
utype = "energy",
scale = 1055.87,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Btu-mean"] = {
name1 = "وحدة حرارية بريطانية (mean)",
symbol = "و.ح.ب.<sub>mean</sub>",
sym_us = "Btu<sub>mean</sub>",
utype = "energy",
scale = 1055.87,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["BTU-th"] = {
name1 = "وحدة حرارية بريطانية (كيمياء حرارية)",
name1_us = "British thermal units (thermochemical)",
symbol = "و.ح.ب.<sub>th</sub>",
sym_us = "BTU<sub>th</sub>",
utype = "energy",
scale = 1054.35026444,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Btu-th"] = {
name1 = "وحدة حرارية بريطانية (كيمياء حرارية)",
name1_us = "British thermal units (thermochemical)",
symbol = "و.ح.ب.<sub>th</sub>",
sym_us = "Btu<sub>th</sub>",
utype = "energy",
scale = 1054.35026444,
default = "kJ",
link = "وحدة حرارية بريطانية",
},
["Cal"] = {
name1 = "سعرة",
name1_us = "calorie",
name2 = "سعرة",
symbol = "سع",
sym_us = "cal",
utype = "energy",
scale = 4184,
default = "kJ",
},
["cal"] = {
name1 = "سعرة",
name1_us = "calorie",
name2 = "سعرة",
symbol = "سع",
sym_us = "cal",
utype = "energy",
scale = 4.184,
default = "J",
},
["Cal-15"] = {
name1 = "سعرة (15 °C)",
name1_us = "Calorie (15 °C)",
symbol = "سعرة<sub>15</sub>",
sym_us = "Cal<sub>15</sub>",
utype = "energy",
scale = 4185.8,
default = "kJ",
link = "سعرة",
},
["cal-15"] = {
name1 = "سعرة (15 °C)",
name1_us = "calorie (15 °C)",
symbol = "سعرة<sub>15</sub>",
sym_us = "cal<sub>15</sub>",
utype = "energy",
scale = 4.1858,
default = "J",
link = "سعرة",
},
["Cal-IT"] = {
name1 = "سعرة (International Steam Table)",
name1_us = "Calorie (International Steam Table)",
symbol = "سعرة<sub>IT</sub>",
sym_us = "Cal<sub>IT</sub>",
utype = "energy",
scale = 4186.8,
default = "kJ",
link = "سعرة",
},
["cal-IT"] = {
name1 = "سعرة (International Steam Table)",
name1_us = "calorie (International Steam Table)",
symbol = "سعرة<sub>IT</sub>",
sym_us = "cal<sub>IT</sub>",
utype = "energy",
scale = 4.1868,
default = "J",
link = "سعرة",
},
["Cal-th"] = {
name1 = "سعرة (thermochemical)",
name1_us = "Calorie (thermochemical)",
symbol = "سعرة<sub>th</sub>",
sym_us = "Cal<sub>th</sub>",
utype = "energy",
scale = 4184,
default = "kJ",
link = "سعرة",
},
["cal-th"] = {
name1 = "سعرة (thermochemical)",
name1_us = "calorie (thermochemical)",
symbol = "سعرة<sub>th</sub>",
sym_us = "cal<sub>th</sub>",
utype = "energy",
scale = 4.184,
default = "J",
link = "سعرة",
},
["ccatm"] = {
name1 = "سنتيمتر مكعب-جو",
name1_us = "cubic centimetre-atmosphere",
name2 = "سنتيمتر مكعب-جو",
symbol = "سم<sup>3</sup>·جو",
sym_us = "ccatm",
utype = "energy",
scale = 0.101325,
default = "mJ",
link = "جو (وحدة)",
},
["CHU-IT"] = {
name1_us = "Celsius heat unit (International Table)",
name2_us = "Celsius heat units (International Table)",
symbol = "CHU<sub>IT</sub>",
utype = "energy",
scale = 1899.100534716,
default = "kJ",
link = "تحويل الوحدات",
},
["cm3atm"] = {
name1 = "سنتيمتر مكعب-جو",
name1_us = "cubic centimetre-atmosphere",
name2 = "سنتيمتر مكعب-جو",
symbol = "سم<sup>3</sup>·جو",
sym_us = "cm3atm",
utype = "energy",
scale = 0.101325,
default = "mJ",
link = "جو (وحدة)",
},
["cufootatm"] = {
name1 = "قدم مكعب من atmosphere",
name1_us = "cubic foot of atmosphere",
symbol = "cu ft atm",
utype = "energy",
scale = 2869.2044809344,
default = "kJ",
link = "جو (وحدة)",
},
["cufootnaturalgas"] = {
name1 = "قدم مكعب من natural gas",
name1_us = "cubic foot of natural gas",
symbol = "cuftnaturalgas",
sym_us = "~cuftnaturalgas",
usename = 1,
utype = "energy",
scale = 1055055.85262,
default = "MJ",
link = "تحويل الوحدات",
},
["cuftatm"] = {
name1 = "قدم مكعب من atmosphere",
name1_us = "cubic foot of atmosphere",
symbol = "cu ft atm",
utype = "energy",
scale = 2869.2044809344,
default = "kJ",
link = "جو (وحدة)",
},
["cuftnaturalgas"] = {
name1 = "قدم مكعب من natural gas",
name1_us = "cubic foot of natural gas",
symbol = "cuftnaturalgas",
sym_us = "~cuftnaturalgas",
usename = 1,
utype = "energy",
scale = 1055055.85262,
default = "MJ",
link = "تحويل الوحدات",
},
["cuydatm"] = {
name1 = "ياردة مربعة of atmosphere",
name1_us = "cubic yard of atmosphere",
symbol = "cu yd atm",
utype = "energy",
scale = 77468.5209852288,
default = "kJ",
link = "جو (وحدة)",
},
["Eh"] = {
name1 = "إلكترون فولت.هارتري",
name2 = "إلكترون فولت.هارتري",
symbol = "إف<sub>ه</sub>",
sym_us = "''E''<sub>h</sub>",
utype = "energy",
scale = 4.35974417e-18,
default = "eV",
link = "هارتري",
},
["erg"] = {
name2 = "إرج",
symbol = "إرج",
sym_us = "erg",
utype = "energy",
scale = 0.0000001,
default = "μJ",
},
["eV"] = {
name1 = "إلكترون فولت",
name2 = "إلكترون فولت",
symbol = "إف",
sym_us = "eV",
utype = "energy",
scale = 1.602176487e-19,
default = "aJ",
},
["feV"] = {
name1 = "فيمتو الكترون فولت",
name2 = "فيمتو الكترون فولت",
symbol = "فـ.إف",
sym_us = "feV",
utype = "energy",
scale = 1.602176487e-34,
default = "yJ",
link = "إلكترون فولت",
},
["foe"] = {
symbol = "foe",
utype = "energy",
scale = 1e44,
default = "YJ",
link = "فو (وحدة)",
},
["ftlb"] = {
name1 = "قدم-رطل",
symbol = "قدم·رطل",
sym_us = "ftlb",
utype = "energy",
alttype = "torque",
scale = 1.3558179483314004,
default = "J",
link = "Foot-pound (energy)",
},
["ftlb-f"] = {
name1 = "قدم-رطل قوة",
name1_us = "foot-pound force",
symbol = "قدم·رطل<sub>ق</sub>",
sym_us = "ft·lb<sub>f</sub>",
utype = "energy",
alttype = "torque",
scale = 1.3558179483314004,
default = "J",
link = "Foot-pound (energy)",
},
["ftlbf"] = {
name1 = "قدم-رطل قوة",
name1_us = "foot-pound force",
symbol = "قدم·رطل<sub>ق</sub>",
sym_us = "ft·lb<sub>f</sub>",
utype = "energy",
alttype = "torque",
scale = 1.3558179483314004,
default = "J",
link = "Foot-pound (energy)",
},
["ftpdl"] = {
name1_us = "foot-poundal",
symbol = "ft·pdl",
utype = "energy",
scale = 0.0421401100938048,
default = "J",
link = "Foot-poundal",
},
["GeV"] = {
name1 = "جيجا إلكترون فولت",
name2 = "جيجا إلكترون فولت",
symbol = "جـ.إف",
sym_us = "G.eV",
utype = "energy",
scale = 1.602176487e-10,
default = "nJ",
link = "إلكترون فولت",
},
["GLatm"] = {
name1 = "جيجا لتر-جو",
name1_us = "gigalitre-atmosphere",
symbol = "جـ.ل·جو",
sym_us = "GL·atm",
utype = "energy",
scale = 101325000000,
default = "GJ",
link = "جو (وحدة)",
},
["Glatm"] = {
name1 = "جيجا لتر-جو",
name1_us = "gigalitre-atmosphere",
symbol = "جـ.ل·جو",
sym_us = "Gl·atm",
utype = "energy",
scale = 101325000000,
default = "GJ",
link = "جو (وحدة)",
},
["gTNT"] = {
name1 = "غرام من تي أن تي",
name2 = "غرام من تي أن تي",
symbol = "gram of TNT",
sym_us = "~gram of TNT",
usename = 1,
utype = "energy",
scale = 4184,
default = "kJ",
link = "مكافيء تي إن تي",
},
["Gtoe"] = {
name1 = "جيجاطن من مكافئ نفطي",
name1_us = "gigatonne of oil equivalent",
name2 = "جيجاطن من مكافئ نفطي",
symbol = "جـ.طن",
sym_us = "G.toe",
utype = "energy",
scale = 4.1868e19,
default = "EJ",
link = "طن نفط مكافئ",
},
["GtonTNT"] = {
name1 = "جيجاطن من تي أن تي",
name2 = "جيجاطن من تي أن تي",
symbol = "gigaton of TNT",
sym_us = "~gigaton of TNT",
usename = 1,
utype = "energy",
scale = 4.184e18,
default = "EJ",
link = "مكافيء تي إن تي",
},
["GtTNT"] = {
name1 = "جيجاطن من تي أن تي",
name2 = "جيجاطن من تي أن تي",
symbol = "gigatonne of TNT",
sym_us = "~gigatonne of TNT",
usename = 1,
utype = "energy",
scale = 4.184e18,
default = "EJ",
link = "مكافيء تي إن تي",
},
["GW.h"] = {
name1 = "جيجاوات في الساعة",
name2 = "جيجاوات في الساعة",
symbol = "جـ.و·سا",
sym_us = "GW.h",
utype = "energy",
scale = 3.6e12,
default = "TJ",
link = "كيلوواط ساعي",
},
["GWh"] = {
name1 = "جيجاوات في الساعة",
name2 = "جيجاوات في الساعة",
symbol = "جـ.و.سا",
sym_us = "GWh",
utype = "energy",
scale = 3.6e12,
default = "TJ",
link = "كيلوواط ساعي",
},
["hph"] = {
name1 = "حصان في الساعة",
name2 = "حصان في الساعة",
symbol = "حصان·سا",
sym_us = "hph",
utype = "energy",
scale = 2684519.537696172792,
default = "kWh",
link = "حصان (وحدة قدرة)",
},
["impgalatm"] = {
name1_us = "imperial gallon-atmosphere",
symbol = "imp gal·atm",
utype = "energy",
scale = 460.63256925,
default = "J",
link = "جو (وحدة)",
},
["inlb"] = {
name1_us = "inch-pound",
symbol = "بوصة.رطل",
sym_us = "in.lb",
utype = "energy",
alttype = "torque",
scale = 0.1129848290276167,
default = "mJ",
link = "Foot-pound (energy)",
},
["inlb-f"] = {
name1 = "بوصة-رطل قوة",
name1_us = "inch-pound force",
symbol = "بوصة.رطل<sub>ق</sub>",
sym_us = "in.lb<sub>f</sub>",
utype = "energy",
alttype = "torque",
scale = 0.1129848290276167,
default = "mJ",
link = "Foot-pound (energy)",
},
["inlbf"] = {
name1 = "بوصة-رطل قوة",
name1_us = "inch-pound force",
symbol = "بوصة.رطل<sub>ق</sub>",
sym_us = "in.lb<sub>f</sub>",
utype = "energy",
alttype = "torque",
scale = 0.1129848290276167,
default = "mJ",
link = "Foot-pound (energy)",
},
["inoz-f"] = {
name1 = "بوصة-أوقية force",
name1_us = "inch-ounce force",
symbol = "بوصة·أوقية<sub>ق</sub>",
sym_us = "inoz-f",
utype = "energy",
alttype = "torque",
scale = 0.00706155181422604375,
default = "mJ",
link = "Foot-pound (energy)",
},
["inozf"] = {
name1 = "بوصة-أوقية force",
name1_us = "inch-ounce force",
symbol = "بوصة·أوقية.<sub>ق</sub>",
sym_us = "inozf",
utype = "energy",
alttype = "torque",
scale = 0.00706155181422604375,
default = "mJ",
link = "Foot-pound (energy)",
},
["J"] = {
_name1 = "جول",
_symbol = "جول",
_sym_us = "J",
utype = "energy",
scale = 1,
prefixes = 1,
default = "cal",
link = "جول",
},
["kBOE"] = {
name1 = "كيلو برميل من مكافئ نفطي",
name1_us = "kilo barrel of oil equivalent",
symbol = "kBOE",
utype = "energy",
scale = 6.1178632e12,
default = "TJ",
link = "مكافئ برميل النفط",
},
["kcal"] = {
name1 = "كيلو سعرة",
symbol = "ك.سعرة",
sym_us = "kcal",
utype = "energy",
scale = 4184,
default = "kJ",
link = "سعرة",
},
["kcal-15"] = {
name1 = "كيلو سعرة (15 °C)",
name1_us = "kilocalorie (15 °C)",
symbol = "ك.سعرة<sub>15</sub>",
sym_us = "kcal<sub>15</sub>",
utype = "energy",
scale = 4185.8,
default = "kJ",
link = "سعرة",
},
["kcal-IT"] = {
name1 = "كيلو سعرة (International Steam Table)",
name1_us = "kilocalorie (International Steam Table)",
symbol = "ك.سعرة<sub>IT</sub>",
sym_us = "kcal<sub>IT</sub>",
utype = "energy",
scale = 4186.8,
default = "kJ",
link = "سعرة",
},
["kcal-th"] = {
name1 = "كيلو سعرة (thermochemical)",
name1_us = "kilocalorie (thermochemical)",
symbol = "ك.سعرة<sub>th</sub>",
utype = "energy",
scale = 4184,
default = "kJ",
link = "سعرة",
},
["kerg"] = {
name1 = "كيلو أرج",
name1_us = "kiloerg",
name2 = "كيلو أرج",
symbol = "ك.أرج",
sym_us = "kerg",
utype = "energy",
scale = 0.0001,
default = "mJ",
link = "إرج",
},
["keV"] = {
name1 = "كيلو إلكترون فولت",
name1_us = "kiloelectronvolt",
name2 = "كيلو إلكترون فولت",
symbol = "ك.إف",
sym_us = "keV",
utype = "energy",
scale = 1.602176487e-16,
default = "fJ",
link = "إلكترون فولت",
},
["kgTNT"] = {
name1 = "كيلوغرام من تي أن تي",
name1_us = "kilogram of TNT",
symbol = "kilogram of TNT",
sym_us = "~kilogram of TNT",
usename = 1,
utype = "energy",
scale = 4184000,
default = "MJ",
link = "مكافيء تي إن تي",
},
["kLatm"] = {
name1 = "كيلو لتر-جو",
name1_us = "kilolitre-atmosphere",
symbol = "ك.ل·جو",
sym_us = "kLatm",
utype = "energy",
scale = 101325,
default = "kJ",
link = "جو (وحدة)",
},
["klatm"] = {
name1 = "كيلو لتر-جو",
name1_us = "kilolitre-atmosphere",
symbol = "ك.ل·جو",
sym_us = "klatm",
utype = "energy",
scale = 101325,
default = "kJ",
link = "جو (وحدة)",
},
["kt(TNT)"] = {
name1 = "كيلو طن",
name1_us = "kilotonne",
symbol = "ك.طن",
sym_us = "kt(TNT)",
utype = "energy",
scale = 4.184e12,
default = "TJ",
link = "مكافيء تي إن تي",
},
["ktoe"] = {
name1 = "كيلوطن من مكافئ نفطي",
name1_us = "kilotonne of oil equivalent",
symbol = "ktoe",
utype = "energy",
scale = 4.1868e13,
default = "TJ",
link = "طن نفط مكافئ",
},
["ktonTNT"] = {
name1 = "كيلوطن من تي أن تي",
name2 = "كيلوطن من تي أن تي",
symbol = "ك.طن.تي أن تي",
sym_us = "ktonTNT",
utype = "energy",
scale = 4.184e12,
default = "TJ",
link = "مكافيء تي إن تي",
},
["ktTNT"] = {
name1 = "كيلوطن من تي أن تي",
name2 = "كيلوطن من تي أن تي",
symbol = "kilotonne of TNT",
sym_us = "~kilotonne of TNT",
usename = 1,
utype = "energy",
scale = 4.184e12,
default = "TJ",
link = "مكافيء تي إن تي",
},
["kW.h"] = {
name1 = "كيلوواط-ساعة",
symbol = "ك.و.سا",
sym_us = "kW.h",
utype = "energy",
scale = 3600000,
default = "MJ",
link = "كيلوواط ساعي",
},
["kWh"] = {
name1 = "كيلوواط-ساعة",
symbol = "ك.و.سا",
sym_us = "kWh",
utype = "energy",
scale = 3600000,
default = "MJ",
link = "كيلوواط ساعي",
},
["Latm"] = {
name1 = "لتر-جو",
name1_us = "litre-atmosphere",
symbol = "ل·جو",
sym_us = "Latm",
utype = "energy",
scale = 101.325,
default = "J",
link = "جو (وحدة)",
},
["latm"] = {
name1 = "لتر-جو",
name1_us = "litre-atmosphere",
symbol = "ل·جو",
sym_us = "latm",
utype = "energy",
scale = 101.325,
default = "J",
link = "جو (وحدة)",
},
["m3atm"] = {
name1 = "متر مكعب-جو",
name1_us = "cubic metre-atmosphere",
symbol = "م<sup>3</sup>·جو",
sym_us = "m3atm",
utype = "energy",
scale = 101325,
default = "kJ",
link = "جو (وحدة)",
},
["Mcal"] = {
name1 = "ميجا سعرة",
name1_us = "megacalorie",
name2 = "ميجا سعرة",
symbol = "مج.سعرة",
sym_us = "Mcal",
utype = "energy",
scale = 4184000,
default = "MJ",
link = "سعرة",
},
["mcal"] = {
name1 = "ملي سعرة",
name1_us = "millicalorie",
name2 = "ملي سعرة",
symbol = "مـ.سعرة",
sym_us = "mcal",
utype = "energy",
scale = 0.004184,
default = "mJ",
link = "سعرة",
},
["Mcal-15"] = {
name1 = "ميجا سعرة (15 °C)",
name1_us = "megacalorie (15 °C)",
symbol = "مج.سعرة<sub>15</sub>",
sym_us = "Mcal<sub>15</sub>",
utype = "energy",
scale = 4185800,
default = "MJ",
link = "سعرة",
},
["mcal-15"] = {
name1 = "ملي سعرة (15 °C)",
name1_us = "millicalorie (15 °C)",
symbol = "مـ.سعرة<sub>15</sub>",
sym_us = "mcal<sub>15</sub>",
utype = "energy",
scale = 0.0041858,
default = "mJ",
link = "سعرة",
},
["Mcal-IT"] = {
name1 = "ميجا سعرة (International Steam Table)",
name1_us = "megacalorie (International Steam Table)",
symbol = "مج.سعرة<sub>IT</sub>",
sym_us = "Mcal<sub>IT</sub>",
utype = "energy",
scale = 4186800,
default = "MJ",
link = "سعرة",
},
["mcal-IT"] = {
name1 = "ملي سعرة (International Steam Table)",
name1_us = "millicalorie (International Steam Table)",
symbol = "مـ.سعرة<sub>IT</sub>",
sym_us = "mcal<sub>IT</sub>",
utype = "energy",
scale = 0.0041868,
default = "mJ",
link = "سعرة",
},
["Mcal-th"] = {
name1 = "ميجا سعرة (thermochemical)",
name1_us = "megacalorie (thermochemical)",
symbol = "مج.سعرة<sub>th</sub>",
sym_us = "Mcal<sub>th</sub>",
utype = "energy",
scale = 4184000,
default = "MJ",
link = "سعرة",
},
["mcal-th"] = {
name1 = "ملي سعرة (thermochemical)",
name1_us = "millicalorie (thermochemical)",
symbol = "مـ.سعرة<sub>th</sub>",
sym_us = "mcal<sub>th</sub>",
utype = "energy",
scale = 0.004184,
default = "mJ",
link = "سعرة",
},
["Merg"] = {
name1 = "ميجا إرج",
name1_us = "megaerg",
name2 = "ميجا إرج",
symbol = "مج.إرج",
sym_us = "Merg",
utype = "energy",
scale = 0.1,
default = "J",
link = "إرج",
},
["merg"] = {
name1 = "ملي إرج",
name1_us = "millierg",
name2 = "ملي إرج",
symbol = "مـ.إرج",
sym_us = "merg",
utype = "energy",
scale = 0.0000000001,
default = "μJ",
link = "إرج",
},
["MeV"] = {
name1 = "ميجا إلكترون فولت",
name2 = "ميجا إلكترون فولت",
symbol = "مج.إف",
sym_us = "MeV",
utype = "energy",
scale = 1.602176487e-13,
default = "pJ",
link = "إلكترون فولت",
},
["meV"] = {
name1 = "ملي إلكترون فولت",
name1_us = "millielectronvolt",
name2 = "ملي إلكترون فولت",
symbol = "مـ.إف",
sym_us = "meV",
utype = "energy",
scale = 1.602176487e-22,
default = "zJ",
link = "إلكترون فولت",
},
["MLatm"] = {
name1 = "ميجا لتر-جو",
name1_us = "megalitre-atmosphere",
name2 = "ميجا لتر-جو",
symbol = "مج.ل·جو",
sym_us = "ML·atm",
utype = "energy",
scale = 101325000,
default = "MJ",
link = "جو (وحدة)",
},
["Mlatm"] = {
name1 = "ميجا لتر-جو",
name1_us = "megalitre-atmosphere",
name2 = "ميجا لتر-جو",
symbol = "مج.ل·جو",
sym_us = "Ml·atm",
utype = "energy",
scale = 101325000,
default = "MJ",
link = "جو (وحدة)",
},
["mLatm"] = {
name1 = "ملي لتر-جو",
name1_us = "millilitre-atmosphere",
name2 = "ملي لتر-جو",
symbol = "مـ.ل·جو",
sym_us = "mL·atm",
utype = "energy",
scale = 0.101325,
default = "mJ",
link = "جو (وحدة)",
},
["mlatm"] = {
name1 = "ملي لتر-جو",
name1_us = "millilitre-atmosphere",
name2 = "ملي لتر-جو",
symbol = "مـ.ل·جو",
sym_us = "ml·atm",
utype = "energy",
scale = 0.101325,
default = "mJ",
link = "جو (وحدة)",
},
["MMBtu"] = {
name1 = "مليون وحدة حرارية بريطانية",
name1_us = "million British thermal units",
symbol = "مليون.و.ح.ب.",
sym_us = "MMBtu",
utype = "energy",
scale = 1055055852.62,
default = "GJ",
link = "وحدة حرارية بريطانية",
},
["Mt(TNT)"] = {
name1 = "ميجا طن",
name1_us = "megatonne",
name2 = "ميجا طن",
symbol = "مج.طن",
sym_us = "Mt(TNT)",
utype = "energy",
scale = 4.184e15,
default = "PJ",
link = "مكافيء تي إن تي",
},
["Mtoe"] = {
name1 = "ميجا طن من مكافئ نفطي",
name1_us = "megatonne of oil equivalent",
name2 = "ميجا طن من مكافئ نفطي",
symbol = "Mtoe",
utype = "energy",
scale = 4.1868e16,
default = "PJ",
link = "طن نفط مكافئ",
},
["MtonTNT"] = {
name1 = "ميجا طن من تي أن تي",
name1_us = "megaton of TNT",
name2 = "ميجا طن من تي أن تي",
symbol = "مج.طن تي إن تي",
sym_us = "Mt",
utype = "energy",
scale = 4.184e15,
default = "PJ",
link = "مكافيء تي إن تي",
},
["mtonTNT"] = {
name1 = "ملي طن من تي أن تي",
name1_us = "milliton of TNT",
name2 = "ملي طن من تي أن تي",
symbol = "milliton of TNT",
sym_us = "~milliton of TNT",
usename = 1,
utype = "energy",
scale = 4184000,
default = "MJ",
link = "مكافيء تي إن تي",
},
["MtTNT"] = {
name1 = "ميجا طن من تي أن تي",
name1_us = "megatonne of TNT",
name2 = "ميجا طن من تي أن تي",
symbol = "megatonne of TNT",
sym_us = "~millitonne of TNT",
usename = 1,
utype = "energy",
scale = 4.184e15,
default = "PJ",
link = "مكافيء تي إن تي",
},
["mtTNT"] = {
name1 = "ملي طن من تي أن تي",
name1_us = "millitonne of TNT",
name2 = "ملي طن من تي أن تي",
symbol = "millitonne of TNT",
sym_us = "~millitonne of TNT",
usename = 1,
utype = "energy",
scale = 4184000,
default = "MJ",
link = "مكافيء تي إن تي",
},
["MW.h"] = {
name1 = "ميجا وات في الساعة",
name1_us = "megawatt-hour",
name2 = "ميجا وات في الساعة",
symbol = "مج.و·س",
sym_us = "MW.h",
utype = "energy",
scale = 3600000000,
default = "GJ",
link = "كيلوواط ساعي",
},
["mW.h"] = {
name1 = "ملي وات في الساعة",
name1_us = "milliwatt-hour",
name2 = "ملي وات في الساعة",
symbol = "مـ.و·س",
sym_us = "mW.h",
utype = "energy",
scale = 3.6,
default = "J",
link = "كيلوواط ساعي",
},
["MWh"] = {
name1 = "ميجا وات في الساعة",
name1_us = "megawatt-hour",
name2 = "ميجا وات في الساعة",
symbol = "مج.و·س",
sym_us = "MWh",
utype = "energy",
scale = 3600000000,
default = "GJ",
link = "كيلوواط ساعي",
},
["mWh"] = {
name1 = "ملي وات في الساعة",
name1_us = "milliwatt-hour",
name2 = "ملي وات في الساعة",
symbol = "مـ.و·س",
sym_us = "mWh",
utype = "energy",
scale = 3.6,
default = "J",
link = "كيلوواط ساعي",
},
["neV"] = {
name1 = "نانو إلكترون فولت",
name1_us = "nanoelectronvolt",
name2 = "نانو إلكترون فولت",
symbol = "نـ.إف",
sym_us = "neV",
utype = "energy",
scale = 1.602176487e-28,
default = "yJ",
link = "إلكترون فولت",
},
["PeV"] = {
name1 = "بيتا إلكترون فولت",
name1_us = "petaelectronvolt",
name2 = "بيتا إلكترون فولت",
symbol = "بتـ.إف",
sym_us = "PeV",
utype = "energy",
scale = 0.0001602176487,
default = "mJ",
link = "إلكترون فولت",
},
["peV"] = {
name1 = "بيكو إلكترون فولت",
name1_us = "picoelectronvolt",
name2 = "بيكو إلكترون فولت",
symbol = "بـ.إف",
sym_us = "peV",
utype = "energy",
scale = 1.602176487e-31,
default = "yJ",
link = "إلكترون فولت",
},
["PSh"] = {
name1 = "Pferdestärkenstunde",
symbol = "PSh",
utype = "energy",
scale = 2647795.5,
default = "kWh",
},
["quad"] = {
name1_us = "quadrillion British thermal units",
name2_us = "quadrillion British thermal units",
symbol = "quad",
utype = "energy",
scale = 1.054804e18,
default = "EJ",
link = "كواد (وحدة)",
},
["Ry"] = {
name1_us = "rydberg",
symbol = "Ry",
utype = "energy",
scale = 2.1798741e-18,
default = "eV",
link = "ثابت ريدبرغ",
},
["scc"] = {
name1 = "standard سنتيمتر مكعب",
name1_us = "standard cubic centimetre",
symbol = "scc",
utype = "energy",
scale = 0.101325,
default = "mJ",
link = "جو (وحدة)",
},
["scf"] = {
name1 = "standard قدم مكعب",
name1_us = "standard cubic foot",
symbol = "scf",
utype = "energy",
scale = 2869.2044809344,
default = "kJ",
link = "جو (وحدة)",
},
["scfoot"] = {
name1 = "standard قدم مكعب",
name1_us = "standard cubic foot",
symbol = "scf",
utype = "energy",
scale = 2869.2044809344,
default = "kJ",
link = "جو (وحدة)",
},
["scy"] = {
name1_us = "standard cubic yard",
symbol = "scy",
utype = "energy",
scale = 77468.5209852288,
default = "kJ",
link = "جو (وحدة)",
},
["sl"] = {
name1_us = "standard litre",
symbol = "sl",
utype = "energy",
scale = 101.325,
default = "J",
link = "جو (وحدة)",
},
["t(TNT)"] = {
name1_us = "tonne",
name2 = "طن تي إن تي",
symbol = "طن تي إن تي",
sym_us = "t(TNT)",
utype = "energy",
scale = 4184000000,
default = "GJ",
link = "مكافيء تي إن تي",
},
["TeV"] = {
name1 = "تيرا إلكترون فولت",
name1_us = "teraelectronvolt",
name2 = "تيرا إلكترون فولت",
symbol = "تـ.إف",
sym_us = "TeV",
utype = "energy",
scale = 1.602176487e-7,
default = "μJ",
link = "إلكترون فولت",
},
["th"] = {
name1_us = "thermie",
name2 = "ثرم",
symbol = "ثرم",
sym_us = "th",
utype = "energy",
scale = 4186800,
default = "MJ",
link = "تحويل الوحدات",
},
["thm-EC"] = {
name1_us = "therm (EC)",
name2_us = "therms (EC)",
symbol = "ثرم(EC)",
sym_us = "thm-EC",
utype = "energy",
scale = 105506000,
default = "MJ",
link = "Therm",
},
["thm-UK"] = {
name1_us = "therm (UK)",
name2_us = "therms (UK)",
symbol = "ثرم(UK)",
sym_us = "thm-UK",
utype = "energy",
scale = 105505585.257348,
default = "MJ",
link = "Therm",
},
["thm-US"] = {
name1 = "ثرم أمريكي",
name1_us = "therms (US)",
name2 = "ثرم أمريكي",
name2_us = "therms (U.S.)",
symbol = "ثرم(US)",
sym_us = "thm (U.S.)",
utype = "energy",
scale = 105480400,
default = "MJ",
link = "Therm",
},
["toe"] = {
name1 = "طن من مكافئ نفطي",
name1_us = "tonne of oil equivalent",
name2 = "طن من مكافئ نفطي",
symbol = "toe",
utype = "energy",
scale = 41868000000,
default = "GJ",
link = "طن نفط مكافئ",
},
["tonTNT"] = {
name1 = "طن من تي أن تي",
name1_us = "ton of TNT",
name2 = "طن من تي أن تي",
symbol = "ton of TNT",
sym_us = "~ton of TNT",
usename = 1,
utype = "energy",
scale = 4184000000,
default = "GJ",
link = "مكافيء تي إن تي",
},
["tTNT"] = {
name1 = "طن من تي أن تي",
name1_us = "tonne of TNT",
name2 = "طن من تي أن تي",
symbol = "tonne of TNT",
sym_us = "~tonne of TNT",
usename = 1,
utype = "energy",
scale = 4184000000,
default = "GJ",
link = "مكافيء تي إن تي",
},
["TtonTNT"] = {
name1 = "تيرا طن من تي أن تي",
name1_us = "teraton of TNT",
name2 = "تيرا طن من تي أن تي",
symbol = "teraton of TNT",
sym_us = "~teraton of TNT",
usename = 1,
utype = "energy",
scale = 4.18E+21,
default = "ZJ",
link = "مكافيء تي إن تي",
},
["TtTNT"] = {
name1 = "تيرا طن من تي أن تي",
name1_us = "teratonne of TNT",
name2 = "تيرا طن من تي أن تي",
symbol = "teratonne of TNT",
sym_us = "~teratonne of TNT",
usename = 1,
utype = "energy",
scale = 4.184e21,
default = "ZJ",
link = "مكافيء تي إن تي",
},
["TW.h"] = {
name1 = "تيرا وات في الساعة",
name1_us = "terawatt-hour",
name2 = "تيرا وات في الساعة",
symbol = "تـ.و·س",
sym_us = "TW.h",
utype = "energy",
scale = 3.6e15,
default = "PJ",
link = "كيلوواط ساعي",
},
["TWh"] = {
name1 = "تيرا وات في الساعة",
name1_us = "terawatt-hour",
name2 = "تيرا وات في الساعة",
symbol = "تـ.و·س",
sym_us = "TWh",
utype = "energy",
scale = 3.6e15,
default = "PJ",
link = "كيلوواط ساعي",
},
["USgalatm"] = {
name1 = "جالون أمريكي-جو",
name1_us = "US gallon-atmosphere",
name2 = "جالون أمريكي-جو",
symbol = "غالون أمريكي·جو",
sym_us = "U.S. gal·atm",
utype = "energy",
scale = 383.5568490138,
default = "J",
link = "جو (وحدة)",
},
["W.h"] = {
name1 = "وات في الساعة",
name1_us = "watt-hour",
name2 = "وات في الساعة",
symbol = "و·س",
sym_us = ".h",
utype = "energy",
scale = 3600,
default = "kJ",
link = "كيلوواط ساعي",
},
["Wh"] = {
name1 = "وات في الساعة",
name1_us = "watt-hour",
name2 = "وات في الساعة",
symbol = "و·س",
sym_us = "Wh",
utype = "energy",
scale = 3600,
default = "kJ",
link = "كيلوواط ساعي",
},
["μerg"] = {
name1 = "ميكرو إرج",
name1_us = "microerg",
name2 = "ميكرو إرج",
symbol = "مكـ.إرج",
sym_us = "μerg",
utype = "energy",
scale = 1e-13,
default = "nJ",
link = "إرج",
},
["μeV"] = {
name1 = "ميكرو إلكترون فولت",
name1_us = "microelectronvolt",
name2 = "ميكرو إلكترون فولت",
symbol = "مكـ.إف",
sym_us = "μeV",
utype = "energy",
scale = 1.602176487e-25,
default = "yJ",
link = "إلكترون فولت",
},
["μW.h"] = {
name1 = "ميكرو وات في الساعة",
name1_us = "microwatt-hour",
name2 = "ميكرو وات في الساعة",
symbol = "مكـ.و·س",
sym_us = "μW.h",
utype = "energy",
scale = 0.0036,
default = "mJ",
link = "كيلوواط ساعي",
},
["μWh"] = {
name1 = "ميكرو وات في الساعة",
name1_us = "microwatt-hour",
name2 = "ميكرو وات في الساعة",
symbol = "مكـ.و·س",
sym_us = "μWh",
utype = "energy",
scale = 0.0036,
default = "mJ",
link = "كيلوواط ساعي",
},
["-kW.h"] = {
target = "kW.h",
},
["μLatm"] = {
name1 = "ميكرو لتر-جو",
name1_us = "microlitre-atmosphere",
name2 = "ميكرو لتر-جو",
symbol = "مكـ.ل·جو",
sym_us = "μL·atm",
utype = "energy",
scale = 0.000101325,
default = "μJ",
link = "جو (وحدة)",
},
["μlatm"] = {
name1 = "ميكرو لتر-جو",
name1_us = "microlitre-atmosphere",
name2 = "ميكرو لتر-جو",
symbol = "مكـ.ل·جو",
sym_us = "μL·atm",
utype = "energy",
scale = 0.000101325,
default = "μJ",
link = "جو (وحدة)",
},
["μtonTNT"] = {
name1 = "ميكروطن من تي أن تي",
name1_us = "microton of TNT",
name2 = "ميكروطن من تي أن تي",
symbol = "microton of TNT",
sym_us = "~microton of TNT",
usename = 1,
utype = "energy",
scale = 4184,
default = "kJ",
link = "مكافيء تي إن تي",
},
["μtTNT"] = {
name1 = "ميكروطن من تي أن تي",
name1_us = "microtonne of TNT",
name2 = "ميكروطن من تي أن تي",
symbol = "microtonne of TNT",
sym_us = "~microtonne of TNT",
usename = 1,
utype = "energy",
scale = 4184,
default = "kJ",
link = "مكافيء تي إن تي",
},
["btu"] = {
target = "BTU",
},
["Calorie"] = {
target = "Cal",
},
["ft.lbf"] = {
target = "ftlbf",
},
["ft·lb-f"] = {
target = "ftlb-f",
},
["ft·lbf"] = {
target = "ftlbf",
},
["g-cal-15"] = {
target = "cal-15",
},
["g-cal-IT"] = {
target = "cal-IT",
},
["g-cal-th"] = {
target = "cal-th",
},
["g-kcal-15"] = {
target = "kcal-15",
},
["g-kcal-IT"] = {
target = "kcal-IT",
},
["g-kcal-th"] = {
target = "kcal-th",
},
["g-Mcal-15"] = {
target = "Mcal-15",
},
["g-mcal-15"] = {
target = "mcal-15",
},
["g-Mcal-IT"] = {
target = "Mcal-IT",
},
["g-mcal-IT"] = {
target = "mcal-IT",
},
["g-Mcal-th"] = {
target = "Mcal-th",
},
["g-mcal-th"] = {
target = "mcal-th",
},
["GW-h"] = {
target = "GW.h",
},
["GW·h"] = {
target = "GW.h",
},
["Hartree"] = {
target = "Eh",
},
["hp.h"] = {
target = "hph",
},
["hp·h"] = {
target = "hph",
},
["in.lb-f"] = {
target = "inlb-f",
},
["in.lbf"] = {
target = "inlbf",
},
["in.oz-f"] = {
target = "inoz-f",
},
["in.ozf"] = {
target = "inozf",
},
["in·lb-f"] = {
target = "inlb-f",
},
["in·lbf"] = {
target = "inlbf",
},
["in·oz-f"] = {
target = "inoz-f",
},
["in·ozf"] = {
target = "inozf",
},
["kbboe"] = {
target = "kBOE",
symbol = "kbboe",
},
["kg-cal-15"] = {
target = "Cal-15",
},
["kg-cal-IT"] = {
target = "Cal-IT",
},
["kg-cal-th"] = {
target = "Cal-th",
},
["kW-h"] = {
target = "kW.h",
},
["kW·h"] = {
target = "kW.h",
},
["MW-h"] = {
target = "MW.h",
},
["mW-h"] = {
target = "mW.h",
},
["MW·h"] = {
target = "MW.h",
},
["mW·h"] = {
target = "mW.h",
},
["TW-h"] = {
target = "TW.h",
},
["TW·h"] = {
target = "TW.h",
},
["U.S.galatm"] = {
target = "USgalatm",
sp_us = true,
},
["uerg"] = {
target = "μerg",
},
["ueV"] = {
target = "μeV",
},
["uLatm"] = {
target = "μLatm",
},
["ulatm"] = {
target = "μlatm",
},
["usgalatm"] = {
target = "USgalatm",
},
["utonTNT"] = {
target = "μtonTNT",
},
["utTNT"] = {
target = "μtTNT",
},
["uW-h"] = {
target = "μW.h",
},
["uW.h"] = {
target = "μW.h",
},
["uWh"] = {
target = "μWh",
},
["uW·h"] = {
target = "μW.h",
},
["W-h"] = {
target = "W.h",
},
["eVpar"] = {
_name1 = "إلكترون فولت",
_symbol = "إف",
_sym_us = "eV",
utype = "energy per chemical amount",
scale = 96485.329522144166,
prefixes = 1,
default = "kcal/mol",
link = "إلكترون فولت",
},
["kcal/mol"] = {
per = { "kcal", "mol" },
utype = "energy per chemical amount",
default = "kJ/mol",
link = "كيلو سعرة لكل مول",
},
["kJ/mol"] = {
per = { "kJ", "mol" },
utype = "energy per chemical amount",
default = "kcal/mol",
link = "جول لكل مول",
},
["kWh/100 km"] = {
name1 = "كيلووات-ساعة لكل 100 كيلومتر",
name2 = "كيلووات-ساعة لكل 100 كيلومتر",
name2_us = "kilowatt-hours per 100 kilometers",
symbol = "كو.س/100 كم",
utype = "energy per unit length",
scale = 36,
default = "MJ/km kWh/mi",
link = "كيلوواط ساعي",
},
["kWh/100 mi"] = {
name1 = "كيلووات-ساعة لكل 100 ميل",
name2 = "كيلووات-ساعة لكل 100 ميل",
symbol = "كو.س/100 ميل",
utype = "energy per unit length",
scale = 22.3694,
default = "mpge",
link = "ميل لكل جالون جازولين مكافئ",
},
["MJ/100 km"] = {
name1 = "ميجا جول لكل 100 كيلومتر",
name2 = "ميجا جول لكل 100 كيلومتر",
name2_us = "megajoules per 100 kilometers",
symbol = "مج.جول/100 كم",
utype = "energy per unit length",
scale = 10,
default = "BTU/mi",
link = "وحدة حرارية بريطانية",
},
["mpge"] = {
name1 = "ميل لكل جالون جازولين مكافئ",
name2 = "ميل لكل جالون جازولين مكافئ",
symbol = "mpg-e",
utype = "energy per unit length",
scale = 13e-6,
invert = -1,
iscomplex= true,
default = "kWh/100 mi",
},
["BTU/mi"] = {
per = { "BTU", "mi" },
utype = "energy per unit length",
default = "v > 1525 ! M ! k ! J/km",
},
["kJ/km"] = {
per = { "kJ", "km" },
utype = "energy per unit length",
default = "BTU/mi",
},
["kWh/km"] = {
per = { "-kW.h", "km" },
utype = "energy per unit length",
default = "MJ/km kWh/mi",
},
["kWh/mi"] = {
per = { "-kW.h", "mi" },
utype = "energy per unit length",
default = "kWh/km MJ/km",
},
["MJ/km"] = {
per = { "MJ", "km" },
utype = "energy per unit length",
default = "BTU/mi",
},
["mpg-e"] = {
target = "mpge",
},
["BTU/lb"] = {
name1 = "وحدة حرارية بريطانية لكل رطل",
name2 = "وحدة حرارية بريطانية لكل رطل",
symbol = "و.ح.ب/رطل",
sym_us = "BTU/lb",
utype = "energy per unit mass",
scale = 429.92261414790346,
default = "kJ/kg",
link = "وحدة حرارية بريطانية",
},
["cal/g"] = {
name1 = "سعرات حرارية لكل غرام",
name2 = "سعرات حرارية لكل غرام",
symbol = "سعرة/غ",
sym_us = "cal/g",
utype = "energy per unit mass",
scale = 4184,
default = "J/g",
link = "Calorie per gram",
},
["GJ/kg"] = {
name1 = "جيجا جول لكل كيلوجرام",
name2 = "جيجا جول لكل كيلوجرام",
symbol = "جـ.جول/كجم",
sym_us = "GJ/kg",
utype = "energy per unit mass",
scale = 1e9,
default = "ktTNT/t",
link = "جول",
},
["J/g"] = {
name1 = "جول لكل غرام",
name2 = "جول لكغ غرام",
symbol = "جول/ع",
sym_us = "J/g",
utype = "energy per unit mass",
scale = 1000,
default = "kcal/g",
link = "جول",
},
["kcal/g"] = {
name1 = "كيلوسعرة لكل جرام",
name2 = "كيلوسعرة لكل جرام",
symbol = "ك.سعرة/غ",
sym_us = "kcal/g",
utype = "energy per unit mass",
scale = 4184000,
default = "kJ/g",
},
["kJ/g"] = {
name1 = "كيلوجول لكل جرام",
name2 = "كيلوجول لكل جرام",
symbol = "ك.جول/غ",
sym_us = "kJ/g",
utype = "energy per unit mass",
scale = 1000000,
default = "kcal/g",
link = "جول",
},
["kJ/kg"] = {
name1 = "كيلوجول لكل كيلوجرام",
name2 = "كيلوجول لكل كيلوجرام",
symbol = "ك.جول/كجم",
sym_us = "kJ/kg",
utype = "energy per unit mass",
scale = 1000,
default = "BTU/lb",
link = "Kilojoule per kilogram",
},
["ktonTNT/MT"] = {
name1 = "كيلوطن من تي ان تي للطن المتري",
name2 = "كيلوطن من تي ان تي للطن المتري",
symbol = "kiloton of TNT per metric ton",
usename = 1,
utype = "energy per unit mass",
scale = 4184000000,
default = "GJ/kg",
link = "مكافيء تي إن تي",
},
["ktTNT/t"] = {
name1 = "كيلوطن من تي ان تي لكل طن",
name2 = "كيلوطن من تي ان تي لكل طن",
symbol = "kilotonne of TNT per tonne",
usename = 1,
utype = "energy per unit mass",
scale = 4184000000,
default = "GJ/kg",
link = "مكافيء تي إن تي",
},
["MtonTNT/MT"] = {
name1 = "ميجاطن من تي ان تي للطن المتري",
name2 = "ميجاطن من تي ان تي للطن المتري",
symbol = "megaton of TNT per metric ton",
usename = 1,
utype = "energy per unit mass",
scale = 4.184e12,
default = "TJ/kg",
link = "مكافيء تي إن تي",
},
["MtTNT/MT"] = {
name1 = "ميجاطن من تي ان تي لكل طن",
name2 = "ميجاطن من تي ان تي لكل طن",
symbol = "megatonne of TNT per tonne",
usename = 1,
utype = "energy per unit mass",
scale = 4.184e12,
default = "TJ/kg",
link = "مكافيء تي إن تي",
},
["TJ/kg"] = {
name1 = "تيراجول لكل كيلوجرام",
name2 = "تيراجول لكل كيلوجرام",
symbol = "تـ.جول/كجم",
sym_us = "TJ/kg",
utype = "energy per unit mass",
scale = 1e12,
default = "MtTNT/MT",
link = "جول",
},
["Cal/g"] = {
per = { "Cal", "g" },
utype = "energy per unit mass",
default = "kJ/g",
},
["BTU/cuft"] = {
per = { "BTU", "cuft" },
utype = "energy per unit volume",
default = "kJ/L",
},
["Cal/12USoz(mL)serve"] = {
per = { "Cal", "-12USoz(mL)serve" },
utype = "energy per unit volume",
default = "kJ/L",
},
["Cal/12USoz(ml)serve"] = {
per = { "Cal", "-12USoz(ml)serve" },
utype = "energy per unit volume",
default = "kJ/l",
},
["Cal/12USozserve"] = {
per = { "Cal", "-12USozserve" },
utype = "energy per unit volume",
default = "kJ/L",
},
["Cal/USoz"] = {
per = { "Cal", "USoz" },
utype = "energy per unit volume",
default = "kJ/ml",
},
["kJ/L"] = {
per = { "kJ", "L" },
utype = "energy per unit volume",
default = "BTU/cuft",
},
["kJ/l"] = {
per = { "kJ", "l" },
utype = "energy per unit volume",
default = "BTU/cuft",
},
["kJ/ml"] = {
per = { "kJ", "ml" },
utype = "energy per unit volume",
default = "Cal/USoz",
},
["MJ/m3"] = {
per = { "MJ", "m3" },
utype = "energy per unit volume",
default = "BTU/cuft",
},
["Sv"] = {
_name1 = "زيفرت",
_symbol = "زف",
_sym_us = "Sv",
utype = "equivalent radiation dose",
scale = 1,
prefixes = 1,
default = "rem",
link = "زيفرت",
},
["rem"] = {
_name1 = "rem",
_symbol = "rem",
utype = "equivalent radiation dose",
scale = 0.01,
prefixes = 1,
default = "Sv",
link = "Roentgen equivalent man",
},
["g/km"] = {
name1 = "جرام لكل كيلومتر",
name1_us = "gram per kilometre",
name2 = "غرام لكل كيلومتر",
name2_us = "grams per kilometer",
symbol = "غ/كم",
utype = "exhaust emission",
scale = 1e-6,
default = "oz/mi",
link = "غاز عادم",
},
["g/mi"] = {
name1 = "جرام لكل ميل",
name1_us = "gram per mile",
symbol = "غ/ميل",
utype = "exhaust emission",
scale = 6.2137119223733397e-7,
default = "g/km",
link = "غاز عادم",
},
["gCO2/km"] = {
name1 = "جرام من CO<sub>2</sub> لكل كيلومتر",
name1_us = "gram of CO<sub>2</sub> per kilometre",
name2 = "جرام من CO<sub>2</sub> لكل كيلومتر",
name2_us = "grams of CO<sub>2</sub> per kilometer",
symbol = "غ(CO<sub>2</sub>)/كم",
utype = "exhaust emission",
scale = 1e-6,
default = "ozCO2/mi",
link = "غاز عادم",
},
["gCO2/mi"] = {
name1 = "جرام من CO<sub>2</sub> لكل ميل",
name1_us = "gram of CO<sub>2</sub> per mile",
symbol = "غ(CO<sub>2</sub>)/ميل",
utype = "exhaust emission",
scale = 6.2137119223733397e-7,
default = "gCO2/km",
link = "غاز عادم",
},
["kg/km"] = {
name1 = "كيلو جرام لكل كيلومتر",
name1_us = "kilogram per kilometre",
name2 = "كيلوغرام لكل كيلومتر",
name2_us = "kilograms per kilometer",
symbol = "كجم/كم",
utype = "exhaust emission",
scale = 0.001,
default = "lb/mi",
link = "غاز عادم",
},
["kgCO2/km"] = {
name1 = "كيلوغرام من CO<sub>2</sub> لكل كيلومتر",
name1_us = "kilogram of CO<sub>2</sub> per kilometre",
name2 = "كيلوغرام من CO<sub>2</sub> لكل كيلومتر",
name2_us = "kilograms of CO<sub>2</sub> per kilometer",
symbol = "كجم(CO<sub>2</sub>)/كم",
utype = "exhaust emission",
scale = 0.001,
default = "lbCO2/mi",
link = "غاز عادم",
},
["lb/mi"] = {
name1 = "رطل لكل ميل",
name1_us = "pound per mile",
symbol = "رطل/ميل",
utype = "exhaust emission",
scale = 0.00028184923173665794,
default = "kg/km",
link = "غاز عادم",
},
["lbCO2/mi"] = {
name1 = "رطل من CO<sub>2</sub> لكل ميل",
name2_us = "pound of CO<sub>2</sub> per mile",
symbol = "رطل(CO<sub>2</sub>)/ميل",
utype = "exhaust emission",
scale = 0.00028184923173665794,
default = "kgCO2/km",
link = "غاز عادم",
},
["oz/mi"] = {
name1 = "أوقية لكل ميل",
name2_us = "ounce per mile",
symbol = "أوقية/ميل",
utype = "exhaust emission",
scale = 1.7615576983541121e-5,
default = "g/km",
link = "غاز عادم",
},
["ozCO2/mi"] = {
name1 = "أوقية من CO<sub>2</sub> لكل ميل",
name1_us = "ounce of CO<sub>2</sub> per mile",
symbol = "أوقية(CO<sub>2</sub>)/ميل",
utype = "exhaust emission",
scale = 1.7615576983541121e-5,
default = "gCO2/km",
link = "غاز عادم",
},
["cuft/a"] = {
name1 = "قدم مكعب لكل سنة",
name2 = "قدم مكعب لكل سنة",
symbol = "قدم<sup>3</sup>/سنة",
utype = "flow",
scale = 8.9730672142368242e-10,
default = "m3/a",
link = "قدم مكعب",
},
["cuft/d"] = {
name1 = "قدم مكعب لكل يوم",
name2 = "قدم مكعب لكل يوم",
symbol = "قدم<sup>3</sup>/ي",
utype = "flow",
scale = 3.2774128000000003e-7,
default = "m3/d",
link = "قدم مكعب",
},
["cuft/h"] = {
name1 = "قدم مكعب لكل ساعة",
name2 = "قدم مكعب لكل ساعة",
symbol = "قدم<sup>3</sup>/سا",
utype = "flow",
scale = 7.8657907200000004e-6,
default = "m3/h",
link = "قدم مكعب",
},
["cuft/min"] = {
name1 = "قدم مكعب لكل دقيقة",
name2 = "قدم مكعب لكل دقيقة",
symbol = "قدم<sup>3</sup>/د",
utype = "flow",
scale = 0.00047194744319999999,
default = "m3/min",
link = "قدم مكعب",
},
["cuft/s"] = {
name1 = "قدم مكعب لكل ثانية",
name2 = "قدم مكعب لكل ثانية",
symbol = "قدم<sup>3</sup>/ث",
utype = "flow",
scale = 2.83E-02,
default = "m3/s",
link = "قدم مكعب",
},
["cumi/a"] = {
name1 = "ميل مكعب لكل سنة",
name2 = "ميل مكعب لكل سنة",
symbol = "ميل<sup>3</sup>/سنة",
utype = "flow",
scale = 132.08171170940057,
default = "km3/a",
link = "قدم مكعب",
},
["cuyd/h"] = {
name1 = "ياردة مكعب لكل ساعة",
name2 = "ياردة مكعب لكل ساعة",
symbol = "ياردة<sup>3</sup>/سا",
utype = "flow",
scale = 0.00021237634944000001,
default = "m3/h",
link = "قدم مكعب",
},
["cuyd/s"] = {
name1 = "ياردة مكعب لكل ثانية",
name2 = "ياردة مكعب لكل ثانية",
symbol = "ياردة<sup>3</sup>/ث",
utype = "flow",
scale = 0.76455485798400002,
default = "m3/s",
link = "Cubic yard per second",
},
["Goilbbl/a"] = {
name1 = "بليون برميل لكل سنة",
name2 = "بليون برميل لكل سنة",
symbol = "بيلون برميل/سنة",
utype = "flow",
scale = 5.0380033629933836,
default = "v * 1.58987294928 < 10 ! e6 ! e9 ! m3/a",
link = "برميل (نفط)",
},
["impgal/h"] = {
name1 = "جالون إمبريال لكل ساعة",
name2 = "جالون إمبريال لكل ساعة",
symbol = "جالون إمبريال/سا",
utype = "flow",
scale = 1.2628027777777779e-6,
default = "m3/h",
link = "غالون",
},
["impgal/min"] = {
name1 = "جالون إمبريال لكل دقيقة",
name2 = "جالون إمبريال لكل دقيقة",
symbol = "جالون إمبريال/د",
utype = "flow",
scale = 7.5768166666666671e-5,
default = "m3/s",
link = "غالون",
},
["impgal/s"] = {
name1 = "جالون إمبريال لكل ثانية",
name2 = "جالون إمبريال لكل ثانية",
symbol = "جالون إمبريال/ث",
utype = "flow",
scale = 0.00454609,
default = "m3/s",
link = "متر مكعب في الثانية",
},
["km3/a"] = {
name1 = "كيلومتر مكعب لكل سنة",
name2 = "كيلومتر مكعب لكل سنة",
name2_us = "cubic kilometers per annum",
symbol = "كم<sup>3</sup>/سنة",
utype = "flow",
scale = 31.68808781402895,
default = "cumi/a",
link = "متر مكعب في الثانية",
},
["km3/d"] = {
name1 = "كيلومتر مكعب لكل يوم",
name2 = "كيلومتر مكعب لكل يوم",
name2_us = "cubic kilometers per day",
symbol = "كم<sup>3</sup>/ي",
utype = "flow",
scale = 11574.074074074075,
default = "cuft/d",
link = "متر مكعب في الثانية",
},
["koilbbl/a"] = {
name1 = "ألف برميل لكل سنة",
name2 = "ألف برميل لكل سنة",
symbol = "ألف برميل/سنة",
utype = "flow",
scale = 5.0380033629933841e-6,
default = "v * 1.58987294928 < 10 ! ! e3 ! m3/a",
link = "برميل (نفط)",
},
["koilbbl/d"] = {
name1 = "ألف برميل لكل يوم",
name2 = "ألف برميل لكل يوم",
symbol = "ألف برميل/ي",
utype = "flow",
scale = 0.0018401307283333335,
default = "v * 1.58987294928 < 10 ! ! e3 ! m3/d",
link = "برميل (نفط)",
},
["L/h"] = {
name1 = "لتر لكل ساعة",
name2 = "لتر لكل ساعة",
name2_us = "liters per hour",
symbol = "ل/سا",
utype = "flow",
scale = 2.7777777777777776e-7,
default = "impgal/h USgal/h",
link = "متر مكعب في الثانية",
},
["L/min"] = {
name1 = "لتر لكل دقيقة",
name2 = "لتر لكل دقيقة",
name2_us = "liters per minute",
symbol = "ل/د",
utype = "flow",
scale = 1.6666666666666667e-5,
default = "impgal/min USgal/min",
link = "متر مكعب في الثانية",
},
["L/s"] = {
name1 = "لتر لكل ثانية",
name2 = "لتر لكل ثانية",
name2_us = "liters per second",
symbol = "ل/ث",
utype = "flow",
scale = 0.001,
default = "cuft/s",
link = "متر مكعب في الثانية",
},
["m3/a"] = {
name1 = "متر مكعب لكل سنة",
name2 = "متر مكعب لكل سنة",
name2_us = "cubic meters per annum",
symbol = "م<sup>3</sup>/سنة",
utype = "flow",
scale = 3.1688087814028947e-8,
default = "cuft/a",
link = "متر مكعب في الثانية",
},
["m3/d"] = {
name1 = "متر مكعب لكل يوم",
name2 = "متر مكعب لكل يوم",
name2_us = "cubic meters per day",
symbol = "م<sup>3</sup>/ي",
utype = "flow",
scale = 1.1574074074074073e-5,
default = "cuft/d",
link = "متر مكعب في الثانية",
},
["m3/h"] = {
name1 = "متر مكعب لكل ساعة",
name2 = "متر مكعب لكل ساعة",
name2_us = "cubic meters per hour",
symbol = "م<sup>3</sup>/سا",
utype = "flow",
scale = 0.00027777777777777778,
default = "cuft/h",
link = "متر مكعب في الثانية",
},
["m3/min"] = {
name1 = "متر مكعب لكل دقيقة",
name2 = "متر مكعب لكل دقيقة",
name2_us = "cubic meters per minute",
symbol = "م<sup>3</sup>/د",
utype = "flow",
scale = 0.016666666666666666,
default = "cuft/min",
link = "متر مكعب في الثانية",
},
["m3/s"] = {
name1 = "متر مكعب لكل ثانية",
name2 = "متر مكعب لكل ثانية",
name2_us = "cubic meters per second",
symbol = "م<sup>3</sup>/ث",
utype = "flow",
scale = 1,
default = "cuft/s",
link = "متر مكعب في الثانية",
},
["Moilbbl/a"] = {
name1 = "مليون برميل لكل سنة",
name2 = "مليون برميل لكل سنة",
symbol = "مليون برميل/سنة",
utype = "flow",
scale = 0.0050380033629933837,
default = "v * 1.58987294928 < 10 ! e3 ! e6 ! m3/a",
link = "برميل (نفط)",
},
["Moilbbl/d"] = {
name1 = "مليون برميل لكل يوم",
name2 = "مليون برميل لكل يوم",
symbol = "مليون برميل/ي",
utype = "flow",
scale = 1.8401307283333335,
default = "v * 1.58987294928 < 10 ! e3 ! e6 ! m3/d",
link = "برميل (نفط)",
},
["oilbbl/a"] = {
name1 = "برميل لكل سنة",
name2 = "برميل لكل سنة",
symbol = "برميل/سنة",
utype = "flow",
scale = 5.0380033629933841e-9,
default = "m3/a",
link = "برميل (نفط)",
},
["oilbbl/d"] = {
name1 = "برميل لكل يوم",
name2 = "برميل لكل يوم",
symbol = "برميل/ي",
utype = "flow",
scale = 1.8401307283333336e-6,
default = "m3/d",
link = "برميل (نفط)",
},
["Toilbbl/a"] = {
name1 = "تريليون برميل لكل سنة",
name2 = "تريليون برميل لكل سنة",
symbol = "تريليون برميل/سنة",
utype = "flow",
scale = 5038.0033629933832,
default = "v * 1.58987294928 < 10 ! e9 ! e12 ! m3/a",
link = "برميل (نفط)",
},
["U.S.gal/d"] = {
name1 = "جالون أمريكي لكل يوم",
name2 = "جالون أمريكي لكل يوم",
symbol = "جالون أمريكي/ي",
utype = "flow",
scale = 4.3812636388888893e-8,
default = "m3/s",
link = "U.S. gallon per day",
customary= 1,
},
["U.S.gal/h"] = {
name1 = "جالون لكل ساعة",
name2 = "جالون لكل ساعة",
symbol = "غالون/سا",
utype = "flow",
scale = 1.0515032733333334e-6,
default = "m3/h",
link = "غالون",
customary= 2,
},
["U.S.gal/min"] = {
name1 = "جالون أمريكي لكل دقيقة",
name2 = "جالون أمريكي لكل دقيقة",
symbol = "جالون أمريكي/د",
utype = "flow",
scale = 6.3090196400000003e-5,
default = "m3/s",
link = "غالون",
},
["USgal/a"] = {
name1 = "جالون أمريكي لكل سنة",
name2 = "جالون أمريكي لكل سنة",
symbol = "جالون أمريكي/سنة",
utype = "flow",
scale = 1.1995246102365199e-10,
default = "m3/s",
link = "US gallon per day",
},
["USgal/d"] = {
name1 = "جالون أمريكي لكل يوم",
name2 = "جالون أمريكي لكل يوم",
symbol = "جالون أمريكي/ي",
utype = "flow",
scale = 4.3812636388888893e-8,
default = "m3/s",
link = "US gallon per day",
},
["USgal/h"] = {
name1 = "جالون لكل ساعة",
name2 = "جالون لكل ساعة",
symbol = "جالون/سا",
utype = "flow",
scale = 1.0515032733333334e-6,
default = "m3/h",
link = "غالون",
customary= 1,
},
["USgal/min"] = {
name1 = "جالون أمريكي لكل دقيقة",
name2 = "جالون أمريكي لكل دقيقة",
symbol = "جالون أمريكي/د",
utype = "flow",
scale = 6.3090196400000003e-5,
default = "m3/s",
link = "غالون",
},
["USgal/s"] = {
name1 = "جالون أمريكي لكل ثانية",
name2 = "جالون أمريكي لكل ثانية",
name2_us = "U.S. gallons per second",
symbol = "جالون أمريكي/ثانية",
utype = "flow",
scale = 0.003785411784,
default = "m3/s",
link = "متر مكعب في الثانية",
},
["ft3/a"] = {
target = "cuft/a",
},
["ft3/d"] = {
target = "cuft/d",
},
["ft3/h"] = {
target = "cuft/h",
},
["ft3/s"] = {
target = "cuft/s",
},
["Gcuft/a"] = {
target = "e9cuft/a",
},
["Gcuft/d"] = {
target = "e9cuft/d",
},
["kcuft/a"] = {
target = "e3cuft/a",
},
["kcuft/d"] = {
target = "e3cuft/d",
},
["kcuft/s"] = {
target = "e3cuft/s",
},
["Mcuft/a"] = {
target = "e6cuft/a",
},
["Mcuft/d"] = {
target = "e6cuft/d",
},
["Mcuft/s"] = {
target = "e6cuft/s",
},
["m³/s"] = {
target = "m3/s",
},
["Tcuft/a"] = {
target = "e12cuft/a",
},
["Tcuft/d"] = {
target = "e12cuft/d",
},
["u.s.gal/min"] = {
target = "U.S.gal/min",
},
["usgal/min"] = {
target = "USgal/min",
},
["-LTf"] = {
name1 = "طن كبير ثقلي",
name1_us = "long ton-force",
name2_us = "long tons-force",
symbol = "LTf",
utype = "force",
scale = 9964.01641818352,
default = "kN",
link = "Long ton-force",
},
["-STf"] = {
name1 = "طن صغير ثقلي",
name1_us = "short ton-force",
name2_us = "short tons-force",
symbol = "STf",
utype = "force",
scale = 8896.443230521,
default = "kN",
link = "Short ton-force",
},
["dyn"] = {
symbol = "داين",
sym_us = "dyn",
utype = "force",
scale = 0.00001,
default = "gr-f",
},
["g-f"] = {
name1 = "غرام ثقلي",
name2 = "غرام ثقلي",
symbol = "غ<sub>ق</sub>",
utype = "force",
scale = 0.00980665,
default = "mN oz-f",
link = "كيلو غرام ثقلي",
},
["gf"] = {
name1 = "غرام ثقلي",
name2 = "غرام ثقلي",
symbol = "gf",
utype = "force",
scale = 0.00980665,
default = "mN ozf",
link = "كيلو غرام ثقلي",
},
["gr-f"] = {
name1_us = "grain-force",
name2_us = "grains-force",
symbol = "جر<sub>ق</sub>",
sym_us = "gr<sub>f</sub>",
utype = "force",
scale = 0.0006354602307515,
default = "μN",
link = "Pound-force",
},
["grf"] = {
name1_us = "grain-force",
name2_us = "grains-force",
symbol = "جر<sub>ق</sub>",
sym_us = "grf",
utype = "force",
scale = 0.0006354602307515,
default = "μN",
link = "Pound-force",
},
["kdyn"] = {
name1 = "كيلو داين",
symbol = "كـ.د",
sym_us = "kdyn",
utype = "force",
scale = 0.01,
default = "oz-f",
link = "داين",
},
["kg-f"] = {
name1 = "كيلو غرام ثقلي",
name2 = "كيلو غرام ثقلي",
symbol = "كجم<sub>ق</sub>",
sym_us = "kg<sub>f</sub>",
utype = "force",
scale = 9.80665,
default = "N lb-f",
},
["kgf"] = {
name1 = "كيلو غرام ثقلي",
name2 = "كيلو غرام ثقلي",
symbol = "كجم<sub>ق</sub>",
sym_us = "kg<sub>f</sub>",
utype = "force",
scale = 9.80665,
default = "N lbf",
},
["kp"] = {
name1 = "كيلورطل",
symbol = "kp",
utype = "force",
scale = 9.80665,
default = "N lb-f",
link = "كيلو غرام ثقلي",
},
["L/T-f"] = {
name1 = "طن كبير ثقلي",
name1_us = "long ton-force",
name2_us = "long tons-force",
symbol = "L/T<sub>ق</sub>",
sym_us = "L/T<sub>f</sub>",
utype = "force",
scale = 9964.01641818352,
default = "kN",
link = "Long ton-force",
},
["L/Tf"] = {
name1_us = "long ton-force",
name2 = "طن كبير ثقلي",
name2_us = "long tons-force",
symbol = "L/Tf",
utype = "force",
scale = 9964.01641818352,
default = "kN",
link = "Long ton-force",
},
["lb-f"] = {
name1_us = "pound-force",
name2_us = "pounds-force",
symbol = "رطل<sub>ق</sub>",
sym_us = "lb<sub>f</sub>",
utype = "force",
scale = 4.4482216152605,
default = "N",
link = "Pound-force",
},
["lbf"] = {
name1_us = "رطل ثقلي",
name2_us = "رطل ثقلي",
symbol = "رطل<sub>ق</sub>",
sym_us = "lb<sub>f</sub>",
utype = "force",
scale = 4.4482216152605,
default = "N",
link = "Pound-force",
},
["lb(f)"] = {
symbol = "رطل",
sym_us = "lb(f)",
utype = "force",
scale = 4.4482216152605,
default = "N",
link = "Pound-force",
},
["LT-f"] = {
name1 = "طن كبير ثقلي",
name1_us = "long ton-force",
name2_us = "long tons-force",
symbol = "LT<sub>ق</sub>",
sym_us = "LT<sub>f</sub>",
utype = "force",
scale = 9964.01641818352,
default = "kN",
link = "Long ton-force",
},
["LTf"] = {
name1 = "طن كبير ثقلي",
name1_us = "long ton-force",
name2_us = "long tons-force",
symbol = "LTf",
sym_us = "~LTf",
usename = 1,
utype = "force",
scale = 9964.01641818352,
default = "kN",
link = "Long ton-force",
},
["Mdyn"] = {
name1 = "ميجا داين",
symbol = "مج.داين",
sym_us = "Mdyn",
utype = "force",
scale = 10,
default = "lb-f",
link = "داين",
},
["mdyn"] = {
name1 = "ميلي داين",
symbol = "مـ.داين",
sym_us = "mdyn",
utype = "force",
scale = 0.00000001,
default = "gr-f",
link = "داين",
},
["mg-f"] = {
name1 = "ميلي غرام ثقلي",
name2 = "ميلي غرام ثقلي",
symbol = "مج<sub>ق</sub>",
sym_us = "mg<sub>f</sub>",
utype = "force",
scale = 0.00000980665,
default = "μN gr-f",
link = "كيلو غرام ثقلي",
},
["mgf"] = {
name1 = "ميلي غرام ثقلي",
name2 = "ميلي غرام ثقلي",
symbol = "مـغ.ق",
sym_us = "mgf",
utype = "force",
scale = 0.00000980665,
default = "μN grf",
link = "كيلو غرام ثقلي",
},
["Mp"] = {
name1 = "megapond",
symbol = "Mp",
utype = "force",
scale = 9806.65,
default = "kN LT-f ST-f",
link = "كيلو غرام ثقلي",
},
["mp"] = {
name1 = "millipond",
symbol = "mp",
utype = "force",
scale = 0.00000980665,
default = "μN gr-f",
link = "كيلو غرام ثقلي",
},
["N"] = {
_name1 = "نيوتن",
_name1_us= "newton",
_symbol = "ن",
_sym_us = "N",
utype = "force",
scale = 1,
prefixes = 1,
default = "lb-f",
link = "نيوتن (وحدة)",
},
["oz-f"] = {
name1_us = "ounce-force",
name2_us = "ounces-force",
symbol = "أوقية<sub>ق</sub>",
utype = "force",
scale = 0.2780138203095378125,
default = "mN",
link = "Pound-force",
},
["ozf"] = {
name1_us = "ounce-force",
name2_us = "ounces-force",
symbol = "ozf",
utype = "force",
scale = 0.2780138203095378125,
default = "mN",
link = "Pound-force",
},
["p"] = {
name1 = "pond",
symbol = "p",
utype = "force",
scale = 0.00980665,
default = "mN oz-f",
link = "كيلو غرام ثقلي",
},
["pdl"] = {
name1 = "باوندال",
symbol = "pdl",
utype = "force",
scale = 0.138254954376,
default = "N",
},
["S/T-f"] = {
name1 = "طن صغير ثقلي",
name1_us = "short ton-force",
name2_us = "short tons-force",
symbol = "S/T<sub>ق</sub>",
sym_us = "S/T<sub>f</sub>",
utype = "force",
scale = 8896.443230521,
default = "kN",
link = "Short ton-force",
},
["S/Tf"] = {
name1 = "طن صغير ثقلي",
name1_us = "short ton-force",
name2_us = "short tons-force",
symbol = "S/Tf",
utype = "force",
scale = 8896.443230521,
default = "kN",
link = "Short ton-force",
},
["ST-f"] = {
name1 = "طن صغير ثقلي",
name1_us = "short ton-force",
name2_us = "short tons-force",
symbol = "ST<sub>ق</sub>",
sym_us = "ST<sub>f</sub>",
utype = "force",
scale = 8896.443230521,
default = "kN",
link = "Short ton-force",
},
["STf"] = {
name1 = "طن صغير ثقلي",
name1_us = "short ton-force",
name2_us = "short tons-force",
symbol = "STf",
sym_us = "~STf",
usename = 1,
utype = "force",
scale = 8896.443230521,
default = "kN",
link = "Short ton-force",
},
["t-f"] = {
name1_us = "طن ثقلي",
name2_us = "طن ثقلي",
symbol = "طن<sub>ق</sub>",
sym_us = "t<sub>f</sub>",
utype = "force",
scale = 9806.65,
default = "kN LT-f ST-f",
link = "Ton-force#Tonne-force",
},
["tf"] = {
name1_us = "طن ثقلي",
name2_us = "طن ثقلي",
symbol = "طن<sub>ق</sub>",
sym_us = "tf",
utype = "force",
scale = 9806.65,
default = "kN LTf STf",
link = "Ton-force#Tonne-force",
},
["dyne"] = {
target = "dyn",
},
["newtons"] = {
target = "N",
},
["poundal"] = {
target = "pdl",
},
["tonne-force"] = {
target = "tf",
},
["impgal/mi"] = {
per = { "@impgal", "mi" },
utype = "fuel efficiency",
invert = 1,
iscomplex= true,
default = "l/km USgal/mi",
},
["km/L"] = {
per = { "km", "L" },
utype = "fuel efficiency",
invert = -1,
iscomplex= true,
default = "mpgimp mpgus",
},
["km/l"] = {
per = { "km", "l" },
utype = "fuel efficiency",
invert = -1,
iscomplex= true,
default = "mpgimp mpgus",
},
["L/100 km"] = {
per = { "L", "100km" },
utype = "fuel efficiency",
invert = 1,
iscomplex= true,
default = "mpgimp mpgus",
symlink = "[[استهلاك الوقود بالتنكة|ميل لكل جالون]]",
},
["l/100 km"] = {
per = { "l", "100km" },
utype = "fuel efficiency",
invert = 1,
iscomplex= true,
default = "mpgimp mpgus",
symlink = "[[استهلاك الوقود بالتنكة|ميل لكل جالون]]",
},
["L/km"] = {
per = { "L", "km" },
utype = "fuel efficiency",
invert = 1,
iscomplex= true,
default = "mpgimp mpgus",
},
["l/km"] = {
per = { "l", "km" },
utype = "fuel efficiency",
invert = 1,
iscomplex= true,
default = "mpgimp mpgus",
},
["mi/impqt"] = {
per = { "mi", "impqt" },
utype = "fuel efficiency",
invert = -1,
iscomplex= true,
default = "km/L",
},
["mi/U.S.qt"] = {
per = { "mi", "U.S.qt" },
utype = "fuel efficiency",
invert = -1,
iscomplex= true,
default = "km/L",
},
["mi/USqt"] = {
per = { "mi", "USqt" },
utype = "fuel efficiency",
invert = -1,
iscomplex= true,
default = "km/L",
},
["mi/usqt"] = {
per = { "mi", "usqt" },
utype = "fuel efficiency",
invert = -1,
iscomplex= true,
default = "km/L",
},
["mpgimp"] = {
per = { "mi", "@impgal" },
symbol = "mpg<sub>‑imp</sub>",
utype = "fuel efficiency",
invert = -1,
iscomplex= true,
default = "L/100 km+mpgus",
symlink = "[[استهلاك الوقود بالتنكة|ميل لكل جالون]]<sub>‑[[Imperial units|إمبراطوري]]</sub>",
},
["mpgus"] = {
per = { "mi", "+USgal" },
symbol = "mpg<sub>‑US</sub>",
utype = "fuel efficiency",
invert = -1,
iscomplex= true,
default = "L/100 km+mpgimp",
symlink = "[[استهلاك الوقود بالتنكة|ميل لكل جالون]]<sub>‑[[United States customary units|أمريكي]]</sub>",
},
["U.S.gal/mi"] = {
per = { "*U.S.gal", "mi" },
sp_us = true,
utype = "fuel efficiency",
invert = 1,
iscomplex= true,
default = "l/km impgal/mi",
},
["usgal/mi"] = {
per = { "+USgal", "mi" },
utype = "fuel efficiency",
invert = 1,
iscomplex= true,
default = "l/km impgal/mi",
},
["L/100km"] = {
target = "L/100 km",
},
["l/100km"] = {
target = "l/100 km",
},
["mpg"] = {
shouldbe = "Use %{mpgus%} for miles per US gallon or %{mpgimp%} for miles per imperial gallon (not %{mpg%})",
},
["mpgU.S."] = {
target = "mpgus",
symbol = "mpg<sub>‑U.S.</sub>",
sp_us = true,
symlink = "[[استهلاك الوقود بالتنكة|ميل لكل جالون]]<sub>‑[[United States customary units|أمريكي]]</sub>",
},
["mpgu.s."] = {
target = "mpgus",
symbol = "mpg<sub>‑U.S.</sub>",
sp_us = true,
symlink = "[[استهلاك الوقود بالتنكة|ميل لكل جالون]]<sub>‑[[United States customary units|أمريكي]]</sub>",
},
["mpgUS"] = {
target = "mpgus",
},
["USgal/mi"] = {
target = "usgal/mi",
},
["kPa/m"] = {
per = { "kPa", "-m-frac" },
utype = "fracture gradient",
default = "psi/ft",
},
["psi/ft"] = {
per = { "psi", "-ft-frac" },
utype = "fracture gradient",
default = "kPa/m",
},
["cm/km"] = {
name1 = "سنتيمتر لكل كيلومتر",
name2 = "سنتيمتر لكل كيلومتر",
name2_us = "centimeters per kilometer",
symbol = "سم/كم",
utype = "gradient",
scale = 0.00001,
default = "ft/mi",
link = "درجة انحدار",
},
["ft/mi"] = {
name1 = "قدم لكل ميل",
name2 = "قدم لكل ميل",
symbol = "قدم /ميل",
utype = "gradient",
scale = 0.00018939393939393939,
default = "v < 5.28 ! c ! ! m/km",
link = "درجة انحدار",
},
["ft/nmi"] = {
name1 = "قدم لكل ميل بحري",
name2 = "قدم لكل ميل بحري",
symbol = "قدم/ميل بحري",
utype = "gradient",
scale = 0.00016457883369330455,
default = "v < 6.076 ! c ! ! m/km",
link = "درجة انحدار",
},
["in/ft"] = {
name1 = "بوصة لكل القدم",
name2 = "بوصة لكل القدم",
symbol = "بوصة /قدم",
utype = "gradient",
scale = 0.083333333333333329,
default = "mm/m",
link = "درجة انحدار",
},
["in/mi"] = {
name1 = "بوصة لكل ميل",
name2 = "بوصة لكل ميل",
symbol = "بوصة /ميل",
utype = "gradient",
scale = 1.5782828282828283e-5,
default = "v < 0.6336 ! m ! c ! m/km",
link = "درجة انحدار",
},
["m/km"] = {
name1 = "متر لكل كيلومتر",
name2 = "متر لكل كيلومتر",
name2_us = "meters per kilometer",
symbol = "م/كم",
utype = "gradient",
scale = 0.001,
default = "ft/mi",
link = "درجة انحدار",
},
["mm/km"] = {
name1 = "ملليمتر لكل كيلومتر",
name2 = "ملليمتر لكل كيلومتر",
name2_us = "millimeters per kilometer",
symbol = "مم/كم",
utype = "gradient",
scale = 0.000001,
default = "in/mi",
link = "درجة انحدار",
},
["mm/m"] = {
name1 = "ملليمتر لكل متر",
name2 = "ملليمتر لكل متر",
name2_us = "millimeters per meter",
symbol = "مم/مم",
utype = "gradient",
scale = 0.001,
default = "in/ft",
link = "درجة انحدار",
},
["admi"] = {
name1 = "ميل بحري",
symbol = "nmi (admiralty)",
utype = "length",
scale = 1853.184,
default = "km mi",
},
["AU"] = {
name1 = "وحدة فلكية",
symbol = "AU",
utype = "length",
scale = 149597870700,
default = "km mi",
},
["Brnmi"] = {
name1 = "ميل بحري بريطاني",
symbol = "(Brit) nmi",
utype = "length",
scale = 1853.184,
default = "km mi",
link = "ميل بحري",
},
["bu"] = {
name2 = "bu",
symbol = "bu",
sym_us = "~bu",
usename = 1,
utype = "length",
scale = 0.0030303030303030303,
default = "mm",
link = "Japanese units of measurement#Length",
},
["ch"] = {
name1 = "سلسلة",
symbol = "ch",
utype = "length",
scale = 20.1168,
default = "ft m",
subdivs = { ["ft"] = { 66, default = "m" }, ["yd"] = { 22, default = "m" } },
link = "سلسلة (وحدة)",
},
["chlk"] = {
name1 = "[[Chain (unit)|chain]]",
symbol = "[[Chain (unit)|ch]]",
utype = "length",
scale = 20.1168,
default = "ft m",
link = "",
},
["chain"] = {
name1 = "سلسلة",
symbol = "chain",
sym_us = "~chain",
usename = 1,
utype = "length",
scale = 20.1168,
default = "ft m",
subdivs = { ["ft"] = { 66, default = "m" }, ["yd"] = { 22, default = "m" } },
link = "سلسلة (وحدة)",
},
["chainlk"] = {
symbol = "[[Chain (unit)|chain]]",
usename = 1,
utype = "length",
scale = 20.1168,
default = "ft m",
link = "",
},
["dpcm"] = {
name2 = "dot/cm",
symbol = "dot/cm",
utype = "length",
scale = 100,
invert = -1,
iscomplex= true,
default = "dpi",
link = "نقطة لكل بوصة",
},
["dpi"] = {
name2 = "DPI",
symbol = "DPI",
utype = "length",
scale = 39.370078740157481,
invert = -1,
iscomplex= true,
default = "pitch",
link = "نقطة لكل بوصة",
},
["fathom"] = {
name1 = "قامة",
symbol = "fathom",
sym_us = "~fathom",
usename = 1,
utype = "length",
scale = 1.8288,
default = "ft m",
},
["foot"] = {
name2 = "قدم",
symbol = "قدم",
utype = "length",
scale = 0.3048,
default = "m",
subdivs = { ["in"] = { 12, default = "m" } },
link = "قدم (وحدة قياس)",
},
["ft"] = {
name2 = "قدم",
symbol = "قدم",
sym_us = "ft",
utype = "length",
scale = 0.3048,
exception= "integer_more_precision",
default = "m",
subdivs = { ["in"] = { 12, default = "m" } },
link = "قدم (وحدة قياس)",
},
["furlong"] = {
name1 = "فرلنغ",
symbol = "furlong",
sym_us = "~furlong",
usename = 1,
utype = "length",
scale = 201.168,
default = "ft m",
},
["Gly"] = {
name1 = "جيجا سنة ضوئية",
symbol = "Gly",
utype = "length",
scale = 9.4607304725808e24,
default = "Mpc",
link = "سنة ضوئية",
},
["Gpc"] = {
name1 = "جيجا بارسيك",
symbol = "جـ.فخ",
sym_us = "Gpc",
utype = "length",
scale = 3.0856775814671916e25,
default = "Gly",
link = "فرسخ فلكي",
},
["hand"] = {
symbol = "يد",
sym_us = "hand",
utype = "length",
builtin = "hand",
scale = 0.1016,
iscomplex= true,
default = "in cm",
link = "يد (وحدة)",
},
["in"] = {
name2 = "بوصة",
symbol = "بوصة",
sym_us = "in",
utype = "length",
scale = 0.0254,
exception= "subunit_more_precision",
default = "mm",
},
["inabbreviated"] = {
name2 = "بوصة",
symbol = "بوصة",
sym_us = "inabbreviated",
utype = "length",
scale = 0.0254,
default = "mm",
},
["kly"] = {
name1 = "كيلو سنة ضوئية",
symbol = "kly",
utype = "length",
scale = 9.4607304725808e18,
default = "pc",
link = "سنة ضوئية",
},
["kpc"] = {
name1 = "كيلو بارسيك",
symbol = "ك.فخ",
sym_us = "kpc",
utype = "length",
scale = 3.0856775814671916e19,
default = "kly",
link = "فرسخ فلكي",
},
["LD"] = {
name1 = "بعد القمر",
symbol = "LD",
utype = "length",
scale = 384403000,
default = "km mi",
link = "بعد القمر (فلك)",
},
["league"] = {
symbol = "league",
sym_us = "~league",
usename = 1,
utype = "length",
scale = 4828.032,
default = "km",
link = "League (unit)",
},
["ly"] = {
name1 = "سنة ضوئية",
symbol = "ly",
utype = "length",
scale = 9.4607304725808e15,
default = "AU",
},
["m"] = {
_name1 = "متر",
_symbol = "م",
_sym_us = "m",
utype = "length",
scale = 1,
prefixes = 1,
default = "v > 0 and v < 3 ! ftin ! ft",
link = "متر",
},
["mi"] = {
symbol = "ميل",
sym_us = "mi",
utype = "length",
scale = 1609.344,
default = "km",
subdivs = { ["ch"] = { 80, default = "km" }, ["chlk"] = { 80, default = "km" }, ["chain"] = { 80, default = "km" }, ["chainlk"] = { 80, default = "km" }, ["ft"] = { 5280, default = "km" }, ["furlong"] = { 8, default = "km" }, ["yd"] = { 1760, default = "km" } },
},
["mil"] = {
symbol = "mil",
sym_us = "~mil",
usename = 1,
utype = "length",
scale = 0.0000254,
default = "mm",
link = "ألف من البوصة",
},
["Mly"] = {
name1 = "ميجا سنة ضوئية",
symbol = "Mly",
utype = "length",
scale = 9.4607304725808e21,
default = "kpc",
link = "سنة ضوئية",
},
["Mpc"] = {
name1 = "ميجا بارسيك",
symbol = "مج.فخ",
sym_us = "Mpc",
utype = "length",
scale = 3.0856775814671916e22,
default = "Mly",
link = "فرسخ فلكي",
},
["NM"] = {
name1 = "ميل بحري",
symbol = "NM",
utype = "length",
scale = 1852,
default = "km mi",
},
["nmi"] = {
name1 = "ميل بحري",
symbol = "nmi",
utype = "length",
scale = 1852,
default = "km mi",
},
["oldUKnmi"] = {
name1 = "ميل بحري",
symbol = "nmi",
utype = "length",
scale = 1853.184,
default = "km mi",
},
["oldUSnmi"] = {
name1 = "ميل بحري",
symbol = "nmi",
utype = "length",
scale = 1853.24496,
default = "km mi",
},
["pc"] = {
name1 = "فرسخ نجمي",
symbol = "فخ",
sym_us = "pc",
utype = "length",
scale = 3.0856775814671916e16,
default = "ly",
link = "فرسخ فلكي",
},
["perch"] = {
name1 = "قصبة",
name2 = "قصبة",
symbol = "perch",
sym_us = "~perch",
usename = 1,
utype = "length",
scale = 5.0292,
default = "ft m",
link = "قصبة (وحدة قياس)",
},
["pitch"] = {
name2 = "μm",
symbol = "μm",
sym_us = "*μm",
utype = "length",
scale = 1e-6,
default = "dpi",
defkey = "pitch",
linkey = "pitch",
link = "نقطة لكل بوصة",
},
["pole"] = {
symbol = "pole",
sym_us = "~pole",
usename = 1,
utype = "length",
scale = 5.0292,
default = "ft m",
link = "قصبة (وحدة قياس)",
},
["pre1954U.S.nmi"] = {
name1 = "(pre-1954 U.S.) nautical mile",
symbol = "(pre-1954 U.S.) nmi",
utype = "length",
scale = 1853.24496,
default = "km mi",
link = "ميل بحري",
},
["pre1954USnmi"] = {
name1 = "(pre-1954 US) nautical mile",
name1_us = "(pre-1954 U.S.) nautical mile",
symbol = "(pre-1954 US) nmi",
sym_us = "(pre-1954 U.S.) nmi",
utype = "length",
scale = 1853.24496,
default = "km mi",
link = "ميل بحري",
},
["rd"] = {
name1 = "rod",
symbol = "rd",
utype = "length",
scale = 5.0292,
default = "ft m",
link = "قصبة (وحدة قياس)",
},
["royal cubit"] = {
symbol = "ذراع",
sym_us = "royal cubit",
utype = "length",
scale = 0.524,
default = "mm",
link = "ذراع (وحدة قياس)",
},
["rtkm"] = {
name1 = "route kilometre",
name1_us = "route kilometer",
symbol = "كم",
sym_us = "rtkm",
utype = "length",
scale = 1000,
default = "mi",
link = "كيلومتر",
},
["rtmi"] = {
name1 = "route mile",
symbol = "ميل",
sym_us = "rtmi",
utype = "length",
scale = 1609.344,
default = "km",
link = "ميل",
},
["shaku"] = {
name2 = "shaku",
symbol = "shaku",
sym_us = "~shaku",
usename = 1,
utype = "length",
scale = 0.30303030303030304,
default = "m",
link = "Shaku (unit)",
},
["sm"] = {
symbol = "سموت",
sym_us = "sm",
utype = "length",
scale = 1.70180,
default = "m",
link = "سموت (وحدة)",
},
["smi"] = {
name1 = "statute mile",
symbol = "ميل",
sym_us = "smi",
utype = "length",
scale = 1609.344,
default = "km",
subdivs = { ["chain"] = { 80, default = "km" } },
link = "ميل",
},
["solar radius"] = {
name1 = "نصف قطر شمسي",
name2 = "نصف قطر شمسي",
symbol = "''نق''<sub>☉</sub>",
utype = "length",
scale = 695700e3,
default = "km",
},
["sun"] = {
name1 = "شمس",
name2 = "شمس",
symbol = "sun",
sym_us = "~sun",
usename = 1,
utype = "length",
scale = 0.030303030303030304,
default = "mm",
link = "Japanese units of measurement#Length",
},
["thou"] = {
name1 = "ألف بوصة",
name2 = "ألف بوصة",
symbol = "thou",
sym_us = "~thou",
usename = 1,
utype = "length",
scale = 0.0000254,
default = "mm",
},
["verst"] = {
name1 = "فرستا",
symbol = "verst",
sym_us = "~verst",
usename = 1,
utype = "length",
scale = 1066.8,
default = "km mi",
link = "فرستا (وحدة قياس)",
},
["yd"] = {
symbol = "يارد",
sym_us = "yd",
utype = "length",
scale = 0.9144,
default = "m",
subdivs = { ["ft"] = { 3, default = "m" } },
},
["μin"] = {
name1 = "ميكرو بوصة",
name2 = "ميكرو بوصة",
symbol = "مي.بوصة",
sym_us = "μin",
utype = "length",
scale = 0.0000000254,
default = "nm",
link = "سوابق النظام الدولي للوحدات",
},
["Å"] = {
name1 = "أنغستروم",
symbol = "أنغ",
sym_us = "Å",
utype = "length",
scale = 0.0000000001,
default = "in",
},
["Hz"] = {
_name1 = "هرتز",
_name2 = "هرتز",
_symbol = "هز",
_sym_us = "Hz",
utype = "length",
scale = 3.3356409519815204e-9,
invert = -1,
iscomplex= true,
prefixes = 1,
default = "m",
link = "هرتز",
},
["-ft-frac"] = {
target = "ft",
link = "تصديع مائي",
},
["-in-stiff"] = {
target = "in",
link = "جساءة",
},
["-m-frac"] = {
target = "m",
link = "تصديع مائي",
},
["-m-stiff"] = {
target = "m",
link = "جساءة",
},
["100km"] = {
target = "km",
multiplier= 100,
},
["admiralty nmi"] = {
target = "oldUKnmi",
},
["angstrom"] = {
target = "Å",
},
["au"] = {
target = "AU",
symbol = "au",
},
["feet"] = {
target = "ft",
},
["hands"] = {
target = "hand",
},
["inch"] = {
target = "in",
},
["light-year"] = {
target = "ly",
},
["meter"] = {
target = "m",
sp_us = true,
},
["meters"] = {
target = "m",
sp_us = true,
},
["metre"] = {
target = "m",
},
["متر"] = {
target = "m",
},
["م"] = {
target = "m",
},
["metres"] = {
target = "m",
},
["micrometre"] = {
target = "μm",
},
["micron"] = {
target = "μm",
default = "μin",
},
["mile"] = {
target = "mi",
},
["miles"] = {
target = "mi",
},
["parsec"] = {
target = "pc",
},
["rod"] = {
target = "rd",
},
["smoot"] = {
target = "sm",
},
["uin"] = {
target = "μin",
},
["yard"] = {
target = "yd",
},
["yards"] = {
target = "yd",
},
["yds"] = {
target = "yd",
},
["dtex"] = {
name1 = "ديسيتكس",
name2 = "ديسيتكس",
symbol = "د.تكس",
sym_us = "dtex",
utype = "linear density",
scale = 1e-7,
default = "lb/yd",
link = "نظام الوحدات في النسيج",
},
["kg/cm"] = {
name1 = "كيلوغرام لكل سنتيمتر",
name1_us = "kilogram per centimeter",
name2 = "كيلوغرام لكل سنتيمتر",
name2_us = "kilograms per centimeter",
symbol = "كجم/سم",
sym_us = "kg/cm",
utype = "linear density",
scale = 100,
default = "lb/yd",
link = "كثافة طولية",
},
["kg/m"] = {
name1 = "كيلوغرام لكل متر",
name1_us = "kilogram per meter",
name2_us = "kilograms per meter",
symbol = "كجم/م",
sym_us = "kg/m",
utype = "linear density",
scale = 1,
default = "lb/yd",
link = "كثافة طولية",
},
["lb/ft"] = {
name1 = "رطل لكل قدم",
symbol = "رطل/قدم",
sym_us = "lb/ft",
utype = "linear density",
scale = 1.4881639435695539,
default = "kg/m",
link = "كثافة طولية",
},
["lb/yd"] = {
name1 = "رطل لكل ياردة",
symbol = "رطل/ياردة",
sym_us = "lb/yd",
utype = "linear density",
scale = 0.49605464785651798,
default = "kg/m",
link = "كثافة طولية",
},
["G"] = {
_name1 = "غاوس",
_name2 = "غاوس",
_symbol = "جاوس",
_sym_us = "G",
utype = "magnetic field strength",
scale = 0.0001,
prefixes = 1,
default = "T",
link = "غاوس (وحدة)",
},
["T"] = {
_name1 = "تسلا",
_symbol = "تس",
_sym_us = "T",
utype = "magnetic field strength",
scale = 1,
prefixes = 1,
default = "G",
link = "تسلا (وحدة)",
},
["A/m"] = {
name1 = "أمبير لكل متر",
name1_us = "amperes per meter",
name2 = "أمبير لكل متر",
symbol = "أ/م",
sym_us = "A/m",
utype = "magnetizing field",
scale = 1,
default = "Oe",
link = "حقل مغناطيسي",
},
["kA/m"] = {
name1 = "كيلو أمبير لكل متر",
name1_us = "kiloamperes per meter",
name2 = "كيلو أمبير لكل متر",
symbol = "ك.أ/م",
sym_us = "kA/m",
utype = "magnetizing field",
scale = 1000,
default = "kOe",
link = "حقل مغناطيسي",
},
["MA/m"] = {
name1 = "ميجا أمبير لكل متر",
name1_us = "megaamperes per meter",
name2 = "ميجا أمبير لكل متر",
symbol = "مج.أ/م",
sym_us = "MA/m",
utype = "magnetizing field",
scale = 1e6,
default = "kOe",
link = "حقل مغناطيسي",
},
["Oe"] = {
_name1 = "أورستد",
_symbol = "Oe",
utype = "magnetizing field",
scale = 79.5774715,
prefixes = 1,
default = "kA/m",
link = "أورستد",
},
["-Lcwt"] = {
name1 = "hundredweight",
name2 = "hundredweight",
symbol = "cwt",
utype = "mass",
scale = 50.80234544,
default = "lb",
link = "القنطار",
},
["-Scwt"] = {
name1 = "hundredweight",
name2 = "hundredweight",
symbol = "cwt",
utype = "mass",
scale = 45.359237,
default = "lb",
link = "القنطار",
},
["-ST"] = {
name1 = "طن صغير",
name1_us = "short ton",
symbol = "طن.صغير",
sym_us = "ST",
utype = "mass",
scale = 907.18474,
default = "t",
link = "طن أمريكي",
},
["carat"] = {
name1 = "قيراط",
symbol = "carat",
sym_us = "~carat",
usename = 1,
utype = "mass",
scale = 0.0002,
default = "g",
link = "قيراط (وحدة كتلة)",
},
["drachm"] = {
name1_us = "dram",
symbol = "drachm",
sym_us = "~drachm",
usename = 1,
utype = "mass",
scale = 0.001771845195,
default = "g",
link = "Dram (unit)",
},
["dram"] = {
target = "drachm",
},
["dwt"] = {
name1 = "pennyweight",
symbol = "dwt",
utype = "mass",
scale = 0.00155517384,
default = "oz g",
},
["DWton"] = {
symbol = "deadweight ton",
sym_us = "~deadweight ton",
usename = 1,
utype = "mass",
scale = 1016.0469088,
default = "DWtonne",
link = "حمولة السفينة",
},
["DWtonne"] = {
symbol = "deadweight tonne",
sym_us = "~deadweight tonne",
usename = 1,
utype = "mass",
scale = 1000,
default = "DWton",
link = "حمولة السفينة",
},
["g"] = {
_name1 = "غرام",
_symbol = "غ",
_sym_us = "g",
utype = "mass",
scale = 0.001,
prefixes = 1,
default = "oz",
link = "غرام (وحدة قياس)",
},
["gr"] = {
name1 = "grain",
symbol = "gr",
utype = "mass",
scale = 0.00006479891,
default = "g",
link = "Grain (unit)",
},
["Gt"] = {
name1 = "جيجا طن",
symbol = "جـ.طن",
sym_us = "Gt",
utype = "mass",
scale = 1000000000000,
default = "LT ST",
link = "طن",
},
["impgalh2o"] = {
name1 = "imperial gallon of water",
name2 = "imperial gallons of water",
symbol = "imp gal H<sub>2</sub>O",
utype = "mass",
scale = 4.5359236999999499,
default = "lb kg",
link = "غالون",
},
["kt"] = {
name1 = "كيلو طن",
symbol = "ك.طن",
sym_us = "kt",
utype = "mass",
scale = 1000000,
default = "LT ST",
link = "طن",
},
["lb"] = {
symbol = "رطل",
sym_us = "lb",
utype = "mass",
scale = 0.45359237,
exception= "integer_more_precision",
default = "kg",
subdivs = { ["oz"] = { 16, default = "kg" } },
},
["Lcwt"] = {
name1 = "long hundredweight",
name2 = "long hundredweight",
symbol = "Lcwt",
sym_us = "~Lcwt",
usename = 1,
utype = "mass",
scale = 50.80234544,
default = "lb",
subdivs = { ["qtr"] = { 4, default = "kg" }, ["st"] = { 8, default = "kg" } },
link = "القنطار",
},
["long cwt"] = {
name1 = "long hundredweight",
name2 = "long hundredweight",
symbol = "long cwt",
utype = "mass",
scale = 50.80234544,
default = "lb kg",
subdivs = { ["qtr"] = { 4, default = "kg" } },
link = "القنطار",
},
["long qtr"] = {
name1 = "long quarter",
symbol = "long qtr",
utype = "mass",
scale = 12.70058636,
default = "lb kg",
link = "أفردوبويز",
},
["LT"] = {
name1 = "طن كبير",
name1_us = "long ton",
symbol = "long ton",
sym_us = "~long ton",
usename = 1,
utype = "mass",
scale = 1016.0469088,
default = "t",
subdivs = { ["Lcwt"] = { 20, default = "t", unit = "-Lcwt" } },
link = "Long ton",
},
["lt"] = {
name1 = "طن كبير",
name1_us = "long ton",
symbol = "LT",
utype = "mass",
scale = 1016.0469088,
default = "t",
subdivs = { ["Lcwt"] = { 20, default = "t", unit = "-Lcwt" } },
link = "Long ton",
},
["metric ton"] = {
name1 = "طن متري",
symbol = "metric ton",
sym_us = "~metric ton",
usename = 1,
utype = "mass",
scale = 1000,
default = "long ton",
link = "طن",
},
["MT"] = {
name1 = "طن متري",
symbol = "طن",
sym_us = "MT",
utype = "mass",
scale = 1000,
default = "LT ST",
link = "طن",
},
["Mt"] = {
name1 = "ميجا طن",
symbol = "مج.طن",
sym_us = "Mt",
utype = "mass",
scale = 1000000000,
default = "LT ST",
link = "طن",
},
["oz"] = {
symbol = "أونصة",
sym_us = "oz",
utype = "mass",
scale = 0.028349523125,
default = "g",
},
["ozt"] = {
name1 = "أوقية ترويسية",
symbol = "ozt",
utype = "mass",
scale = 0.0311034768,
default = "oz g",
link = "الأوقية الترويسية",
},
["pdr"] = {
name1 = "رطل",
symbol = "pdr",
utype = "mass",
scale = 0.45359237,
default = "kg",
},
["qtr"] = {
name1 = "quarter",
symbol = "qtr",
utype = "mass",
scale = 12.70058636,
default = "lb kg",
subdivs = { ["lb"] = { 28, default = "kg" } },
link = "أفردوبويز",
},
["Scwt"] = {
name1 = "short hundredweight",
name2 = "short hundredweight",
symbol = "Scwt",
sym_us = "~Scwt",
usename = 1,
utype = "mass",
scale = 45.359237,
default = "lb",
link = "القنطار",
},
["short cwt"] = {
name1 = "short hundredweight",
name2 = "short hundredweight",
symbol = "short cwt",
utype = "mass",
scale = 45.359237,
default = "lb kg",
link = "القنطار",
},
["short qtr"] = {
name1 = "short quarter",
symbol = "short qtr",
utype = "mass",
scale = 11.33980925,
default = "lb kg",
link = "أفردوبويز",
},
["ST"] = {
name1 = "طن صغير",
name1_us = "short ton",
symbol = "short ton",
sym_us = "~short ton",
usename = 1,
utype = "mass",
scale = 907.18474,
default = "t",
subdivs = { ["Scwt"] = { 20, default = "t", unit = "-Scwt" } },
link = "طن أمريكي",
},
["shtn"] = {
name1 = "طن صغير",
name1_us = "short ton",
symbol = "short ton",
sym_us = "sh tn",
usename = 1,
utype = "mass",
scale = 907.18474,
default = "t",
link = "طن أمريكي",
},
["shton"] = {
symbol = "ton",
sym_us = "~ton",
usename = 1,
utype = "mass",
scale = 907.18474,
default = "t",
link = "طن",
},
["solar mass"] = {
name1 = "solar mass",
name2 = "solar masses",
symbol = "''M''<sub>☉</sub>",
utype = "mass",
scale = 1.98855e30,
default = "kg",
link = "كتلة شمسية",
},
["st"] = {
name2 = "ستون",
symbol = "ستون",
sym_us = "st",
utype = "mass",
scale = 6.35029318,
default = "lb kg",
subdivs = { ["lb"] = { 14, default = "kg lb" } },
link = "ستون (وحدة)",
},
["t"] = {
name1 = "طن",
name2 = "طن متري",
symbol = "t",
utype = "mass",
scale = 1000,
default = "LT ST",
},
["tonne"] = {
name2 = "طن متري",
symbol = "طن",
sym_us = "t",
utype = "mass",
scale = 1000,
default = "shton",
},
["troy pound"] = {
symbol = "troy pound",
sym_us = "~troy pound",
usename = 1,
utype = "mass",
scale = 0.3732417216,
default = "lb kg",
link = "وزن تروي",
},
["usgalh2o"] = {
name1 = "US gallon of water",
name2 = "جالون أمريكي من الماء",
name2_us = "U.S. gallons of water",
symbol = "US gal H<sub>2</sub>O",
utype = "mass",
scale = 3.7776215836051126,
default = "lb kg",
link = "وحدات قياس عرفية أمريكية",
},
["viss"] = {
name2 = "viss",
symbol = "viss",
utype = "mass",
scale = 1.632932532,
default = "kg",
link = "Burmese units of measurement#mass",
},
["billion tonne"] = {
target = "e9t",
},
["kilogram"] = {
target = "kg",
},
["kilotonne"] = {
target = "kt",
},
["lbs"] = {
target = "lb",
},
["lbt"] = {
target = "troy pound",
},
["lcwt"] = {
target = "Lcwt",
},
["long ton"] = {
target = "LT",
},
["mcg"] = {
target = "μg",
},
["million tonne"] = {
target = "e6t",
},
["scwt"] = {
target = "Scwt",
},
["short ton"] = {
target = "ST",
},
["stone"] = {
target = "st",
},
["thousand tonne"] = {
target = "e3t",
},
["tonnes"] = {
target = "t",
},
["kg/kW"] = {
name1 = "كيلوغرام لكل كيلووات",
name2 = "كيلوغرام لكل كيلووات",
symbol = "kg/kW",
utype = "mass per unit power",
scale = 0.001,
default = "lb/hp",
link = "واط",
},
["lb/hp"] = {
name1 = "رطل لكل حصان",
name2 = "رطل لكل حصان",
symbol = "lb/hp",
utype = "mass per unit power",
scale = 0.00060827738784176115,
default = "kg/kW",
link = "حصان (وحدة قدرة)",
},
["kg/h"] = {
per = { "kg", "h" },
utype = "mass per unit time",
default = "lb/h",
},
["lb/h"] = {
per = { "lb", "h" },
utype = "mass per unit time",
default = "kg/h",
},
["g-mol/d"] = {
name1 = "جرام مول في اليوم",
name2 = "جرام مول في اليوم",
symbol = "غ-مول/ي",
utype = "molar rate",
scale = 1.1574074074074073e-5,
default = "μmol/s",
link = "مول",
},
["g-mol/h"] = {
name1 = "جرام مول في الساعة",
name2 = "جرام مول في الساعة",
symbol = "غ-مول/سا",
utype = "molar rate",
scale = 0.00027777777777777778,
default = "mmol/s",
link = "مول",
},
["g-mol/min"] = {
name1 = "جرام مول في الدقيقة",
name2 = "جرام مول في الدقيقة",
symbol = "غ-مول/د",
utype = "molar rate",
scale = 0.016666666666666666,
default = "g-mol/s",
link = "مول",
},
["g-mol/s"] = {
name1 = "جرام مول في الثانية",
name2 = "جرام مول في الثانية",
symbol = "غ-مول/ثا",
utype = "molar rate",
scale = 1,
default = "lb-mol/min",
link = "مول",
},
["gmol/d"] = {
name1 = "جرام مول في اليوم",
name2 = "جرام مول في اليوم",
symbol = "غ-مول/ي",
utype = "molar rate",
scale = 1.1574074074074073e-5,
default = "μmol/s",
link = "مول",
},
["gmol/h"] = {
name1 = "جرام مول في الساعة",
name2 = "جرام مول في الساعة",
symbol = "غ-مول/سا",
utype = "molar rate",
scale = 0.00027777777777777778,
default = "mmol/s",
link = "مول",
},
["gmol/min"] = {
name1 = "جرام مول في الدقيقة",
name2 = "جرام مول في الدقيقة",
symbol = "غ-مول/د",
utype = "molar rate",
scale = 0.016666666666666666,
default = "gmol/s",
link = "مول",
},
["gmol/s"] = {
name1 = "جرام مول في الثانية",
name2 = "جرام مول في الثانية",
symbol = "غ-مول/ثا",
utype = "molar rate",
scale = 1,
default = "lbmol/min",
link = "مول",
},
["kmol/d"] = {
name1 = "كيلو مول في اليوم",
name2 = "كيلو مول في اليوم",
symbol = "ك.مول/ي",
utype = "molar rate",
scale = 0.011574074074074073,
default = "mmol/s",
link = "مول",
},
["kmol/h"] = {
name1 = "كيلو مول في الساعة",
name2 = "كيلو مول في الساعة",
symbol = "ك.مول/سا",
utype = "molar rate",
scale = 0.27777777777777779,
default = "mol/s",
link = "مول",
},
["kmol/min"] = {
name1 = "كيلو مول في الدقيقة",
name2 = "كيلو مول في الدقيقة",
symbol = "ك.مول/د",
utype = "molar rate",
scale = 16.666666666666668,
default = "mol/s",
link = "مول",
},
["kmol/s"] = {
name1 = "كيلو مول في الثانية",
name2 = "كيلو مول في الثانية",
symbol = "ك.مول/ثا",
utype = "molar rate",
scale = 1000,
default = "lb-mol/s",
link = "مول",
},
["lb-mol/d"] = {
name1 = "رطل مول في اليوم",
name2 = "رطل مول في اليوم",
symbol = "رطل مول/ي",
utype = "molar rate",
scale = 0.0052499116898148141,
default = "mmol/s",
link = "مول",
},
["lb-mol/h"] = {
name1 = "رطل مول في الساعة",
name2 = "رطل مول في الساعة",
symbol = "رطل مول/ي",
utype = "molar rate",
scale = 0.12599788055555555,
default = "mol/s",
link = "مول",
},
["lb-mol/min"] = {
name1 = "رطل مول في الدقيقة",
name2 = "رطل مول في الدقيقة",
symbol = "رطل مول/د",
utype = "molar rate",
scale = 7.5598728333333334,
default = "mol/s",
link = "مول",
},
["lb-mol/s"] = {
name1 = "رطل مول في الثانية",
name2 = "رطل مول في الثانية",
symbol = "رطل مول/ثا",
utype = "molar rate",
scale = 453.59237,
default = "kmol/s",
link = "مول",
},
["lbmol/d"] = {
name1 = "رطل مول في اليوم",
name2 = "رطل مول في اليوم",
symbol = "رطل مول/ي",
utype = "molar rate",
scale = 0.0052499116898148141,
default = "mmol/s",
link = "مول",
},
["lbmol/h"] = {
name1 = "رطل مول في الساعة",
name2 = "رطل مول في الساعة",
symbol = "رطل مول/سا",
utype = "molar rate",
scale = 0.12599788055555555,
default = "mol/s",
link = "مول",
},
["lbmol/min"] = {
name1 = "رطل مول في الدقيقة",
name2 = "رطل مول في الدقيقة",
symbol = "رطل مول/د",
utype = "molar rate",
scale = 7.5598728333333334,
default = "mol/s",
link = "مول",
},
["lbmol/s"] = {
name1 = "رطل مول في الثانية",
name2 = "رطل مول في الثانية",
symbol = "رطل مول/ثا",
utype = "molar rate",
scale = 453.59237,
default = "kmol/s",
link = "مول",
},
["mmol/s"] = {
name1 = "مللي مول في الثانية",
name2 = "مللي مول في الثانية",
symbol = "ميلي مول/ثا",
utype = "molar rate",
scale = 0.001,
default = "lb-mol/d",
link = "مول",
},
["mol/d"] = {
name1 = "مول في اليوم",
name2 = "مول في اليوم",
symbol = "مول/ي",
utype = "molar rate",
scale = 1.1574074074074073e-5,
default = "μmol/s",
link = "مول",
},
["mol/h"] = {
name1 = "مول في الساعة",
name2 = "مول في الساعة",
symbol = "مول/سا",
utype = "molar rate",
scale = 0.00027777777777777778,
default = "mmol/s",
link = "مول",
},
["mol/min"] = {
name1 = "مول في الدقيقة",
name2 = "مول في الدقيقة",
symbol = "مول/د",
utype = "molar rate",
scale = 0.016666666666666666,
default = "mol/s",
link = "مول",
},
["mol/s"] = {
name1 = "مول في الثانية",
name2 = "مول في الثانية",
symbol = "مول/ثا",
utype = "molar rate",
scale = 1,
default = "lb-mol/min",
link = "مول",
},
["μmol/s"] = {
name1 = "ميكرو مول في الثانية",
name2 = "ميكرو مول في الثانية",
symbol = "ميكرو مول/ثا",
utype = "molar rate",
scale = 0.000001,
default = "lb-mol/d",
link = "مول",
},
["umol/s"] = {
target = "μmol/s",
},
["/acre"] = {
name1 = "لكل أكر",
name2 = "لكل أكر",
symbol = "/أكر",
utype = "per unit area",
scale = 247.10538146716533,
default = "/ha",
link = "أكر",
},
["/ha"] = {
name1 = "لكل هكتار",
name2 = "لكل هكتار",
symbol = "/ها",
utype = "per unit area",
scale = 100,
default = "/acre",
link = "هكتار",
},
["/sqcm"] = {
name1 = "لكل سنتيمتر مربع",
name1_us = "per square centimeter",
name2 = "لكل سنتيمتر مربع",
symbol = "/سم<sup>2</sup>",
utype = "per unit area",
scale = 1e10,
default = "/sqin",
link = "متر مربع",
},
["/sqin"] = {
name1 = "لكل بوصة مربعة",
name2 = "لكل بوصة مربعة",
symbol = "/بوصة<sup>2</sup>",
utype = "per unit area",
scale = 1550003100.0062001,
default = "/sqcm",
link = "بوصة مربعة",
},
["/sqkm"] = {
name1 = "لكل كيلومتر مربع",
name1_us = "per square kilometer",
name2 = "لكل كيلومتر مربع",
symbol = "/كم<sup>2</sup>",
utype = "per unit area",
scale = 1,
default = "/sqmi",
link = "كيلومتر مربع",
},
["/sqmi"] = {
name1 = "لكل ميل مربع",
name2 = "لكل ميل مربع",
symbol = "/ميل<sup>2</sup>",
utype = "per unit area",
scale = 0.38610215854244584,
default = "/sqkm",
link = "ميل مربع",
},
["PD/acre"] = {
name1 = "نسمة لكل أكر",
name1_us = "inhabitant per acre",
symbol = "/أكر",
utype = "per unit area",
scale = 247.10538146716533,
default = "PD/ha",
link = "أكر",
},
["PD/ha"] = {
name1 = "نسمة لكل هكتار",
name1_us = "inhabitant per hectare",
symbol = "/ها",
sym_us = "/acre",
utype = "per unit area",
scale = 100,
default = "PD/acre",
link = "هكتار",
},
["PD/sqkm"] = {
name1 = "نسمة لكل كيلومتر مربع",
name1_us = "inhabitant per square kilometre",
name2 = "نسمة لكل كيلومتر مربع",
name2_us = "inhabitants per square kilometer",
symbol = "/كم<sup>2</sup>",
utype = "per unit area",
scale = 1,
default = "PD/sqmi",
link = "كيلومتر مربع",
},
["PD/sqmi"] = {
name1 = "نسمة لكل ميل مربع",
name1_us = "inhabitant per square mile",
symbol = "/ميل<sup>2</sup>",
utype = "per unit area",
scale = 0.38610215854244584,
default = "PD/sqkm",
link = "ميل مربع",
},
["/cm2"] = {
target = "/sqcm",
},
["/in2"] = {
target = "/sqin",
},
["/km2"] = {
target = "/sqkm",
},
["pd/acre"] = {
target = "PD/acre",
},
["pd/ha"] = {
target = "PD/ha",
},
["PD/km2"] = {
target = "PD/sqkm",
},
["pd/km2"] = {
target = "PD/sqkm",
},
["PD/km²"] = {
target = "PD/sqkm",
},
["pd/sqkm"] = {
target = "PD/sqkm",
},
["pd/sqmi"] = {
target = "PD/sqmi",
},
["/l"] = {
name1 = "لكل لتر",
name1_us = "per liter",
name2 = "لكل لتر",
name2_us = "per liter",
symbol = "/ل",
utype = "per unit volume",
scale = 1000,
default = "/usgal",
link = "لتر",
},
["/USgal"] = {
name1 = "لكل غالون",
name2 = "لكل غالون",
symbol = "/غ",
utype = "per unit volume",
scale = 264.172052,
default = "/l",
link = "غالون",
customary= 2,
},
["/usgal"] = {
target = "/USgal",
},
["bhp"] = {
name1 = "brake horsepower",
name2 = "كبح حصاني",
symbol = "bhp",
utype = "power",
scale = 745.69987158227022,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["Cal/d"] = {
name1 = "large calorie per day",
name2 = "large سعرة لكل يوم",
symbol = "Cal/d",
utype = "power",
scale = 0.048425925925925928,
default = "kJ/d",
link = "سعرة",
},
["Cal/h"] = {
name1 = "large calorie per hour",
name2 = "large سعرة لكل ساعة",
symbol = "Cal/h",
utype = "power",
scale = 1.1622222222222223,
default = "kJ/h",
link = "سعرة",
},
["cal/h"] = {
name1 = "سعرة في الساعة",
name2 = "سعرة في الساعة",
symbol = "cal/h",
utype = "power",
scale = 0.0011622222222222223,
default = "W",
link = "سعرة",
},
["CV"] = {
name1 = "حصان متري",
name2 = "حصان متري",
symbol = "CV",
utype = "power",
scale = 735.49875,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["hk"] = {
name1 = "حصان متري",
name2 = "حصان متري",
symbol = "hk",
utype = "power",
scale = 735.49875,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["hp"] = {
name1 = "حصان",
name2 = "حصان",
symbol = "حصان",
utype = "power",
scale = 745.69987158227022,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["hp-electric"] = {
name1 = "حصان كهربائي",
name2 = "حصان كهربائي",
symbol = "hp",
utype = "power",
scale = 746,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["hp-electrical"] = {
name1 = "حصان كهربائي",
name2 = "حصان كهربائي",
symbol = "hp",
utype = "power",
scale = 746,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["hp-metric"] = {
name1 = "حصان متري",
name2 = "حصان متري",
symbol = "hp",
utype = "power",
scale = 735.49875,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["ihp"] = {
name1 = "indicated horsepower",
name2 = "indicated حصان",
symbol = "ihp",
utype = "power",
scale = 745.69987158227022,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["kcal/h"] = {
name1 = "كيلو سعرة كل ساعة",
name2 = "كيلو سعرة كل ساعة",
symbol = "kcal/h",
utype = "power",
scale = 1.1622222222222223,
default = "kW",
link = "سعرة",
},
["kJ/d"] = {
name1 = "كيلو جول كل يوم",
name2 = "كيلو جول كل يوم",
symbol = "kJ/d",
utype = "power",
scale = 0.011574074074074073,
default = "Cal/d",
link = "جول",
},
["kJ/h"] = {
name1 = "كيلو جول كل ساعة",
name2 = "كيلو جول كل ساعة",
symbol = "kJ/h",
utype = "power",
scale = 0.27777777777777779,
default = "W",
link = "جول",
},
["PS"] = {
name1 = "حصان متري",
name2 = "حصان متري",
symbol = "PS",
utype = "power",
scale = 735.49875,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["shp"] = {
name1 = "shaft horsepower",
name2 = "shaft حصان",
symbol = "shp",
utype = "power",
scale = 745.69987158227022,
default = "kW",
link = "حصان (وحدة قدرة)",
},
["W"] = {
_name1 = "واط",
_symbol = "و",
utype = "power",
scale = 1,
prefixes = 1,
default = "hp",
link = "واط",
},
["BTU/h"] = {
per = { "BTU", "h" },
utype = "power",
default = "W",
},
["Btu/h"] = {
per = { "Btu", "h" },
utype = "power",
default = "W",
},
["BHP"] = {
target = "bhp",
},
["btu/h"] = {
target = "BTU/h",
},
["HP"] = {
target = "hp",
},
["Hp"] = {
target = "hp",
},
["hp-mechanical"] = {
target = "hp",
},
["IHP"] = {
target = "ihp",
},
["SHP"] = {
target = "shp",
},
["whp"] = {
target = "hp",
},
["hp/lb"] = {
name1 = "حصان لكل رطل",
name1_us = "horsepower per pound",
symbol = "hp/lb",
utype = "power per unit mass",
scale = 1643.986806,
default = "kW/kg",
link = "نسبة القوة إلى الوزن",
},
["hp/LT"] = {
name1 = "حصان لكل طن كبير",
name1_us = "horsepower per long ton",
symbol = "hp/LT",
utype = "power per unit mass",
scale = 0.73392268125000004,
default = "kW/t",
link = "نسبة القوة إلى الوزن",
},
["hp/ST"] = {
name1 = "حصان لكل طن صغير",
name1_us = "horsepower per short ton",
symbol = "hp/ST",
utype = "power per unit mass",
scale = 0.821993403,
default = "kW/t",
link = "نسبة القوة إلى الوزن",
},
["hp/t"] = {
name1 = "حصان لكل طن",
name1_us = "horsepower per tonne",
symbol = "hp/t",
utype = "power per unit mass",
scale = 0.74569987158227022,
default = "kW/t",
link = "نسبة القوة إلى الوزن",
},
["kW/kg"] = {
name1 = "كيلو وات لكل كيلوجرام",
name1_us = "kilowatt per kilogram",
symbol = "kW/kg",
utype = "power per unit mass",
scale = 1000,
default = "hp/lb",
link = "نسبة القوة إلى الوزن",
},
["kW/t"] = {
name1 = "كيلو وات لكل طن",
name1_us = "kilowatt per tonne",
symbol = "kW/t",
utype = "power per unit mass",
scale = 1,
default = "PS/t",
link = "نسبة القوة إلى الوزن",
},
["PS/t"] = {
name1 = "حصان متري لكل طن",
name1_us = "metric horsepower per tonne",
symbol = "PS/t",
utype = "power per unit mass",
scale = 0.73549875,
default = "kW/t",
link = "نسبة القوة إلى الوزن",
},
["shp/lb"] = {
name1 = "shaft حصان لكل رطل",
name1_us = "shaft horsepower per pound",
symbol = "shp/lb",
utype = "power per unit mass",
scale = 1643.986806,
default = "kW/kg",
link = "نسبة القوة إلى الوزن",
},
["hp/tonne"] = {
target = "hp/t",
symbol = "hp/tonne",
default = "kW/tonne",
},
["kW/tonne"] = {
target = "kW/t",
symbol = "kW/tonne",
},
["-lb/in2"] = {
name1 = "رطل لكل بوصة مربعة",
name1_us = "pound per square inch",
name2 = "رطل لكل بوصة مربعة",
symbol = "lb/in<sup>2</sup>",
utype = "pressure",
scale = 6894.7572931683608,
default = "kPa kgf/cm2",
link = "رطل على البوصة المربعة",
},
["atm"] = {
name1_us = "standard atmosphere",
symbol = "جو",
sym_us = "atm",
utype = "pressure",
scale = 101325,
default = "kPa",
link = "جو (وحدة)",
},
["Ba"] = {
name1 = "ميكروبار",
name1_us = "Barye",
name2 = "باري",
symbol = "مي.بار",
sym_us = "Ba",
utype = "pressure",
scale = 0.1,
default = "Pa",
link = "بار",
},
["bar"] = {
name1_us = "bar",
name2_us = "bar",
symbol = "بار",
sym_us = "bar",
utype = "pressure",
scale = 100000,
default = "kPa",
},
["dbar"] = {
name1 = "ديسي بار",
name1_us = "decibar",
symbol = "د.بار",
sym_us = "dbar",
utype = "pressure",
scale = 10000,
default = "kPa",
link = "بار",
},
["inHg"] = {
name1 = "بوصة زئبقية",
name1_us = "inch of mercury",
name2_us = "inches of mercury",
symbol = "inHg",
utype = "pressure",
scale = 3386.388640341,
default = "kPa",
link = "زئبق",
},
["kBa"] = {
name1 = "كيلوباري",
name1_us = "kilobarye",
symbol = "ك.بار",
sym_us = "kBa",
utype = "pressure",
scale = 100,
default = "hPa",
link = "بار",
},
["kg-f/cm2"] = {
name1 = "كيلو جرام-قوة لكل سنتيمتر مربع",
name1_us = "kilogram-force per square centimetre",
name2 = "كيلو جرام-قوة لكل سنتيمتر مربع",
name2_us = "kilograms-force per square centimeter",
symbol = "كجم<sub>ق</sub>/سم<sup>2</sup>",
sym_us = "kg<sub>f</sub>/cm<sup>2</sup>",
utype = "pressure",
scale = 98066.5,
default = "psi",
link = "كيلو غرام ثقلي",
},
["kg/cm2"] = {
name1 = "كيلو جرام لكل سنتيمتر مربع",
name1_us = "kilogram per square centimetre",
name2 = "كيلو جرام لكل سنتيمتر مربع",
name2_us = "kilograms per square centimeter",
symbol = "كجم/سم<sup>2</sup>",
sym_us = "kg/cm2",
utype = "pressure",
scale = 98066.5,
default = "psi",
link = "كيلو غرام ثقلي",
},
["kgf/cm2"] = {
name1 = "كيلو جرام-قوة لكل سنتيمتر مربع",
name1_us = "kilogram-force per square centimetre",
name2 = "كيلو جرام-قوة لكل سنتيمتر مربع",
name2_us = "kilograms-force per square centimeter",
symbol = "كجم<sub>ق</sub>/سم<sup>2</sup>",
sym_us = "kgf/cm<sup>2</sup>",
utype = "pressure",
scale = 98066.5,
default = "psi",
link = "كيلو غرام ثقلي",
},
["ksi"] = {
name1 = "كيلورطل لكل بوصة مربعة",
name1_us = "kilopound per square inch",
name2 = "كيلورطل لكل بوصة مربعة",
symbol = "ksi",
utype = "pressure",
scale = 6894757.2931683613,
default = "MPa",
link = "رطل على البوصة المربعة",
},
["lbf/in2"] = {
name1 = "رطل-قوة لكل بوصة مربعة",
name1_us = "pound-force per square inch",
name2 = "رطل-قوة لكل بوصة مربعة",
symbol = "رطل<sub>ق</sub>/بوصة<sup>2</sup>",
sym_us = "lbf/in<sup>2</sup>",
utype = "pressure",
scale = 6894.7572931683608,
default = "kPa kgf/cm2",
link = "رطل على البوصة المربعة",
},
["mb"] = {
name1 = "ميليبار",
name2 = "ميليبار",
symbol = "مـم.بار",
sym_us = "mb",
utype = "pressure",
scale = 100,
default = "hPa",
link = "بار",
},
["mbar"] = {
name1 = "ميليبار",
name2 = "ميليبار",
symbol = "مـم.بار",
sym_us = "mbar",
utype = "pressure",
scale = 100,
default = "hPa",
link = "بار",
},
["mmHg"] = {
name1 = "ملليمتر من الزئبق",
name1_us = "millimetre of mercury",
name2 = "ملليمتر من الزئبق",
name2_us = "millimeters of mercury",
symbol = "مـم.زئبق",
sym_us = "mmHg",
utype = "pressure",
scale = 133.322387415,
default = "kPa",
link = "ميليمتر زئبقي",
},
["Pa"] = {
_name1 = "باسكال",
_symbol = "با",
_sym_us = "Pa",
utype = "pressure",
scale = 1,
prefixes = 1,
default = "psi",
link = "باسكال (وحدة)",
},
["psf"] = {
name1 = "رطل لكل قدم مربع",
name1_us = "pound per square foot",
symbol = "psf",
utype = "pressure",
scale = 47.880258980335839,
default = "kPa",
link = "رطل على البوصة المربعة",
},
["psi"] = {
name1 = "رطل لكل بوصة مربعة",
name1_us = "pound per square inch",
symbol = "psi",
utype = "pressure",
scale = 6894.7572931683608,
default = "kPa",
link = "رطل على البوصة المربعة",
},
["Torr"] = {
name1_us = "Torr",
symbol = "تور",
sym_us = "Torr",
utype = "pressure",
scale = 133.32236842105263,
default = "kPa",
link = "تور (وحدة)",
},
["N/cm2"] = {
per = { "N", "cm2" },
utype = "pressure",
default = "psi",
},
["N/m2"] = {
per = { "N", "m2" },
utype = "pressure",
default = "psi",
},
["g/cm2"] = {
per = { "g", "cm2" },
utype = "pressure",
default = "lb/sqft",
multiplier= 9.80665,
},
["g/m2"] = {
per = { "g", "m2" },
utype = "pressure",
default = "lb/sqft",
multiplier= 9.80665,
},
["kg/ha"] = {
per = { "kg", "ha" },
utype = "pressure",
default = "lb/acre",
multiplier= 9.80665,
},
["kg/m2"] = {
per = { "kg", "m2" },
utype = "pressure",
default = "lb/sqft",
multiplier= 9.80665,
},
["lb/1000sqft"] = {
per = { "lb", "1000sqft" },
utype = "pressure",
default = "g/m2",
multiplier= 9.80665,
},
["lb/acre"] = {
per = { "lb", "acre" },
utype = "pressure",
default = "kg/ha",
multiplier= 9.80665,
},
["lb/sqft"] = {
per = { "lb", "sqft" },
utype = "pressure",
default = "kg/m2",
multiplier= 9.80665,
},
["lb/sqyd"] = {
per = { "lb", "sqyd" },
utype = "pressure",
default = "kg/m2",
multiplier= 9.80665,
},
["LT/acre"] = {
per = { "LT", "acre" },
utype = "pressure",
default = "t/ha",
multiplier= 9.80665,
},
["MT/ha"] = {
per = { "MT", "ha" },
utype = "pressure",
default = "LT/acre ST/acre",
multiplier= 9.80665,
},
["oz/sqft"] = {
per = { "oz", "sqft" },
utype = "pressure",
default = "g/m2",
multiplier= 9.80665,
},
["oz/sqyd"] = {
per = { "oz", "sqyd" },
utype = "pressure",
default = "g/m2",
multiplier= 9.80665,
},
["ST/acre"] = {
per = { "ST", "acre" },
utype = "pressure",
default = "t/ha",
multiplier= 9.80665,
},
["t/ha"] = {
per = { "t", "ha" },
utype = "pressure",
default = "LT/acre ST/acre",
multiplier= 9.80665,
},
["tonne/acre"] = {
per = { "tonne", "acre" },
utype = "pressure",
default = "tonne/ha",
multiplier= 9.80665,
},
["tonne/ha"] = {
per = { "tonne", "ha" },
utype = "pressure",
default = "tonne/acre",
multiplier= 9.80665,
},
["kgfpsqcm"] = {
target = "kgf/cm2",
},
["kgpsqcm"] = {
target = "kg/cm2",
},
["kN/m2"] = {
target = "kPa",
},
["lb/in2"] = {
target = "lbf/in2",
},
["torr"] = {
target = "Torr",
},
["Bq"] = {
_name1 = "بيكريل",
_symbol = "بيك",
_sym_us = "Bq",
utype = "radioactivity",
scale = 1,
prefixes = 1,
default = "pCi",
link = "بيكريل",
},
["Ci"] = {
_name1 = "كوري",
_symbol = "كور",
_sym_us = "Ci",
utype = "radioactivity",
scale = 3.7e10,
prefixes = 1,
default = "GBq",
link = "كوري (وحدة)",
},
["Rd"] = {
_name1 = "رذرفورد",
_name1_us= "rutherford",
_symbol = "Rd",
utype = "radioactivity",
scale = 1e6,
prefixes = 1,
default = "MBq",
link = "رذرفورد",
},
["cm/h"] = {
name1 = "سنتيمتر كل ساعة",
name1_us = "centimeters per hour",
name2 = "سنتيمتر كل ساعة",
symbol = "سم/س",
utype = "speed",
scale = 2.7777777777777775e-6,
default = "in/h",
link = "متر في الثانية",
},
["cm/s"] = {
name1 = "سنتيمتر في الثانية",
name1_us = "centimeters per second",
name2 = "سنتيمتر في الثانية",
symbol = "سم/ث",
utype = "speed",
scale = 0.01,
default = "in/s",
link = "متر في الثانية",
},
["cm/year"] = {
name1 = "سنتيمتر سنويا",
name1_us = "centimeters per year",
name2 = "سنتيمتر سنويا",
symbol = "سم/سنة",
utype = "speed",
scale = 3.168873850681143e-10,
default = "in/year",
link = "قيم أسية (سرعة)",
},
["foot/s"] = {
name1 = "قدم في الثانية",
name2 = "قدم في الثانية",
symbol = "قدم/ث",
utype = "speed",
scale = 0.3048,
default = "m/s",
link = "Feet per second",
},
["ft/min"] = {
name1 = "قدم في الدقيقة",
name2 = "قدم في الدقيقة",
symbol = "قدم/د",
utype = "speed",
scale = 0.00508,
default = "m/min",
link = "Feet per second",
},
["ft/s"] = {
name1 = "قدم في الثانية",
name2 = "قدم في الثانية",
symbol = "قدم/ث",
utype = "speed",
scale = 0.3048,
default = "m/s",
link = "Feet per second",
},
["furlong per fortnight"] = {
name1 = "furlongs لكل fortnight",
name1_us = "furlong per fortnight",
symbol = "furlong per fortnight",
usename = 1,
utype = "speed",
scale = 0.00016630952380952381,
default = "km/h mph",
link = "FFF System",
},
["in/h"] = {
name1 = "بوصة في الساعة",
name2 = "بوصة في الساعة",
symbol = "in/h",
utype = "speed",
scale = 7.0555555555555559e-6,
default = "cm/h",
link = "بوصة",
},
["in/s"] = {
name1 = "بوصة في الثانية",
name2 = "بوصة في الثانية",
symbol = "بوصة/ث",
utype = "speed",
scale = 0.0254,
default = "cm/s",
link = "بوصة",
},
["in/year"] = {
name1 = "بوصة في السنة",
name2 = "بوصة في السنة",
symbol = "بوصة/سنة",
utype = "speed",
scale = 8.0489395807301024e-10,
default = "cm/year",
link = "قيم أسية (سرعة)",
},
["isp"] = {
name1 = "ثانية",
name1_us = "second",
name2 = "ثوان",
symbol = "س",
sym_us = "s",
utype = "speed",
scale = 9.80665,
default = "km/s",
link = "اندفاع نوعي",
},
["km/d"] = {
name1 = "كيلومتر في اليوم",
name1_us = "kilometers per day",
name2 = "كيلومتر في اليوم",
symbol = "كم/ي",
utype = "speed",
scale = 1.1574074074074074e-2,
default = "mi/d",
link = "قيم أسية (سرعة)",
},
["km/h"] = {
name1 = "كيلومتر في الساعة",
name1_us = "kilometers per hour",
name2 = "كيلومتر في الساعة",
symbol = "كم/س",
utype = "speed",
scale = 0.27777777777777779,
default = "mph",
},
["km/s"] = {
name1 = "كيلومتر في الثانية",
name1_us = "kilometers per second",
name2 = "كيلومتر في الثانية",
symbol = "كم/ث",
utype = "speed",
scale = 1000,
default = "mi/s",
link = "متر في الثانية",
},
["kn"] = {
symbol = "عقدة",
sym_us = "kn",
utype = "speed",
scale = 0.51444444444444448,
default = "km/h mph",
link = "عقدة (وحدة)",
},
["kNs/kg"] = {
name2 = "kN-s/kg",
symbol = "kN-s/kg",
utype = "speed",
scale = 1000,
default = "isp",
link = "اندفاع نوعي",
},
["m/min"] = {
name1 = "متر في الدقيقة",
name1_us = "meters per minute",
name2 = "متر في الدقيقة",
symbol = "م/د",
utype = "speed",
scale = 0.016666666666666666,
default = "ft/min",
link = "متر في الثانية",
},
["m/s"] = {
name1 = "متر في الثانية",
name1_us = "meters per second",
name2 = "متر في الثانية",
symbol = "م/ث",
utype = "speed",
scale = 1,
default = "ft/s",
},
["Mach"] = {
name2 = "ماخ",
symbol = "ماخ",
sym_us = "Mach",
utype = "speed",
builtin = "mach",
scale = 0,
iscomplex= true,
default = "mph km/h",
link = "عدد ماخ",
},
["mi/d"] = {
name1 = "ميل في اليوم",
name2 = "ميل في اليوم",
symbol = "ميل/ي",
utype = "speed",
scale = 1.8626666666666667e-2,
default = "km/d",
link = "قيم أسية (سرعة)",
},
["mi/s"] = {
name1 = "ميل في الثانية",
name2 = "ميل في الثانية",
symbol = "ميل/ث",
utype = "speed",
scale = 1609.344,
default = "km/s",
link = "ميل",
},
["mm/h"] = {
name1 = "ملليمتر كل ساعة",
name1_us = "millimeters per hour",
name2 = "ملليمتر كل ساعة",
symbol = "مم/س",
utype = "speed",
scale = 2.7777777777777781e-7,
default = "in/h",
link = "متر في الثانية",
},
["mph"] = {
name1 = "ميل في الساعة",
name2 = "ميل في الساعة",
symbol = "ميل/س",
sym_us = "mph",
utype = "speed",
scale = 0.44704,
default = "km/h",
},
["Ns/kg"] = {
name2 = "N-s/kg",
symbol = "N-s/kg",
utype = "speed",
scale = 1,
default = "isp",
link = "اندفاع نوعي",
},
["si tsfc"] = {
name2 = "g/(kN·s)",
symbol = "g/(kN·s)",
utype = "speed",
scale = 9.9999628621379242e-7,
invert = -1,
iscomplex= true,
default = "tsfc",
link = "Thrust specific fuel consumption",
},
["tsfc"] = {
name2 = "lb/(lbf·h)",
symbol = "lb/(lbf·h)",
utype = "speed",
scale = 2.832545036049801e-5,
invert = -1,
iscomplex= true,
default = "si tsfc",
link = "Thrust specific fuel consumption",
},
["cm/y"] = {
target = "cm/year",
},
["cm/yr"] = {
target = "cm/year",
},
["in/y"] = {
target = "in/year",
},
["in/yr"] = {
target = "in/year",
},
["knot"] = {
target = "kn",
},
["knots"] = {
target = "kn",
},
["kph"] = {
target = "km/h",
},
["mi/h"] = {
target = "mph",
},
["mm/s"] = {
per = { "mm", "s" },
utype = "speed",
default = "in/s",
link = "متر في الثانية",
},
["C"] = {
name1 = "درجة مئوية",
name2 = "درجة مئوية",
symbol = "°م",
sym_us = "°C",
usesymbol= 1,
utype = "temperature",
scale = 1,
offset = -273.15,
iscomplex= true,
istemperature= true,
default = "F",
link = "درجة حرارة مئوية",
},
["F"] = {
name1 = "درجة فهرنهايت",
name2 = "درجة فهرنهايت",
symbol = "°ف",
sym_us = "°F",
usesymbol= 1,
utype = "temperature",
scale = 0.55555555555555558,
offset = 32-273.15*(9/5),
iscomplex= true,
istemperature= true,
default = "C",
link = "فهرنهايت",
},
["K"] = {
_name1 = "كلفن",
_name2 = "kelvin",
_symbol = "ك",
_sym_us = "K",
usesymbol= 1,
utype = "temperature",
scale = 1,
offset = 0,
iscomplex= true,
istemperature= true,
prefixes = 1,
default = "C F",
link = "كلفن",
},
["keVT"] = {
name1 = "كيلو إلكترون فولت",
symbol = "ك.إف",
sym_us = "keV",
utype = "temperature",
scale = 11.604505e6,
offset = 0,
iscomplex= true,
default = "MK",
link = "إلكترون فولت",
},
["R"] = {
name1 = "درجة رانكين",
name2 = "درجة رانكين",
symbol = "°ر",
sym_us = "°R",
usesymbol= 1,
utype = "temperature",
scale = 0.55555555555555558,
offset = 0,
iscomplex= true,
istemperature= true,
default = "K F C",
link = "مقياس رانكين",
},
["Celsius"] = {
target = "C",
},
["°C"] = {
target = "C",
},
["°F"] = {
target = "F",
},
["°R"] = {
target = "R",
},
["C-change"] = {
name1 = "تغير درجة مئوية",
name1_us = "degree Celsius change",
name2_us = "degrees Celsius change",
symbol = "°م",
sym_us = "°C",
usesymbol= 1,
utype = "temperature change",
scale = 1,
default = "F-change",
link = "درجة حرارة مئوية",
},
["F-change"] = {
name1 = "تغير درجة فهرنهايت",
name1_us = "degree Fahrenheit change",
name2_us = "degrees Fahrenheit change",
symbol = "°ف",
sym_us = "°F",
usesymbol= 1,
utype = "temperature change",
scale = 0.55555555555555558,
default = "C-change",
link = "فهرنهايت",
},
["K-change"] = {
name1 = "تغير كلفن",
name1_us = "kelvin change",
name2_us = "kelvins change",
symbol = "ك",
sym_us = "K",
usesymbol= 1,
utype = "temperature change",
scale = 1,
default = "F-change",
link = "كلفن",
},
["°C-change"] = {
target = "C-change",
},
["°F-change"] = {
target = "F-change",
},
["century"] = {
name1 = "قرن",
name2 = "قرون",
symbol = "ha",
utype = "time",
scale = 3155760000,
default = "Gs",
link = "قرن (زمن)",
},
["d"] = {
name1 = "يوم",
name2 = "أيام",
symbol = "ي",
sym_us = "d",
utype = "time",
scale = 86400,
default = "ks",
},
["decade"] = {
name1 = "عقد",
name2 = "عقود",
symbol = "daa",
utype = "time",
scale = 315576000,
default = "Ms",
link = "عقد (وقت)",
},
["dog year"] = {
name1 = "dog year",
symbol = "dog yr",
utype = "time",
scale = 220903200,
default = "years",
},
["fortnight"] = {
symbol = "fortnight",
sym_us = "~fortnight",
usename = 1,
utype = "time",
scale = 1209600,
default = "week",
},
["h"] = {
name1 = "ساعة",
name2 = "ساعات",
symbol = "سا",
sym_us = "h",
utype = "time",
scale = 3600,
default = "ks",
link = "ساعة (وحدة)",
},
["long billion year"] = {
name1 = "بليون سنة",
name2 = "بليون سنة",
symbol = "Ta",
utype = "time",
scale = 31557600000000000000,
default = "Es",
link = "سنة",
},
["millennium"] = {
name1 = "ألفية",
name2 = "ألفيات",
symbol = "ka",
utype = "time",
scale = 31557600000,
default = "Gs",
},
["milliard year"] = {
name1 = "مليار سنة",
name2 = "مليار سنة",
symbol = "Ga",
utype = "time",
scale = 31557600000000000,
default = "Ps",
link = "سنة",
},
["million year"] = {
name1 = "مليون سنة",
name2 = "مليون سنة",
symbol = "Ma",
utype = "time",
scale = 31557600000000,
default = "Ts",
link = "سنة",
},
["min"] = {
name1 = "دقيقة",
symbol = "د",
sym_us = "min",
utype = "time",
scale = 60,
default = "s",
},
["month"] = {
symbol = "month",
sym_us = "~month",
usename = 1,
utype = "time",
scale = 2629800,
default = "Ms",
link = "شهر",
},
["months"] = {
name1 = "month",
symbol = "mo",
utype = "time",
scale = 2629800,
default = "year",
link = "شهر",
},
["s"] = {
_name1 = "ثانية",
_symbol = "ثا",
_sym_us = "s",
utype = "time",
scale = 1,
prefixes = 1,
default = "min",
link = "ثانية",
},
["short billion year"] = {
name1 = "بليون سنة",
name2 = "بليون سنة",
symbol = "Ga",
utype = "time",
scale = 31557600000000000,
default = "Ps",
link = "سنة",
},
["short trillion year"] = {
name1 = "تريليون سنة",
name2 = "تريليون سنة",
symbol = "Ta",
utype = "time",
scale = 31557600000000000000,
default = "Es",
link = "سنة",
},
["thousand million year"] = {
name1 = "ألف مليون سنة",
name2 = "ألف مليون سنة",
symbol = "Ga",
utype = "time",
scale = 31557600000000000,
default = "Ps",
link = "سنة",
},
["wk"] = {
name1 = "أسبوع",
symbol = "week",
sym_us = "~week",
usename = 1,
utype = "time",
scale = 604800,
default = "Ms",
},
["year"] = {
name1 = "سنة",
symbol = "a",
utype = "time",
scale = 31557600,
default = "Ms",
},
["years"] = {
name1 = "سنة",
symbol = "yr",
utype = "time",
scale = 31557600,
default = "Ms",
},
["byr"] = {
target = "short billion year",
},
["day"] = {
target = "d",
},
["days"] = {
target = "d",
},
["dog yr"] = {
target = "dog year",
},
["Gyr"] = {
target = "thousand million year",
},
["hour"] = {
target = "h",
},
["hours"] = {
target = "h",
},
["kMyr"] = {
target = "thousand million year",
},
["kmyr"] = {
target = "thousand million year",
},
["kyr"] = {
target = "millennium",
},
["long byr"] = {
target = "long billion year",
},
["minute"] = {
target = "min",
},
["minutes"] = {
target = "min",
},
["mth"] = {
target = "month",
},
["Myr"] = {
target = "million year",
},
["myr"] = {
target = "million year",
},
["second"] = {
target = "s",
},
["seconds"] = {
target = "s",
},
["tmyr"] = {
target = "thousand million year",
},
["tryr"] = {
target = "short trillion year",
},
["tyr"] = {
target = "millennium",
},
["week"] = {
target = "wk",
},
["weeks"] = {
target = "wk",
},
["yr"] = {
target = "year",
},
["kg.m"] = {
name1 = "كيلو غرام·متر",
name2 = "كيلو غرام·متر",
symbol = "كجم·م",
sym_us = "kg·m",
utype = "torque",
scale = 9.80665,
default = "Nm lbft",
link = "كيلو غرام ثقلي",
},
["kgf.m"] = {
name1 = "كيلو غرام ثقلي·متر",
name1_us = "kilogram force-metre",
name2 = "كيلو غرام ثقلي·متر",
symbol = "كجم<sub>ق</sub>·م",
sym_us = "kgf·m",
utype = "torque",
scale = 9.80665,
default = "Nm lbfft",
link = "كيلو غرام ثقلي",
},
["kgm"] = {
name1 = "كيلو غرام·متر",
name2 = "كيلو غرام·متر",
symbol = "كجم·م",
sym_us = "kg·m",
utype = "torque",
scale = 9.80665,
default = "Nm lbfft",
link = "كيلو غرام ثقلي",
},
["lb-fft"] = {
name1 = "رطل قوة-قدم",
name1_us = "pound force-foot",
name2 = "رطل قوة-قدم",
symbol = "قدم·رطل<sub>ق</sub>",
sym_us = "ft·lb<sub>f</sub>",
utype = "torque",
scale = 1.3558179483314004,
default = "Nm",
link = "رطل قدم (عزم)",
},
["lb.ft"] = {
name1 = "رطل قوة-قدم",
name1_us = "pound force-foot",
name2 = "رطل قوة-قدم",
symbol = "قدم·رطل",
sym_us = "lb·ft",
utype = "torque",
scale = 1.3558179483314004,
default = "Nm",
link = "رطل قدم (عزم)",
},
["lb.in"] = {
name1 = "رطل قوة-بوصة",
name1_us = "pound force-inch",
name2 = "رطل قوة-بوصة",
symbol = "رطل·بوصة",
sym_us = "lb·in",
utype = "torque",
scale = 0.1129848290276167,
default = "mN.m",
link = "رطل قدم (عزم)",
},
["lbfft"] = {
name1 = "رطل قوة-قدم",
name1_us = "pound force-foot",
name2 = "رطل قوة-قدم",
symbol = "رطل<sub>ق</sub>·قدم",
sym_us = "lbf·ft",
utype = "torque",
scale = 1.3558179483314004,
default = "Nm",
link = "رطل قدم (عزم)",
},
["lbft"] = {
name1 = "رطل قدم",
name2 = "رطل قدم",
symbol = "رطل·قدم",
sym_us = "lb·ft",
utype = "torque",
scale = 1.3558179483314004,
default = "Nm",
link = "رطل قدم (عزم)",
},
["m.kg-f"] = {
name1 = "متر كيلو غرام ثقلي",
name1_us = "meter kilograms-force",
name2 = "متر كيلو غرام ثقلي",
symbol = "م·كجم<sub>ق</sub>",
sym_us = "m·kg<sub>f</sub>",
utype = "torque",
scale = 9.80665,
default = "Nm lbfft",
link = "كيلو غرام ثقلي",
},
["m.kgf"] = {
name1 = "متر كيلو غرام ثقلي",
name1_us = "meter kilograms-force",
name2 = "متر كيلو غرام ثقلي",
symbol = "م·كجم<sub>ق</sub>",
sym_us = "m·kgf",
utype = "torque",
scale = 9.80665,
default = "Nm lbfft",
link = "كيلو غرام ثقلي",
},
["mN.m"] = {
name1 = "ملي نيوتن لكل متر",
name2 = "ملي نيوتن لكل متر",
symbol = "مـن·م",
sym_us = "mN·m",
utype = "torque",
scale = 0.001,
default = "lb.in",
link = "نيوتن متر",
},
["Nm"] = {
name1 = "نيوتن لكل متر",
name2 = "نيوتن لكل متر",
symbol = "ن·م",
sym_us = "N·m",
utype = "torque",
alttype = "energy",
scale = 1,
default = "lbfft",
link = "نيوتن متر",
},
["kN/m"] = {
per = { "kN", "-m-stiff" },
utype = "torque",
default = "lbf/in",
},
["lbf/in"] = {
per = { "lbf", "-in-stiff" },
utype = "torque",
default = "kN/m",
},
["lb-f.ft"] = {
target = "lb-fft",
},
["lb-f·ft"] = {
target = "lb-fft",
},
["lbf.ft"] = {
target = "lbfft",
},
["lbf·ft"] = {
target = "lbfft",
},
["lb·ft"] = {
target = "lb.ft",
},
["mkg-f"] = {
target = "m.kg-f",
},
["mkgf"] = {
target = "m.kgf",
},
["N.m"] = {
target = "Nm",
},
["N·m"] = {
target = "Nm",
},
["-12USoz(mL)serve"] = {
name2_us = "12 U.S. fl oz (355 mL) serving",
symbol = "12 US fl oz (355 mL) serving",
sym_us = "12 U.S. fl oz (355 mL) serving",
utype = "volume",
scale = 0.00035488235475000004,
default = "mL",
link = "عبوة المشروبات",
},
["-12USoz(ml)serve"] = {
name2_us = "12 U.S. fl oz (355 ml) serving",
symbol = "12 US fl oz (355 ml) serving",
sym_us = "12 U.S. fl oz (355 ml) serving",
utype = "volume",
scale = 0.00035488235475000004,
default = "ml",
link = "عبوة المشروبات",
},
["-12USozserve"] = {
name2_us = "12 U.S. fl oz serving",
symbol = "12 US fl oz serving",
sym_us = "12 U.S. fl oz serving",
utype = "volume",
scale = 0.00035488235475000004,
default = "mL",
link = "عبوة المشروبات",
},
["acre foot"] = {
name1 = "قدم فدان",
name2 = "قدم فدان",
symbol = "acre·ft",
utype = "volume",
scale = 1233.48183754752,
default = "m3",
},
["acre ft"] = {
name1 = "قدم فدان",
name2 = "قدم فدان",
symbol = "acre·ft",
utype = "volume",
scale = 1233.48183754752,
default = "m3",
},
["AUtbsp"] = {
name1_us = "Australian tablespoon",
symbol = "AU tbsp",
utype = "volume",
scale = 0.000020,
default = "ml",
link = "Australian tablespoon",
},
["Bcuft"] = {
name1 = "billion cubic foot",
name2 = "billion cubic feet",
symbol = "billion cu ft",
utype = "volume",
scale = 28316846.592,
default = "Gl",
link = "Cubic foot",
},
["bdft"] = {
name1_us = "board foot",
symbol = "bd ft",
utype = "volume",
scale = 0.0023597372167,
default = "m3",
link = "Board foot",
},
["board feet"] = {
symbol = "board foot",
usename = 1,
utype = "volume",
scale = 0.0023597372167,
default = "m3",
},
["board foot"] = {
symbol = "board foot",
usename = 1,
utype = "volume",
scale = 0.0023597372167,
default = "m3",
},
["cc"] = {
name1 = "سنتيمتر مكعب",
name2 = "سنتيمتر مكعب",
symbol = "سم<sup>3</sup>",
utype = "volume",
scale = 0.000001,
default = "cuin",
},
["CID"] = {
name1 = "بوصة مكعبة",
name1_us = "cubic inch",
symbol = "بوصة<sup>3</sup>",
utype = "volume",
scale = 0.000016387064,
default = "cc",
},
["cord"] = {
symbol = "cord",
utype = "volume",
scale = 3.624556363776,
default = "m3",
link = "Cord (unit)",
},
["cufoot"] = {
name1 = "قدم مكعب",
name2 = "قدم مكعب",
symbol = "قدم<sup>3</sup>",
utype = "volume",
scale = 0.028316846592,
default = "m3",
},
["cuft"] = {
name1 = "قدم مكعب",
name2 = "قدم مكعب",
symbol = "قدم<sup>3</sup>",
utype = "volume",
scale = 0.028316846592,
default = "m3",
},
["cuin"] = {
name1 = "بوصة مكعبة",
name2 = "بوصة مكعبة",
symbol = "بوصة<sup>3</sup>",
utype = "volume",
scale = 0.000016387064,
default = "cm3",
},
["cumi"] = {
name1 = "ميل مكعب",
symbol = "ميل<sup>3</sup>",
utype = "volume",
scale = 4168181825.440579584,
default = "km3",
},
["cuyd"] = {
name1 = "يارد مكعب",
symbol = "ياردة<sup>3</sup>",
utype = "volume",
scale = 0.764554857984,
default = "m3",
},
["firkin"] = {
symbol = "firkin",
usename = 1,
utype = "volume",
scale = 0.04091481,
default = "l impgal USgal",
},
["foot3"] = {
target = "cufoot",
},
["Goilbbl"] = {
name1 = "بليون برميل",
name1_us = "billion barrels",
symbol = "جـ.برميل",
sym_us = "Gbbl",
utype = "volume",
scale = 158987294.928,
default = "v * 1.58987294928 < 10 ! e6 ! e9 ! m3",
link = "برميل (نفط)",
},
["gr water"] = {
name1_us = "grains water",
name2_us = "grains water",
symbol = "gr H<sub>2</sub>O",
sym_us = "| gr H<sub>2</sub>O",
utype = "volume",
scale = 0.00000006479891,
default = "cm3",
link = "Grain (unit)",
},
["grt"] = {
name1_us = "gross register ton",
symbol = "grt",
utype = "volume",
scale = 2.8316846592,
default = "m3",
link = "Gross register tonnage",
},
["impbbl"] = {
name1 = "برميل إمبراطوري",
name1_us = "imperial barrel",
symbol = "برميل إمب",
sym_us = "imp bbl",
utype = "volume",
scale = 0.16365924,
default = "l impgal USgal",
link = "برميل (نفط)",
},
["impbsh"] = {
name1 = "بوشل إمبراطوري",
name1_us = "imperial bushel",
symbol = "بوشل إمب",
sym_us = "imp bsh",
utype = "volume",
scale = 0.03636872,
default = "l impgal USdrygal",
link = "بوشل",
},
["impbu"] = {
name1 = "بوشل إمبراطوري",
name1_us = "imperial bushel",
symbol = "بوشل إمب",
sym_us = "imp bu",
utype = "volume",
scale = 0.03636872,
default = "m3",
link = "بوشل",
},
["impgal"] = {
name1 = "جالون إمبراطوري",
name1_us = "imperial gallon",
symbol = "غالون إمب",
sym_us = "imp gal",
utype = "volume",
scale = 0.00454609,
default = "l USgal",
link = "غالون",
},
["impgi"] = {
name1_us = "gill",
symbol = "جيل",
sym_us = "gi",
utype = "volume",
scale = 0.0001420653125,
default = "ml USoz",
link = "Gill (unit)",
},
["impkenning"] = {
name1 = "كينينج إمبراطوري",
name1_us = "imperial kenning",
symbol = "كينينج",
sym_us = "kenning",
utype = "volume",
scale = 0.01818436,
default = "l USdrygal",
link = "Kenning (unit)",
},
["impoz"] = {
name1 = "أونصة سائلة",
name1_us = "imperial fluid ounce",
symbol = "imp fl oz",
utype = "volume",
scale = 0.0000284130625,
default = "ml USoz",
link = "Imperial fluid ounce",
},
["imppk"] = {
name1 = "بك إمبراطوري",
name1_us = "imperial peck",
symbol = "بك",
sym_us = "pk",
utype = "volume",
scale = 0.00909218,
default = "l USdrygal",
link = "Peck",
},
["imppt"] = {
name1 = "باينت إمبراطوري",
name1_us = "imperial pint",
symbol = "باينت إمب",
sym_us = "imp pt",
utype = "volume",
scale = 0.00056826125,
default = "l",
link = "باينت",
},
["impqt"] = {
name1 = "كوارت إمبراطوري",
name1_us = "imperial quart",
symbol = "كوارت إمب",
sym_us = "imp qt",
utype = "volume",
scale = 0.0011365225,
default = "ml USoz",
link = "وحدات إمبراطورية",
customary= 3,
},
["kilderkin"] = {
symbol = "kilderkin",
sym_us = "~kilderkin",
usename = 1,
utype = "volume",
scale = 0.08182962,
default = "l impgal USgal",
},
["koilbbl"] = {
name1 = "ألف برميل",
name1_us = "thousand barrels",
symbol = "كـ.برميل",
sym_us = "kbbl",
utype = "volume",
scale = 158.987294928,
default = "v * 1.58987294928 < 10 ! ! e3 ! m3",
link = "برميل (نفط)",
},
["L"] = {
_name1 = "لتر",
_symbol = "ل",
_sym_us = "L",
utype = "volume",
scale = 0.001,
prefixes = 1,
default = "impgal USgal",
link = "لتر",
},
["l"] = {
_name1 = "لتر",
_symbol = "ل",
_sym_us = "L",
utype = "volume",
scale = 0.001,
prefixes = 1,
default = "impgal USgal",
link = "لتر",
},
["m3"] = {
_name1 = "متر مكعب",
_symbol = "م<sup>3</sup>",
_sym_us = "m<sup>3</sup>",
utype = "volume",
scale = 1,
prefixes = 3,
default = "cuft",
link = "متر مكعب",
},
["Mbbl"] = {
name1 = "ألف برميل",
name1_us = "thousand barrels",
symbol = "كـ.برميل",
sym_us = "Mbbl",
utype = "volume",
scale = 158.987294928,
default = "v * 1.58987294928 < 10 ! e3 ! ! m3",
link = "برميل (نفط)",
},
["MMoilbbl"] = {
name1 = "مليون برميل",
name1_us = "million barrels",
symbol = "مج.برميل",
sym_us = "MMbbl",
utype = "volume",
scale = 158987.294928,
default = "v * 1.58987294928 < 10 ! e3 ! e6 ! m3",
link = "برميل (نفط)",
},
["Moilbbl"] = {
name1 = "مليون برميل",
name1_us = "million barrels",
symbol = "مليون.برميل",
sym_us = "Mbbl",
utype = "volume",
scale = 158987.294928,
default = "v * 1.58987294928 < 10 ! e3 ! e6 ! m3",
link = "برميل (نفط)",
},
["MTON"] = {
name1_us = "measurement ton",
symbol = "MTON",
utype = "volume",
scale = 1.13267386368,
default = "m3",
link = "Measurement ton",
},
["MUSgal"] = {
name1 = "مليون جالون أمريكي",
name1_us = "million US gallons",
name2 = "مليون جالون أمريكي",
name2_us = "million U.S. gallons",
symbol = "مليون غال.أمريكي",
sym_us = "million U.S. gal",
utype = "volume",
scale = 3785.411784,
default = "Ml",
link = "غالون",
},
["oilbbl"] = {
name1_us = "barrel",
symbol = "برميل",
sym_us = "bbl",
utype = "volume",
scale = 0.158987294928,
default = "m3",
link = "برميل (نفط)",
},
["stere"] = {
symbol = "stère",
sym_us = "~stère",
usename = 1,
utype = "volume",
scale = 1,
default = "cuft",
},
["Toilbbl"] = {
name1 = "تريليون برميل",
name1_us = "trillion barrels",
symbol = "تـ.برميل",
sym_us = "Tbbl",
utype = "volume",
scale = 158987294928,
default = "v * 1.58987294928 < 10 ! e9 ! e12 ! m3",
link = "برميل (نفط)",
},
["USbbl"] = {
name1_us = "US barrel",
name2_us = "U.S. barrel",
symbol = "برميل أمريكي",
sym_us = "U.S. bbl",
utype = "volume",
scale = 0.119240471196,
default = "l USgal impgal",
link = "برميل (نفط)",
},
["USbeerbbl"] = {
name1 = "برميل بيرة أمريكي",
name1_us = "US beer barrel",
name2_us = "U.S. beer barrel",
symbol = "برميل أمريكي",
sym_us = "U.S. bbl",
utype = "volume",
scale = 0.117347765304,
default = "l USgal impgal",
link = "برميل (نفط)",
},
["USbsh"] = {
name1_us = "US bushel",
symbol = "بوشل أمريكي",
sym_us = "U.S. bsh",
utype = "volume",
scale = 0.03523907016688,
default = "l USdrygal impgal",
link = "بوشل",
},
["USbu"] = {
name1_us = "US bushel",
symbol = "بوشل أمريكي",
sym_us = "U.S. bu",
utype = "volume",
scale = 0.03523907016688,
default = "l USdrygal impgal",
link = "بوشل",
},
["USdrybbl"] = {
name1_us = "U.S. dry barrel",
name2_us = "US dry barrel",
symbol = "US dry bbl",
sym_us = "U.S. dry bbl",
utype = "volume",
scale = 0.11562819898508,
default = "m3",
link = "برميل (نفط)",
},
["USdrygal"] = {
name1_us = "U.S. dry gallon",
name2_us = "US dry gallon",
symbol = "US dry gal",
sym_us = "U.S. dry gal",
utype = "volume",
builtin = "جالون أمريكي جاف",
scale = 0.00440488377086,
iscomplex= true,
default = "l",
link = "غالون",
},
["USdrypt"] = {
name1 = "باينت أمريكي جاف",
name1_us = "U.S. dry pint",
name2_us = "US dry pint",
symbol = "US dry pt",
sym_us = "U.S. dry pt",
utype = "volume",
scale = 0.0005506104713575,
default = "ml",
link = "Pint",
},
["USdryqt"] = {
name1 = "كوارت أمريكي جاف",
name1_us = "US dry quart",
symbol = "US dry qt",
sym_us = "U.S. dry qt",
utype = "volume",
scale = 0.001101220942715,
default = "ml",
link = "الكوارت",
},
["USflgal"] = {
name1 = "غالون أمريكي",
name1_us = "US gallon",
symbol = "غال-أمريكي",
sym_us = "U.S. fl gal",
utype = "volume",
scale = 0.003785411784,
default = "l impgal",
link = "غالون",
},
["USgal"] = {
name1 = "غالون أمريكي",
name1_us = "US gallon",
symbol = "غال-أمريكي",
sym_us = "U.S. gal",
utype = "volume",
scale = 0.003785411784,
default = "l impgal",
link = "غالون",
},
["USgi"] = {
name1 = "gill",
symbol = "gi",
utype = "volume",
scale = 0.0001182941183,
default = "ml impoz",
link = "Gill (unit)",
},
["USkenning"] = {
name1_us = "US kenning",
name2_us = "U.S. kenning",
symbol = "كينينج أمريكي",
sym_us = "U.S. kenning",
utype = "volume",
scale = 0.01761953508344,
default = "l impgal",
link = "Kenning (unit)",
},
["USmin"] = {
name1_us = "US minim",
name2_us = "U.S. minim",
symbol = "US min",
sym_us = "U.S. min",
utype = "volume",
scale = 0.000000061611519921875,
default = "ml",
link = "Minim (unit)",
},
["USoz"] = {
name1 = "أوصنة أمريكية سائلة",
name1_us = "US fluid ounce",
name2_us = "U.S. fluid ounce",
symbol = "US fl oz",
sym_us = "U.S. fl oz",
utype = "volume",
scale = 0.0000295735295625,
default = "ml",
link = "وحدات قياس عرفية أمريكية",
},
["USpk"] = {
name1_us = "US peck",
name2_us = "U.S. peck",
symbol = "US pk",
sym_us = "U.S. pk",
utype = "volume",
scale = 0.00880976754172,
default = "l impgal",
link = "Peck",
},
["USpt"] = {
name1_us = "US pint",
name2_us = "U.S. pint",
symbol = "باينت أمريكي",
sym_us = "U.S. pt",
utype = "volume",
scale = 0.000473176473,
default = "l imppt",
link = "Pint",
},
["USqt"] = {
name1_us = "US quart",
symbol = "كوارت أمريكي",
sym_us = "U.S. qt",
utype = "volume",
scale = 0.000946352946,
default = "ml",
link = "الكوارت",
customary= 1,
},
["USquart"] = {
name1_us = "US quart",
symbol = "كوارت أمريكي",
sym_us = "U.S. qt",
utype = "volume",
scale = 0.000946352946,
default = "ml impoz",
link = "الكوارت",
},
["UStbsp"] = {
name1_us = "US tablespoon",
name2_us = "U.S. tablespoon",
symbol = "US tbsp",
sym_us = "U.S. tbsp",
utype = "volume",
scale = 1.4786764781250001e-5,
default = "ml",
link = "US tablespoon",
},
["winecase"] = {
symbol = "case",
usename = 1,
utype = "volume",
scale = 0.009,
default = "l",
link = "Case (goods)",
},
["*U.S.drygal"] = {
target = "USdrygal",
sp_us = true,
customary= 2,
},
["*U.S.gal"] = {
target = "USgal",
sp_us = true,
default = "L impgal",
customary= 2,
},
["+USdrygal"] = {
target = "USdrygal",
customary= 1,
},
["+usfloz"] = {
target = "USoz",
link = "Fluid ounce",
customary= 1,
},
["+USgal"] = {
target = "USgal",
customary= 1,
},
["+USoz"] = {
target = "USoz",
customary= 1,
},
["@impgal"] = {
target = "impgal",
customary= 3,
},
["acre feet"] = {
target = "acre ft",
},
["acre-feet"] = {
target = "acre ft",
},
["acre-ft"] = {
target = "acre ft",
},
["acre.foot"] = {
target = "acre foot",
},
["acre.ft"] = {
target = "acre ft",
},
["acre·foot"] = {
target = "acre foot",
},
["acre·ft"] = {
target = "acre ft",
},
["bushels"] = {
target = "USbsh",
},
["cid"] = {
target = "CID",
},
["ft3"] = {
target = "cuft",
},
["gal"] = {
target = "USgal",
},
["غالون أمريكي"] = {
target = "USgal",
},
["gallon"] = {
shouldbe = "Use %{USgal%} for US gallons or %{impgal%} for imperial gallons (not %{gallon%})",
},
["gallons"] = {
shouldbe = "Use %{USgal%} for US gallons or %{impgal%} for imperial gallons (not %{gallons%})",
},
["Gcuft"] = {
target = "e9cuft",
},
["impfloz"] = {
target = "impoz",
},
["Impgal"] = {
target = "impgal",
},
["in3"] = {
target = "cuin",
},
["kcuft"] = {
target = "e3cuft",
},
["kcum"] = {
target = "e3m3",
},
["km³"] = {
target = "km3",
},
["liter"] = {
target = "L",
sp_us = true,
},
["liters"] = {
target = "L",
sp_us = true,
},
["litre"] = {
target = "L",
},
["litres"] = {
target = "L",
},
["Mcuft"] = {
target = "e6cuft",
},
["Mcum"] = {
target = "e6m3",
},
["Mft3"] = {
target = "e6cuft",
},
["mi3"] = {
target = "cumi",
},
["m³"] = {
target = "m3",
},
["Pcuft"] = {
target = "e15cuft",
},
["pt"] = {
shouldbe = "Use %{USpt%} for US pints or %{imppt%} for imperial pints (not %{pt%})",
},
["qt"] = {
shouldbe = "Use %{USqt%} for US quarts or %{impqt%} for imperial quarts (not %{qt%})",
},
["Tcuft"] = {
target = "e12cuft",
},
["Tft3"] = {
target = "e12cuft",
},
["U.S.bbl"] = {
target = "USbbl",
sp_us = true,
default = "l U.S.gal impgal",
},
["U.S.beerbbl"] = {
target = "USbeerbbl",
sp_us = true,
default = "l U.S.gal impgal",
},
["U.S.bsh"] = {
target = "USbsh",
sp_us = true,
default = "l U.S.drygal impgal",
},
["U.S.bu"] = {
target = "USbu",
sp_us = true,
default = "l U.S.drygal impgal",
},
["U.S.drybbl"] = {
target = "USdrybbl",
sp_us = true,
},
["U.S.drygal"] = {
target = "USdrygal",
sp_us = true,
},
["U.S.drypt"] = {
target = "USdrypt",
sp_us = true,
},
["U.S.dryqt"] = {
target = "USdryqt",
sp_us = true,
},
["U.S.flgal"] = {
target = "USflgal",
sp_us = true,
},
["U.S.floz"] = {
target = "USoz",
sp_us = true,
},
["U.S.gal"] = {
target = "USgal",
sp_us = true,
default = "L impgal",
},
["u.s.gal"] = {
target = "USgal",
sp_us = true,
default = "L impgal",
},
["U.S.gi"] = {
target = "USgi",
sp_us = true,
},
["U.S.kenning"] = {
target = "USkenning",
sp_us = true,
},
["U.S.oz"] = {
target = "USoz",
sp_us = true,
},
["U.S.pk"] = {
target = "USpk",
sp_us = true,
},
["U.S.pt"] = {
target = "USpt",
sp_us = true,
},
["U.S.qt"] = {
target = "USqt",
sp_us = true,
default = "L impqt",
customary= 2,
},
["usbbl"] = {
target = "USbbl",
},
["usbeerbbl"] = {
target = "USbeerbbl",
},
["usbsh"] = {
target = "USbsh",
},
["usbu"] = {
target = "USbu",
},
["usdrybbl"] = {
target = "USdrybbl",
},
["usdrygal"] = {
target = "USdrygal",
},
["usdrypt"] = {
target = "USdrypt",
},
["usdryqt"] = {
target = "USdryqt",
},
["USfloz"] = {
target = "USoz",
},
["usfloz"] = {
target = "USoz",
},
["USGAL"] = {
target = "USgal",
},
["usgal"] = {
target = "USgal",
},
["usgi"] = {
target = "USgi",
},
["uskenning"] = {
target = "USkenning",
},
["usoz"] = {
target = "USoz",
},
["uspk"] = {
target = "USpk",
},
["uspt"] = {
target = "USpt",
},
["usqt"] = {
target = "USqt",
},
["yd3"] = {
target = "cuyd",
},
["cuft/sqmi"] = {
per = { "cuft", "sqmi" },
utype = "volume per unit area",
default = "m3/km2",
},
["m3/ha"] = {
name1 = "متر مكعب لكل هكتار",
name2 = "متر مكعب لكل هكتار",
name2_us = "cubic meters per hectare",
symbol = "م<sup>3</sup>/هكتار",
utype = "volume per unit area",
scale = 0.0001,
default = "USbu/acre",
link = "هكتار",
},
["m3/km2"] = {
per = { "m3", "km2" },
utype = "volume per unit area",
default = "cuft/sqmi",
},
["U.S.gal/acre"] = {
per = { "U.S.gal", "acre" },
utype = "volume per unit area",
default = "m3/km2",
},
["USbu/acre"] = {
name1 = "بوشل أمريكي لكل فدان",
name2 = "بوشل أمريكي لكل فدان",
symbol = "US bushel per acre",
usename = 1,
utype = "volume per unit area",
scale = 8.7077638761350888e-6,
default = "m3/ha",
link = "بوشل",
},
["USgal/acre"] = {
per = { "USgal", "acre" },
utype = "volume per unit area",
default = "m3/km2",
},
["cuyd/mi"] = {
per = { "cuyd", "mi" },
utype = "volume per unit length",
default = "m3/km",
},
["m3/km"] = {
per = { "m3", "km" },
utype = "volume per unit length",
default = "cuyd/mi",
},
["mich"] = {
combination= { "ch", "mi" },
multiple = { 80 },
utype = "length",
},
["michlk"] = {
combination= { "chlk", "mi" },
multiple = { 80 },
utype = "length",
},
["michainlk"] = {
combination= { "chainlk", "mi" },
multiple = { 80 },
utype = "length",
},
["miydftin"] = {
combination= { "in", "ft", "yd", "mi" },
multiple = { 12, 3, 1760 },
utype = "length",
},
["mift"] = {
combination= { "ft", "mi" },
multiple = { 5280 },
utype = "length",
},
["ydftin"] = {
combination= { "in", "ft", "yd" },
multiple = { 12, 3 },
utype = "length",
},
["ydft"] = {
combination= { "ft", "yd" },
multiple = { 3 },
utype = "length",
},
["ftin"] = {
combination= { "in", "ft" },
multiple = { 12 },
utype = "length",
},
["footin"] = {
combination= { "in", "foot" },
multiple = { 12 },
utype = "length",
},
["handin"] = {
combination= { "in", "hand" },
multiple = { 4 },
utype = "length",
},
["lboz"] = {
combination= { "oz", "lb" },
multiple = { 16 },
utype = "mass",
},
["stlb"] = {
combination= { "lb", "st" },
multiple = { 14 },
utype = "mass",
},
["stlboz"] = {
combination= { "oz", "lb", "st" },
multiple = { 16, 14 },
utype = "mass",
},
["st and lb"] = {
combination= { "lb", "st" },
multiple = { 14 },
utype = "mass",
},
["GN LTf"] = {
combination= { "GN", "-LTf" },
utype = "force",
},
["GN LTf STf"] = {
combination= { "GN", "-LTf", "-STf" },
utype = "force",
},
["GN STf"] = {
combination= { "GN", "-STf" },
utype = "force",
},
["GN STf LTf"] = {
combination= { "GN", "-STf", "-LTf" },
utype = "force",
},
["kN LTf"] = {
combination= { "kN", "-LTf" },
utype = "force",
},
["kN LTf STf"] = {
combination= { "kN", "-LTf", "-STf" },
utype = "force",
},
["kN STf"] = {
combination= { "kN", "-STf" },
utype = "force",
},
["kN STf LTf"] = {
combination= { "kN", "-STf", "-LTf" },
utype = "force",
},
["LTf STf"] = {
combination= { "-LTf", "-STf" },
utype = "force",
},
["MN LTf"] = {
combination= { "MN", "-LTf" },
utype = "force",
},
["MN LTf STf"] = {
combination= { "MN", "-LTf", "-STf" },
utype = "force",
},
["MN STf"] = {
combination= { "MN", "-STf" },
utype = "force",
},
["MN STf LTf"] = {
combination= { "MN", "-STf", "-LTf" },
utype = "force",
},
["STf LTf"] = {
combination= { "-STf", "-LTf" },
utype = "force",
},
["L/100 km mpgimp"] = {
combination= { "L/100 km", "mpgimp" },
utype = "fuel efficiency",
},
["l/100 km mpgimp"] = {
combination= { "l/100 km", "mpgimp" },
utype = "fuel efficiency",
},
["L/100 km mpgUS"] = {
combination= { "L/100 km", "mpgus" },
utype = "fuel efficiency",
},
["L/100 km mpgus"] = {
combination= { "L/100 km", "mpgus" },
utype = "fuel efficiency",
},
["l/100 km mpgus"] = {
combination= { "l/100 km", "mpgus" },
utype = "fuel efficiency",
},
["mpgimp L/100 km"] = {
combination= { "mpgimp", "L/100 km" },
utype = "fuel efficiency",
},
["LT ST t"] = {
combination= { "lt", "-ST", "t" },
utype = "mass",
},
["LT t ST"] = {
combination= { "lt", "t", "-ST" },
utype = "mass",
},
["ST LT t"] = {
combination= { "-ST", "lt", "t" },
utype = "mass",
},
["ST t LT"] = {
combination= { "-ST", "t", "lt" },
utype = "mass",
},
["t LT ST"] = {
combination= { "t", "lt", "-ST" },
utype = "mass",
},
["ton"] = {
combination= { "LT", "ST" },
utype = "mass",
},
["kPa kg/cm2"] = {
combination= { "kPa", "kgf/cm2" },
utype = "pressure",
},
["kPa lb/in2"] = {
combination= { "kPa", "-lb/in2" },
utype = "pressure",
},
["floz"] = {
combination= { "impoz", "USoz" },
utype = "volume",
},
}
---------------------------------------------------------------------------
-- Do not change the data in this table because it is created by running --
-- a script that reads the wikitext from a wiki page (see note above). --
---------------------------------------------------------------------------
local default_exceptions = {
-- Prefixed units with a default different from that of the base unit.
-- Each key item is a prefixed symbol (unitcode for engineering notation).
["سـم<sup>2</sup>"] = "sqin",
["دم<sup>2</sup>"] = "sqin",
["e3acre"] = "km2",
["e3m2"] = "e6sqft",
["e6acre"] = "km2",
["e6ha"] = "e6acre",
["e6km2"] = "e6sqmi",
["e6m2"] = "e6sqft",
["e6sqft"] = "v * 9.290304 < 100 ! e3 ! e6 ! m2",
["e6sqmi"] = "e6km2",
["هـم<sup>2</sup>"] = "acre",
["كـم<sup>2</sup>"] = "sqmi",
["مـم<sup>2</sup>"] = "sqin",
["آجول"] = "eV",
["e3BTU"] = "MJ",
["e6BTU"] = "GJ",
["يـجول"] = "kWh",
["فـجول"] = "keV",
["جـجول"] = "kWh",
["مججول"] = "kWh",
["بتـجول"] = "kWh",
["بـجول"] = "MeV",
["تـجول"] = "kWh",
["يوجول"] = "kWh",
["يكـجول"] = "μeV",
["زتـجول"] = "kWh",
["زبـجول"] = "meV",
["e12cuft/a"] = "v * 2.8316846592 < 100 ! e9 ! e12 ! m3/a",
["e12cuft/d"] = "v * 2.8316846592 < 100 ! e9 ! e12 ! m3/d",
["e12m3/a"] = "Tcuft/a",
["e12m3/d"] = "Tcuft/d",
["e3cuft/a"] = "v * 2.8316846592 < 100 ! ! e3 ! m3/a",
["e3cuft/d"] = "v * 2.8316846592 < 100 ! ! e3 ! m3/d",
["e3cuft/s"] = "v * 2.8316846592 < 100 ! ! e3 ! m3/s",
["e3m3/a"] = "v < 28.316846592 ! k ! M ! cuft/a",
["e3m3/d"] = "v < 28.316846592 ! k ! M ! cuft/d",
["e3m3/s"] = "v < 28.316846592 ! k ! M ! cuft/s",
["e3USgal/a"] = "v * 3.785411784 < 1000 ! ! e3 ! m3/a",
["e6cuft/a"] = "v * 2.8316846592 < 100 ! e3 ! e6 ! m3/a",
["e6cuft/d"] = "v * 2.8316846592 < 100 ! e3 ! e6 ! m3/d",
["e6cuft/s"] = "v * 2.8316846592 < 100 ! e3 ! e6 ! m3/s",
["e6m3/a"] = "v < 28.316846592 ! M ! G ! cuft/a",
["e6m3/d"] = "v < 28.316846592 ! M ! G ! cuft/d",
["e6m3/s"] = "v < 28.316846592 ! e6 ! e9 ! cuft/s",
["e6USgal/a"] = "v * 3.785411784 < 1000 ! e3 ! e6 ! m3/a",
["e9cuft/a"] = "m3/a",
["e9cuft/d"] = "v * 2.8316846592 < 100 ! e6 ! e9 ! m3/d",
["e9m3/a"] = "v < 28.316846592 ! G ! T ! cuft/a",
["e9m3/d"] = "v < 28.316846592 ! G ! T ! cuft/d",
["e9m3/s"] = "v < 28.316846592 ! e9 ! e12 ! cuft/s",
["e9USgal/a"] = "v * 3.785411784 < 1000 ! e6 ! e9 ! m3/a",
["e9USgal/s"] = "v * 3.785411784 < 1000 ! e6 ! e9 ! m3/s",
["نـن"] = "gr-f",
["مكـن"] = "gr-f",
["مـن"] = "oz-f",
["آم"] = "in",
["سـم"] = "in",
["دام"] = "ft",
["دم"] = "in",
["e12km"] = "e12mi",
["e12mi"] = "e12km",
["e3AU"] = "ly",
["e3km"] = "e3mi",
["e3mi"] = "e3km",
["e6km"] = "e6mi",
["e6mi"] = "e6km",
["e9km"] = "AU",
["e9mi"] = "e9km",
["يـم"] = "mi",
["فـم"] = "in",
["جـم"] = "mi",
["هـم"] = "ft",
["كـم"] = "mi",
["مـم"] = "in",
["مجم"] = "mi",
["نـم"] = "in",
["بتـم"] = "mi",
["بـم"] = "in",
["تـم"] = "mi",
["يوم"] = "mi",
["يكـم"] = "in",
["زتـم"] = "mi",
["زبـم"] = "in",
["مكـم"] = "in",
["e12lb"] = "v * 4.5359237 < 10 ! Mt ! Gt",
["e3lb"] = "v * 4.5359237 < 10 ! kg ! t",
["e3ozt"] = "v * 0.311034768 < 10 ! kg ! t",
["e3t"] = "LT ST",
["e6carat"] = "t",
["e6lb"] = "v * 4.5359237 < 10 ! t ! kilotonne",
["e6ozt"] = "lb kg",
["e6ST"] = "Mt",
["e6t"] = "LT ST",
["e9lb"] = "v * 4.5359237 < 10 ! kilotonne ! Mt",
["e9t"] = "LT ST",
["جـغ"] = "lb",
["كـغ"] = "lb",
["مـغ"] = "gr",
["مجغ"] = "LT ST",
["نـغ"] = "gr",
["مكـغ"] = "gr",
["مـبيك"] = "fCi",
["كـبيك"] = "nCi",
["مجبيك"] = "μCi",
["جـبيك"] = "mCi",
["تـبيك"] = "Ci",
["بتـبيك"] = "kCi",
["يـبيك"] = "kCi",
["فـكور"] = "mBq",
["بـكور"] = "Bq",
["نـكور"] = "Bq",
["مكـكور"] = "kBq",
["مـكور"] = "MBq",
["كـكور"] = "TBq",
["مجكور"] = "PBq",
["نـثا"] = "μs",
["مكـثا"] = "ms",
["مـثا"] = "s",
["كـثا"] = "h",
["مجثا"] = "week",
["جـثا"] = "decade",
["تـثا"] = "millennium",
["بتـثا"] = "million year",
["يـثا"] = "thousand million year",
["مجك"] = "keVT",
["سـل"] = "impoz usoz",
["سـل"] = "impoz usoz",
["سـم<sup>3</sup>"] = "cuin",
["دل"] = "impoz usoz",
["دل"] = "impoz usoz",
["مـم<sup>3</sup>"] = "cuin",
["دم<sup>3</sup>"] = "cuin",
["e12cuft"] = "v * 2.8316846592 < 100 ! e9 ! e12 ! m3",
["e12impgal"] = "v * 4.54609 < 1000 ! T ! P ! l",
["e12m3"] = "v < 28.316846592 ! T ! P ! cuft",
["e12U.S.gal"] = "v * 3.785411784 < 1000 ! T ! P ! l",
["e12USgal"] = "v * 3.785411784 < 1000 ! T ! P ! l",
["e15cuft"] = "v * 2.8316846592 < 100 ! e12 ! e15 ! m3",
["e15m3"] = "Pcuft",
["e3bdft"] = "v * 0.23597372167 < 100 ! e3 ! e6 ! m3",
["e3cuft"] = "v * 2.8316846592 < 100 ! ! e3 ! m3",
["e3impgal"] = "v * 4.54609 < 1000 ! k ! M ! l",
["e3m3"] = "v < 28.316846592 ! k ! M ! cuft",
["e3U.S.gal"] = "v * 3.785411784 < 1000 ! k ! M ! l",
["e3USgal"] = "v * 3.785411784 < 1000 ! k ! M ! l",
["e6bdft"] = "v * 0.23597372167 < 100 ! e3 ! e6 ! m3",
["e6cuft"] = "v * 2.8316846592 < 100 ! e3 ! e6 ! m3",
["e6cuyd"] = "v * 7.64554857984 < 10 ! e3 ! e6 ! m3",
["e6impgal"] = "v * 4.54609 < 1000 ! M ! G ! l",
["e6L"] = "USgal",
["e6m3"] = "v < 28.316846592 ! M ! G ! cuft",
["e6U.S.gal"] = "v * 3.785411784 < 1000 ! M ! G ! l",
["e6USgal"] = "v * 3.785411784 < 1000 ! M ! G ! l",
["e9bdft"] = "v * 0.23597372167 < 100 ! e6 ! e9 ! m3",
["e9cuft"] = "v * 2.8316846592 < 100 ! e6 ! e9 ! m3",
["e9impgal"] = "v * 4.54609 < 1000 ! G ! T ! l",
["e9m3"] = "v < 28.316846592 ! G ! T ! cuft",
["e9U.S.gal"] = "v * 3.785411784 < 1000 ! G ! T ! l",
["e9USgal"] = "v * 3.785411784 < 1000 ! G ! T ! l",
["جـل"] = "cuft",
["جـل"] = "cuft",
["كـل"] = "cuft",
["كـل"] = "cuft",
["كـم<sup>3</sup>"] = "cumi",
["مـل"] = "impoz usoz",
["مـل"] = "impoz usoz",
["مجل"] = "v < 28.316846592 ! e3 ! e6 ! cuft",
["مجل"] = "v < 28.316846592 ! e3 ! e6 ! cuft",
["تـل"] = "cumi",
["تـل"] = "cumi",
["مكـل"] = "cuin",
["مكـل"] = "cuin",
}
---------------------------------------------------------------------------
-- Do not change the data in this table because it is created by running --
-- a script that reads the wikitext from a wiki page (see note above). --
---------------------------------------------------------------------------
local link_exceptions = {
-- Prefixed units with a linked article different from that of the base unit.
-- Each key item is a prefixed symbol (not unitcode).
["مـم<sup>2</sup>"] = "مليمتر مربع",
["سـم<sup>2</sup>"] = "سنتيمتر مربع",
["دم<sup>2</sup>"] = "ديسيمتر مربع",
["كـم<sup>2</sup>"] = "كيلومتر مربع",
["كـجول"] = "كيلوجول",
["مججول"] = "ميجا جول",
["فـم"] = "فمتومتر",
["بـم"] = "بيكومتر",
["نـم"] = "نانومتر",
["مكـم"] = "ميكرومتر",
["مـم"] = "مليمتر",
["سـم"] = "سنتيمتر",
["دم"] = "ديسيمتر",
["دام"] = "ديكامتر",
["هـم"] = "هكتومتر",
["كـم"] = "كيلومتر",
["مجم"] = "ميجامتر",
["جـم"] = "جيجامتر",
["تـم"] = "تيرا متر",
["بتـم"] = "بيتا متر",
["يـم"] = "إكساء متر",
["زتـم"] = "زيتا متر",
["يوم"] = "يوتا متر",
["مكـغ"] = "ميكروغرام",
["مـغ"] = "ميليغرام",
["كـغ"] = "كيلوغرام",
["مجغ"] = "ميجاغرام",
["يكـو"] = "يوكتو وات",
["زبـو"] = "زبتو وات",
["آو"] = "آتو وات",
["فـو"] = "فيمتو وات",
["بـو"] = "بيكو وات",
["نـو"] = "نانو وات",
["مكـو"] = "مايكرو وات",
["مـو"] = "ملي وات",
["كـو"] = "كيلو وات",
["مجو"] = "ميجا وات",
["جـو"] = "جيجا وات",
["تـو"] = "تيرا وات",
["بتـو"] = "بيتا وات",
["يـو"] = "إكساء وات",
["زتـو"] = "زيتا وات",
["يوو"] = "يوتا وات",
["آثا"] = "أتوثانية",
["فـثا"] = "فمتوثانية",
["بـثا"] = "بيكو ثانية",
["نـثا"] = "نانوثانية",
["مكـثا"] = "ميكروثانية",
["مـثا"] = "ملي ثانية",
["كـثا"] = "كيلو ثانية",
["مجثا"] = "ميجا ثانية",
["جـثا"] = "جيجا ثانية",
["تـثا"] = "تيرا ثانية",
["بتـثا"] = "بيتا ثانية",
["يـثا"] = "إكساء ثانية",
["زتـثا"] = "زيتا ثانية",
["يوثا"] = "يوتا ثانية",
["مـم<sup>3</sup>"] = "ملي متر مكعب",
["سـم<sup>3</sup>"] = "سنتي متر مكعب",
["دم<sup>3</sup>"] = "ديسيمتر مكعب",
["دام<sup>3</sup>"] = "ديكا متر مكعب",
["كـم<sup>3</sup>"] = "كيلو متر مكعب",
["مكـل"] = "ميكرو لتر",
["مكـل"] = "ميكرو لتر",
["مـل"] = "ميل لتر",
["مـل"] = "ميل لتر",
["سـل"] = "سنتي لتر",
["سـل"] = "سنتي لتر",
["دل"] = "ديسي لتر",
["دل"] = "ديسي لتر",
["دال"] = "ديكا لتر",
["دال"] = "ديكا لتر",
["هـل"] = "هكتو لتر",
["هـل"] = "هكتو لتر",
["كـل"] = "كيلو لتر",
["كـل"] = "كيلو لتر",
["مجل"] = "ميجا لتر",
["مجل"] = "ميجا لتر",
["جـل"] = "جيجا لتر",
["جـل"] = "جيجا لتر",
["تـل"] = "تيرا لتر",
["تـل"] = "تيرا لتر",
["بتـل"] = "بيتا لتر",
["بتـل"] = "بيتا لتر",
}
---------------------------------------------------------------------------
-- Do not change the data in this table because it is created by running --
-- a script that reads the wikitext from a wiki page (see note above). --
---------------------------------------------------------------------------
local per_unit_fixups = {
-- Automatically created per units of form "x/y" may have their unit type
-- changed, for example, "length/time" is changed to "speed".
-- Other adjustments can also be specified.
["/area"] = "per unit area",
["/volume"] = "per unit volume",
["area/area"] = "area per unit area",
["energy/length"] = "energy per unit length",
["energy/mass"] = "energy per unit mass",
["energy/time"] = { utype = "power", link = "Power" },
["energy/volume"] = "energy per unit volume",
["force/area"] = { utype = "pressure", link = "ضغط" },
["length/length"] = { utype = "gradient", link = "تدرج" },
["length/time"] = { utype = "speed", link = "سرعة" },
["length/time/time"] = { utype = "acceleration", link = "تسارع" },
["mass/area"] = { utype = "pressure", multiplier = 9.80665 },
["mass/length"] = "linear density",
["mass/mass"] = "concentration",
["mass/power"] = "mass per unit power",
["mass/time"] = "mass per unit time",
["mass/volume"] = { utype = "density", link = "Density" },
["power/mass"] = "power per unit mass",
["power/volume"] = { link = "Power density" },
["pressure/length"] = "fracture gradient",
["speed/time"] = { utype = "acceleration", link = "تسارع" },
["volume/area"] = "volume per unit area",
["volume/length"] = "volume per unit length",
["volume/time"] = "flow",
}
return {
all_units = all_units,
default_exceptions = default_exceptions,
link_exceptions = link_exceptions,
per_unit_fixups = per_unit_fixups,
}
2h7ypqmv1rajc738z3g52v0d3zjwiqr
وحدة:Convert character width
828
28895
118025
2022-08-10T20:50:07Z
ForzaGreen
14525
أنشأ الصفحة ب'-- This module converts support characters from half-width to full-width, and vice versa. -- See [[Halfwidth and fullwidth forms]] for an explanation of half- and full-width characters. -- @todo FIXME: Needs more characters adding, needs support for diacritic marks. local data = mw.loadData( 'Module:Convert character width/data' ) local p = {} -- Converts one half-width character to one full-width character. local function getFull( s ) return data[ s ] or s...'
Scribunto
text/plain
-- This module converts support characters from half-width to full-width, and vice versa.
-- See [[Halfwidth and fullwidth forms]] for an explanation of half- and full-width characters.
-- @todo FIXME: Needs more characters adding, needs support for diacritic marks.
local data = mw.loadData( 'Module:Convert character width/data' )
local p = {}
-- Converts one half-width character to one full-width character.
local function getFull( s )
return data[ s ] or s
end
-- Converts one full-width character to one half-width character.
local function getHalf( s )
for half, full in pairs( data ) do
if s == full then
return half
end
end
return s
end
-- Converts multiple half-width characters to full-width characters.
function p.full( frame )
local s = type( frame ) == 'table' and frame.args and frame.args[ 1 ] or frame
s = type( s ) == 'number' and tostring( s ) or s
if type( s ) ~= 'string' then return end
return ( mw.ustring.gsub( s, '.', getFull ) )
end
-- Converts multiple full-width characters to half-width characters.
function p.half( frame )
local s = type( frame ) == 'table' and frame.args and frame.args[ 1 ] or frame
s = type( s ) == 'number' and tostring( s ) or s
if type( s ) ~= 'string' then return end
return ( mw.ustring.gsub( s, '.', getHalf ) )
end
return p
8hxk1rupqmuwu208z9w8suwqp1u08zw
وحدة:Convert/makeunits
828
28896
118026
2022-08-10T20:51:27Z
ForzaGreen
14525
أنشأ الصفحة ب'-- This module generates the wikitext required at Module:Convert/data -- by reading and processing the wikitext of the master list of units -- (see conversion_data for the page title). -- -- Script method: -- * Read lines, ignoring everything before "== Conversions ==". -- * Process the following lines: -- * Find next level-3 heading like "=== Length ===". -- * Parse each following line starting with "|" -- (but ignore lines starting with "|-" or "|}". --...'
Scribunto
text/plain
-- This module generates the wikitext required at Module:Convert/data
-- by reading and processing the wikitext of the master list of units
-- (see conversion_data for the page title).
--
-- Script method:
-- * Read lines, ignoring everything before "== Conversions ==".
-- * Process the following lines:
-- * Find next level-3 heading like "=== Length ===".
-- * Parse each following line starting with "|"
-- (but ignore lines starting with "|-" or "|}".
-- * Split such lines into fields (delimiter "||") and trim
-- leading/trailing whitespace from each field.
-- Remove any "colspan" at front of second field (symbol).
-- * Remove thousand separators (commas) from the scale field.
-- If the scale is a number, do not change it.
-- Otherwise, it should be an expression like "5/9", in
-- which case it is replaced by the value of the expression.
-- * Remove wiki formatting '[[...]]' from the link field.
-- * Remove redundant fields from the unit to reduce size of data table.
-- * Create alternative forms of a unit such as an alias or a combination.
-- * Stop processing when encounter end of text or a line starting
-- with a level-2 heading ("==" but not "===").
-- * Repeat above for each heading listed at prepare_data().
-- * Output Lua source for the units table.
--
-- -- Output has the following form.
-- local all_units = {
-- ["unitcode"] = { -- standard format
-- name1 = "singular name", -- omitted if redundant
-- name1_us = "singular name sp=us", -- omitted if redundant
-- name2 = "plural name", -- omitted if redundant
-- name2_us = "plural name sp=us", -- omitted if redundant
-- symbol = "symbol",
-- sym_us = "symbol sp=us", -- omitted if redundant
-- usename = 1, -- omitted if empty
-- utype = "unit type", -- from level-3 heading
-- scale = 1, -- a value, if necessary from evaluating an expression
-- subdivs = { ["ft"] = { 5280, default = "km" }, ["yd"] = { 1760 } } -- composite input; omitted if empty
-- link = "title of article for wikilink", -- omitted if empty or redundant
-- ... -- other values
-- },
-- ["unitcode"] = { -- alternative format to generate an alias
-- target = "unit code",
-- ... -- optional values to override those of target
-- },
-- ["unitcode"] = { -- alternative format to generate a "per" unit like $/acre or BTU/h
-- per = {u1, u2}, -- numbered table of unitcodes (u1 may be a currency symbol)
-- ... -- optional values
-- },
-- ["unitcode"] = { -- alternative format to generate an error message
-- shouldbe = "message that some other unit code should be used",
-- },
-- ["unitcode"] = { -- alternative format for combination outputs (like 'm ft')
-- combination = {u1, u2, ...}, -- numbered table of unitcodes
-- utype = "unit type", -- as for standard format
-- },
-- ["unitcode"] = { -- alternative format for output multiples (like 'ftin')
-- combination = {u1, u2, ...}, -- numbered table of unitcodes
-- multiple = {f1, f2, ...}, -- numbered table of integer factors
-- utype = "unit type", -- as for standard format
-- },
-- ...
-- }
local ulower = mw.ustring.lower
local usub = mw.ustring.sub
local text_code
local specials = {
-- This table is used to add extra fields when defining some units which
-- require exceptions to normal processing.
-- Each key is in the local language, while each value is fixed text.
-- However, this script should NOT be edited.
-- Instead, the translation_table in Module:Convert/text can be edited,
-- and this script will replace sections of the following with localized
-- definitions from Module:Convert/text, if given.
-- Ask for assistance at [[:en:Module talk:Convert]].
-- LATER: It would be better if this was defined in the conversion data.
utype = {
-- ["unit type in local language"] = "name_used_in_this_script"
["fuel efficiency"] = "type_fuel_efficiency",
["length"] = "type_length",
["temperature"] = "type_temperature",
["volume"] = "type_volume",
},
ucode = {
exception = {
-- ["unit code in local language"] = "name_used_in_module_convert"
["ft"] = "integer_more_precision",
["in"] = "subunit_more_precision",
["lb"] = "integer_more_precision",
},
istemperature = {
-- Common temperature scales (not keVT or MK).
-- ["unit code in local language"] = true
["C"] = true,
["F"] = true,
["K"] = true,
["R"] = true,
},
usesymbol = {
-- Use unit symbol not name if abbr not specified.
-- ["unit code in local language"] = 1
["C"] = 1,
["F"] = 1,
["K"] = 1,
["R"] = 1,
["C-change"] = 1,
["F-change"] = 1,
["K-change"] = 1,
},
alttype = {
-- Unit has an alternate type that is a valid conversion.
-- ["unit code in local language"] = "alternate type in local language"
["Nm"] = "energy",
["ftlb"] = "torque",
["ftlb-f"] = "torque",
["ftlbf"] = "torque",
["inlb"] = "torque",
["inlb-f"] = "torque",
["inlbf"] = "torque",
["inoz-f"] = "torque",
["inozf"] = "torque",
},
},
}
-- Module text for the local language (localization).
-- A default table of text for enwiki is provided here.
-- If needed for another wiki, wanted sections from the table can be
-- copied into translation_table in Module:Convert/text.
-- For example, copying and modifying only the titles section may give:
--
-- local translation_table = {
-- ... -- other items
-- mtext = {
-- titles = {
-- -- name_used_in_this_script = 'Title of page'
-- conversion_data = 'Modul:Convert/documentation/conversion data/dok',
-- },
-- },
-- }
local mtext = {
section_names = {
-- name_used_in_this_script = 'Section title used in conversion data'
overrides = 'Overrides',
conversions = 'Conversions',
outmultiples = 'Output multiples',
combinations = 'Combinations',
inmultiples = 'Input multiples',
defaults = 'Defaults',
links = 'Links',
perunits = 'Automatic per units',
varnames = 'Variable names',
},
titles = {
-- name_used_in_this_script = 'Title of page'
conversion_data = 'Module:Convert/توثيق/تحويل_البيانات',
},
messages = {
-- name_used_in_this_script = 'Error message ($1 = first parameter, $2 = second)'
m_als_bad = 'Alias has invalid text in field "$1".',
m_als_dup = 'Alias "$1" already defined.',
m_als_link = 'Alias "$1" must include a wikilink ("[[...]]") in the symlink text.',
m_als_mul = 'Alias "$1" has multiplier "$2" which is not a number.',
m_als_same = 'Should omit "$1" for alias "$2" because it is the same as its target.',
m_als_type = 'Target of alias "$1" has wrong type.',
m_als_undef = 'Primary unit must be defined before alias "=$1"',
m_cmb_miss = 'Missing unit code for a combination.',
m_cmb_none = 'No units specified for combination "$1"',
m_cmb_one = 'Only one unit specified for combination "$1"',
m_cmb_type = 'Unit "$1" in combination "$2" has wrong type.',
m_cmb_undef = 'Unit "$1" in combination "$2" not defined.',
m_cmp_def = 'Composite "$1" must specify a default unit code.',
m_cmp_int = 'Composite "$1" has components where scale ratios are not integers.',
m_cmp_inval = 'Composite "$1" has a component with an invalid scale, "$2".',
m_cmp_many = 'Composite "$1" has too many fields.',
m_cmp_miss = 'Missing unit code for a composite.',
m_cmp_order = 'Composite "$1" has components in wrong order or with invalid scales.',
m_cmp_scale = 'Alternate unit "$1" in composite "$2" has wrong scale.',
m_cmp_two = 'Composite "$1" must specify exactly two unit codes.',
m_cmp_type = 'Unit "$1" in composite "$2" has wrong type.',
m_cmp_undef = 'Unit "$1" in composite "$2" not defined.',
m_def_cond = 'Invalid condition in default "$1" for unit "$2".',
m_def_fmt = 'Default output "$1" for unit "$2" should have 2 or 3 "!".',
m_def_rpt = 'Default output "$1" for unit "$2" is repeated.',
m_def_same = 'Default output for unit "$1" is the same unit.',
m_def_type = 'Default output "$1" for unit "$2" has wrong type.',
m_def_undef = 'Default output "$1" for unit "$2" is not defined.',
m_dfs_code = 'Defaults section: no unit code specified.',
m_dfs_dup = 'Defaults section: unit "$1" has already been specified.',
m_dfs_none = 'Defaults section: unit "$1" has no default specified.',
m_dfs_sym = 'Defaults section: unit "$1" must have a symbol.',
m_dfs_two = 'Defaults section: unit "$1" should have two fields only.',
m_dfs_undef = 'Defaults section: unit "$1" is not defined.',
m_dup_code = 'Unit code "$1" has already been defined.',
m_error = 'Error:',
m_ftl_read = 'Could not read wikitext from "[[$1]]".',
m_ftl_table = '[[$1]] should export table "$2".',
m_ftl_type = 'Fatal error: unknown data type for "$1"',
m_hdg_lev2 = 'Level 2 heading "$1" not found.',
m_hdg_lev3 = 'No level 3 heading before: $1',
m_line_num = ' (line $1).',
m_lnk_brack = 'Link "$1" has wrong number of brackets.',
m_lnk_dup = 'Link exception "$1" is already defined.',
m_lnk_miss = 'Missing unit code for a link.',
m_lnk_none = 'No link defined for unit "$1".',
m_lnk_sym = 'Unit code "$1" for a link must have a symbol.',
m_lnk_two = 'Row for unit "$1" link should have two fields only.',
m_lnk_type = 'Link exception "$1" has wrong type.',
m_lnk_undef = 'Unit code "$1" for a link is not defined.',
m_miss_code = 'Missing unit code.',
m_miss_sym = 'Missing symbol.',
m_miss_type = 'Missing unit type.',
m_mul_int = 'Multiple "$1" has components where scale ratios are not integers.',
m_mul_miss = 'Missing unit code for a multiple.',
m_mul_none = 'No units specified for multiple "$1"',
m_mul_one = 'Only one unit specified for multiple "$1"',
m_mul_order = 'Multiple "$1" has components in wrong order or with invalid scales.',
m_mul_scale = 'Multiple "$1" has a component with an invalid scale, "$2".',
m_mul_std = 'Unit "$1" in multiple "$2" must be a standard unit.',
m_mul_type = 'Unit "$1" in multiple "$2" has wrong type.',
m_mul_undef = 'Unit "$1" in multiple "$2" not defined.',
m_no_title = 'Need title of page with unit definitions.',
m_ovr_dup = 'Override "$1" is already defined.',
m_ovr_miss = 'Missing unit code for an override.',
m_per_dup = 'Per unit "$1" already defined.',
m_per_empty = 'Unit "$1" has an empty field in the "per".',
m_per_fuel = 'Unit "$1" has invalid unit types for fuel efficiency.',
m_per_inv = 'Invalid field for a "per".',
m_per_two = 'Unit "$1" does not have exactly 2 fields in the "per".',
m_per_undef = 'Unit "$1" has undefined unit code "$2" in the "per".',
m_percent_s = 'Field "$1" must not contain "%s".',
m_pfx_bad = 'Unknown prefix: "$1".',
m_pfx_name = 'Unit with Prefix set must include Name.',
m_scl_bad = 'Scale expression is invalid: "$1".',
m_scl_miss = 'Missing scale.',
m_scl_oflow = 'Scale expression gives an invalid value: "$1".',
m_var_cnt = 'Variable names section: each row must have the configured number of columns.',
m_var_dup = 'Unit "$1" already has a variable name.',
m_var_miss = 'Missing field for a variable name.',
m_var_undef = 'Unit "$1" in variable names is not defined.',
m_warning = 'Warning:',
m_wrn_more = ' (and more not shown)',
m_wrn_nbsp = 'Line $1 contains a nonbreaking space.',
m_wrn_nodef = 'Units with the following unit codes have no default output.',
m_wrn_ucode = ' $1',
},
}
local function message(key, ...)
-- Return a message from the message table, which can be localized.
-- '$1', '$2', ... are replaced with the first, second, ... parameters,
-- each of which must be a string or a number.
-- The global variable is_test_run can be set by a testing program to
-- check the messages generated by this program.
local rep = {}
for i, v in ipairs({...}) do
rep['$' .. i] = v
end
key = key or '???'
local extra
if is_test_run and key ~= 'm_line_num' then
extra = key .. ': '
else
extra = ''
end
return extra .. string.gsub(mtext.messages[key] or key, '$%d+', rep)
end
local function quit(key, ...)
-- Use error() to pass an error message to the surrounding pcall().
error(message(key, ...), 0)
end
local function quit_no_message()
-- Throw an error.
-- This is used in some functions which can throw an error with a message,
-- but where the message is in fact never displayed because the calling
-- function uses pcall to catch errors, and any message is ignored.
-- Using this function documents that the message (which may be useful in
-- some other application) does not need translation as it never appears.
error('this message is not displayed', 0)
end
local function collection()
-- Return a table to hold items.
return {
n = 0,
add = function (self, item)
self.n = self.n + 1
self[self.n] = item
end,
pop = function (self, item)
if self.n > 0 then
local top = self[self.n]
self.n = self.n - 1
return top
end
end,
join = function (self, sep)
return table.concat(self, sep or '\n')
end,
}
end
local warnings = collection()
local function add_warning(key, ...)
-- Add a warning that will be inserted before the final result.
warnings:add(message(key, ...))
end
---Begin code to evaluate expressions-----------------------------------
-- This is needed because Lua's loadstring() is not available in Scribunto,
-- and each scale value can be specifed as an expression such as "5/9".
-- More complex expressions are supported, including use of parentheses
-- and the binary operators: + - * / ^
local operators = {
['+'] = { precedence = 1, associativity = 1, func = function (a, b) return a + b end },
['-'] = { precedence = 1, associativity = 1, func = function (a, b) return a - b end },
['*'] = { precedence = 2, associativity = 1, func = function (a, b) return a * b end },
['/'] = { precedence = 2, associativity = 1, func = function (a, b) return a / b end },
['^'] = { precedence = 3, associativity = 2, func = function (a, b) return a ^ b end },
['('] = '(',
[')'] = ')',
}
local function tokenizer(text)
-- Function 'next' returns the next token which is one of:
-- number
-- table (operator)
-- string ('(' or ')')
-- nil (end of text)
-- If invalid, an error is thrown.
-- The number is unsigned (unary operators are not supported).
return {
pos = 1,
maxpos = #text,
text = text,
next = function(self)
if self.pos <= self.maxpos then
local p1, p2, hit = self.text:find('^%s*([+%-*/^()])', self.pos)
if hit then
self.pos = p2 + 1
return operators[hit]
end
p1, p2, hit = self.text:find('^%s*(%d*%.?%d*[eE][+-]?%d*)', self.pos)
if not hit then
p1, p2, hit = self.text:find('^%s*(%d*%.?%d*)', self.pos)
end
local value = tonumber(hit)
if value then
self.pos = p2 + 1
return value
end
quit_no_message('invalid number "' .. self.text:sub(self.pos) .. '"')
end
end
}
end
local function evaluate_tokens(tokens, inparens)
-- Return the value from evaluating tokenized expression, or throw an error.
local numstack, opstack = collection(), collection()
local function perform_ops(precedence, associativity)
while opstack.n > 0 and (opstack[opstack.n].precedence > precedence or
(opstack[opstack.n].precedence == precedence and associativity == 1)) do
local rhs = numstack:pop()
local lhs = numstack:pop()
if not (rhs and lhs) then quit_no_message('missing number') end
local op = opstack:pop()
numstack:add(op.func(lhs, rhs))
end
end
local token_last
local function set_state(token_type)
if token_last == token_type then
local missing = (token_type == 'number') and 'operator' or 'number'
quit_no_message('missing ' .. missing)
end
token_last = token_type
end
while true do
local token = tokens:next()
if type(token) == 'number' then
set_state('number')
numstack:add(token)
elseif type(token) == 'table' then
set_state('operator')
perform_ops(token.precedence, token.associativity)
opstack:add(token)
elseif token == '(' then
set_state('number')
numstack:add(evaluate_tokens(tokens, true))
elseif token == ')' then
if inparens then
break
end
quit_no_message('unbalanced parentheses')
else
break
end
end
perform_ops(0)
if numstack.n > 1 then quit_no_message('missing operator') end
if numstack.n < 1 then quit_no_message('missing number') end
return numstack:pop()
end
local function evaluate(expression)
-- Return value (a number) from evaluating expression (a string),
-- or throw an error if invalid.
-- This is not bullet proof, but it should support the expressions used.
return evaluate_tokens(tokenizer(expression))
end
---End code to evaluate expressions-------------------------------------
---Begin code adapted from Module:Convert-------------------------------
local plural_suffix = 's' -- may be changed from translation.plural_suffix below
local function shallow_copy(t)
-- Return a shallow copy of t.
-- Do not need the features and overhead of mw.clone() provided by Scribunto.
local result = {}
for k, v in pairs(t) do
result[k] = v
end
return result
end
local function split(text, delimiter)
-- Return a numbered table with fields from splitting text.
-- The delimiter is used in a regex without escaping (for example, '.' would fail).
-- Each field has any leading/trailing whitespace removed.
local t = {}
text = text .. delimiter -- to get last item
for item in text:gmatch('%s*(.-)%s*' .. delimiter) do
table.insert(t, item)
end
return t
end
local unit_mt = {
-- Metatable to get missing values for a unit that does not accept SI prefixes.
-- Warning: The boolean value 'false' is returned for any missing field
-- so __index is not called twice for the same field in a given unit.
__index = function (self, key)
local value
if key == 'name1' or key == 'sym_us' then
value = self.symbol
elseif key == 'name2' then
value = self.name1 .. plural_suffix
elseif key == 'name1_us' then
value = self.name1
if not rawget(self, 'name2_us') then
-- If name1_us is 'foot', do not make name2_us by appending plural_suffix.
self.name2_us = self.name2
end
elseif key == 'name2_us' then
local raw1_us = rawget(self, 'name1_us')
if raw1_us then
value = raw1_us .. plural_suffix
else
value = self.name2
end
elseif key == 'link' then
value = self.name1
else
value = false
end
rawset(self, key, value)
return value
end
}
local function prefixed_name(unit, name, index)
-- Return unit name with SI prefix inserted at correct position.
-- index = 1 (name1), 2 (name2), 3 (name1_us), 4 (name2_us).
-- The position is a byte (not character) index, so use Lua's sub().
local pos = rawget(unit, 'prefix_position')
if type(pos) == 'string' then
pos = tonumber(split(pos, ',')[index])
end
if pos then
return name:sub(1, pos - 1) .. unit.si_name .. name:sub(pos)
end
return unit.si_name .. name
end
local unit_prefixed_mt = {
-- Metatable to get missing values for a unit that accepts SI prefixes.
-- Before use, fields si_name, si_prefix must be defined.
-- The unit must define _symbol, _name1 and
-- may define _sym_us, _name1_us, _name2_us
-- (_sym_us, _name2_us may be defined for a language using sp=us
-- to refer to a variant unrelated to U.S. units).
__index = function (self, key)
local value
if key == 'symbol' then
value = self.si_prefix .. self._symbol
elseif key == 'sym_us' then
value = rawget(self, '_sym_us')
if value then
value = self.si_prefix .. value
else
value = self.symbol
end
elseif key == 'name1' then
value = prefixed_name(self, self._name1, 1)
elseif key == 'name2' then
value = rawget(self, '_name2')
if value then
value = prefixed_name(self, value, 2)
else
value = self.name1 .. plural_suffix
end
elseif key == 'name1_us' then
value = rawget(self, '_name1_us')
if value then
value = prefixed_name(self, value, 3)
else
value = self.name1
end
elseif key == 'name2_us' then
value = rawget(self, '_name2_us')
if value then
value = prefixed_name(self, value, 4)
elseif rawget(self, '_name1_us') then
value = self.name1_us .. plural_suffix
else
value = self.name2
end
elseif key == 'link' then
value = self.name1
else
value = false
end
rawset(self, key, value)
return value
end
}
local function lookup(units, unitcode, sp, what)
-- Return a copy of the unit if found, or return nil.
-- In this cut-down code, sp is always nil, and what is ignored.
local t = units[unitcode]
if t then
if t.shouldbe then
return nil
end
local result = shallow_copy(t)
if result.prefixes then
result.si_name = ''
result.si_prefix = ''
return setmetatable(result, unit_prefixed_mt)
end
return setmetatable(result, unit_mt)
end
local SIprefixes = text_code.SIprefixes
for plen = SIprefixes[1] or 2, 1, -1 do
-- Look for an SI prefix; should never occur with an alias.
-- Check for longer prefix first ('dam' is decametre).
-- SIprefixes[1] = prefix maximum #characters (as seen by mw.ustring.sub).
local prefix = usub(unitcode, 1, plen)
local si = SIprefixes[prefix]
if si then
local t = units[usub(unitcode, plen+1)]
if t and t.prefixes then
local result = shallow_copy(t)
if (sp == 'us' or t.sp_us) and si.name_us then
result.si_name = si.name_us
else
result.si_name = si.name
end
result.si_prefix = si.prefix or prefix
-- In this script, each scale is a string.
result.scale = tostring(tonumber(t.scale) * 10 ^ (si.exponent * t.prefixes))
result.prefixes = nil -- a prefixed unit does not take more prefixes (in this script, the returned unit may be added to the list of units)
return setmetatable(result, unit_prefixed_mt)
end
end
end
local exponent, baseunit = unitcode:match('^e(%d+)(.*)')
if exponent then
local engscale = text_code.eng_scales[exponent]
if engscale then
local result = lookup(units, baseunit, sp, 'no_combination')
if not result then return nil end
if not (result.offset or result.builtin or result.engscale) then
result.defkey = unitcode -- key to lookup default exception
result.engscale = engscale
-- Do not set result.scale as this code is called for units where that is not set.
return result
end
end
end
return nil
end
local function evaluate_condition(value, condition)
-- Return true or false from applying a conditional expression to value,
-- or throw an error if invalid.
-- A very limited set of expressions is supported:
-- v < 9
-- v * 9 < 9
-- where
-- 'v' is replaced with value
-- 9 is any number (as defined by Lua tonumber)
-- '<' can also be '<=' or '>' or '>='
-- In addition, the following form is supported:
-- LHS and RHS
-- where
-- LHS, RHS = any of above expressions.
local function compare(value, text)
local arithop, factor, compop, limit = text:match('^%s*v%s*([*]?)(.-)([<>]=?)(.*)$')
if arithop == nil then
quit_no_message('Invalid default expression.')
elseif arithop == '*' then
factor = tonumber(factor)
if factor == nil then
quit_no_message('Invalid default expression.')
end
value = value * factor
end
limit = tonumber(limit)
if limit == nil then
quit_no_message('Invalid default expression.')
end
if compop == '<' then
return value < limit
elseif compop == '<=' then
return value <= limit
elseif compop == '>' then
return value > limit
elseif compop == '>=' then
return value >= limit
end
quit_no_message('Invalid default expression.') -- should not occur
end
local lhs, rhs = condition:match('^(.-%W)and(%W.*)')
if lhs == nil then
return compare(value, condition)
end
return compare(value, lhs) and compare(value, rhs)
end
---End adapted code-----------------------------------------------------
local function strip(text)
-- Return text with no leading/trailing whitespace.
return text:match("^%s*(.-)%s*$")
end
local function empty(text)
-- Return true if text is nil or empty (assuming a string).
return text == nil or text == ''
end
-- Tables of units: k = unit code, v = unit table.
local units_index = {} -- all units: normal, alias, per, combination, or multiple
local alias_index = {} -- all aliases (to detect attempts to define more than once)
local per_index = {} -- all "per" units (to detect attempts to define more than once)
local function get_unit(ucode, utype)
-- Look up unit code in our cache of units.
-- If utype == nil, the unit should already have been defined.
-- Otherwise, ucode may represent an automatically generated combination
-- where each component must have the given utype; a dummy unit is returned.
if empty(ucode) then
return nil
end
local unit = lookup(units_index, ucode)
if unit or not utype then
return unit
end
local combo = collection()
if ucode:find('+', 1, true) then
for item in (ucode .. '+'):gmatch('%s*(.-)%s*%+') do
if item ~= '' then
combo:add(item)
end
end
elseif ucode:find('%s') then
for item in ucode:gmatch('%S+') do
combo:add(item)
end
end
if combo.n > 1 then
local result = setmetatable({ utype = utype }, {
__index = function (self, key)
error('Bug: invalid use of automatically generated unit')
end })
for _, v in ipairs(combo) do
local component = lookup(units_index, v)
if not component or component.shouldbe or component.combination then
return nil
end
if utype ~= component.utype then
result.utype = component.utype -- set wrong type which caller will detect
break
end
end
return result
end
end
local overrides = {} -- read from input for unit codes that should not be checked for a duplicate
local function insert_unique_unit(data, unit, index)
-- After inserting any required built-in data, insert the unit into the
-- data table and (if index not nil) add to index,
-- but not if the unit code is already defined.
local ucode = unit.unitcode
local known = get_unit(ucode)
if known and not overrides[ucode] then
quit('m_dup_code', ucode)
end
for item, t in pairs(specials.ucode) do
unit[item] = t[ucode]
end
if index then
index[ucode] = unit
end
table.insert(data, unit)
end
local function check_condition(condition)
-- Return true if condition appears to be valid; otherwise return false.
for _, value in ipairs({ 0, 0.1, 1, 1.1, 10, 100, 1000, 1e4, 1e5 }) do
local success, result = pcall(evaluate_condition, value, condition)
if not success then
return false
end
end
return true
end
local function check_default_expression(default, ucode)
-- Return a numbered table of names present in param default
-- (two names if an expression, or one name (param default) otherwise).
-- Throw an error if a problem occurs.
-- An expression uses pipe-delimited fields with 'v' representing
-- the input value for the conversion.
-- Example (suffix is optional): 'v < 120 ! small ! big ! suffix'
-- returns { 'smallsuffix', 'bigsuffix' }.
if not default:find('!', 1, true) then
return { default }
end
local t = {}
for item in (default .. '!'):gmatch('%s*(.-)%s*!') do
t[#t+1] = item -- split on '!', removing leading/trailing whitespace
end
if not (#t == 3 or #t == 4) then
quit('m_def_fmt', default, ucode)
end
local condition, default1, default2 = t[1], t[2], t[3]
if #t == 4 then
default1 = default1 .. t[4]
default2 = default2 .. t[4]
end
if not check_condition(condition) then
quit('m_def_cond', default, ucode)
end
return { default1, default2 }
end
local function check_default(default, ucode, utype, unit_table)
-- Check the given name (or expression) of a default output.
-- Normally a unit must not define itself as its default. However,
-- some units are defined merely for use in per units, and they have
-- the same ucode, utype and default.
-- Example: unit cent which cannot be converted to anything other than
-- a cent, but which can work, for example, in cent/km and cent/mi.
-- Throw an error if a problem occurs.
local done = {}
for _, default in ipairs(check_default_expression(default, ucode)) do
if done[default] then
quit('m_def_rpt', default, ucode)
end
if default == ucode and ucode ~= utype then
quit('m_def_same', ucode)
end
local default_table = get_unit(default, utype)
if not default_table then
quit('m_def_undef', default, ucode)
end
if not (utype == unit_table.utype and utype == default_table.utype) then
quit('m_def_type', default, ucode)
end
done[default] = true
end
end
local function check_all_defaults(cfg, units)
-- Check each default in units and warn if needed.
-- This is done after all input data has been processed.
-- Throw an error if a problem occurs.
local errors = collection()
local missing = collection() -- unitcodes with missing defaults
for _, unit in ipairs(units) do
if not unit.shouldbe and not unit.combination then
-- This is a standard unit or an alias/per (not shouldbe, combo).
-- An alias may have a default defined, but it is optional.
local default = unit.default
local ucode = unit.unitcode
if empty(default) then
if not unit.target then -- unit should have a default
missing:add(ucode)
end
else
local ok, msg = pcall(check_default, default, ucode, unit.utype, unit)
if not ok then
errors:add(msg)
if errors.n >= cfg.maxerrors then
break
end
end
end
end
end
if errors.n > 0 then
error(errors:join(), 0)
end
if missing.n > 0 then
add_warning('m_wrn_nodef')
local limit = cfg.maxerrors
for _, v in ipairs(missing) do
limit = limit - 1
if limit < 0 then
add_warning('m_wrn_more')
break
end
add_warning('m_wrn_ucode', v)
end
end
end
local function check_all_pers(cfg, units)
-- Check each component of each "per" unit and warn if needed.
-- In addition, add any required extra fields for some types of units.
-- This is done after all input data has been processed.
-- Throw an error if a problem occurs.
local errors = collection()
local function errmsg(key, ...)
errors:add(message(key, ...))
end
for _, unit in ipairs(units) do
local per = unit.per
if per then
local ucode = unit.unitcode
if #per ~= 2 then
errmsg('m_per_two', ucode)
else
local types = {}
for i, v in ipairs(per) do
if empty(v) then
errmsg('m_per_empty', ucode)
end
if not text_code.currency[v] then
local t = get_unit(v)
if t then
types[i] = t.utype
else
errmsg('m_per_undef', ucode, v)
end
end
end
if specials.utype[unit.utype] == 'type_fuel_efficiency' then
local expected = { type_volume = 1, type_length = 2 }
local top_type = expected[specials.utype[types[1]]]
local bot_type = expected[specials.utype[types[2]]]
if top_type and bot_type and top_type ~= bot_type then
unit.iscomplex = true
if top_type == 1 then
unit.invert = 1
else
unit.invert = -1
end
else
errmsg('m_per_fuel', ucode)
end
end
end
end
if errors.n >= cfg.maxerrors then
break
end
end
if errors.n > 0 then
error(errors:join(), 0)
end
end
local function update_units(units, composites, varnames)
-- Update some unit definitions with extra data defined in other sections.
-- This is done after all input data has been processed.
for _, unit in ipairs(units) do
local comp = composites[unit.unitcode]
if comp then
unit.subdivs = '{ ' .. table.concat(comp.subdivs, ', ') .. ' }'
end
local vn = varnames[unit.unitcode]
if vn then
unit.varname = vn
end
end
end
local function make_override(cfg, data)
-- Return a function which, when called, stores a unit code that is not to be
-- checked for a duplicate. The table is stored in data (also a table).
return function (utype, fields)
local ucode = fields[1]
if empty(ucode) then
quit('m_ovr_miss')
end
if data[ucode] then
quit('m_ovr_dup', ucode)
end
data[ucode] = true
end
end
local function make_default(cfg, data)
-- Return a function which, when called, stores a table that defines a
-- default output unit. The table is stored in data (also a table).
local defaults_index = {} -- to detect attempts to define a default twice
return function (utype, fields)
-- Store a table defining a unit.
-- This is for a unit such as 'kg' that has a default output unit
-- different from what is defined for the base unit ('g').
-- Throw an error if a problem occurs.
local ucode = fields[1]
local default = fields[2]
if empty(ucode) then
quit('m_dfs_code')
end
if empty(default) then
quit('m_dfs_none', ucode)
end
if #fields ~= 2 then
quit('m_dfs_two', ucode)
end
local unit_table = get_unit(ucode)
if not unit_table then
quit('m_dfs_undef', ucode)
end
local symbol = unit_table.defkey or unit_table.symbol
if empty(symbol) then
quit('m_dfs_sym', ucode)
end
check_default(default, ucode, utype, unit_table)
if defaults_index[ucode] then
quit('m_dfs_dup', ucode)
end
defaults_index[ucode] = default
table.insert(data, { symbol = symbol, default = default })
end
end
local function clean_link(link, name)
-- Return link, customary where:
-- link = given link after removing any '[[...]]' wiki formatting
-- and removing any leading '+' or '*' or '@';
-- customary = 1 if leading '+', or 2 if '*' or 3 if '@', or nil
-- (for extra "US" or "U.S." or "Imperial" customary units link).
-- Result has leading/trailing whitespace removed, and is nil if empty
-- or if link matches the name, if a name is specified.
-- Exception: If the link is empty and the name starts with '[[',
-- the link is stored as '' (for a unit name which is always linked).
-- If the resulting link is nil, no link field is stored, and
-- if a link is required, it will be set from the unit's name.
local original = link
if empty(link) then
return (name and name:sub(1, 2) == '[[') and '' or nil
end
local prefixes = { ['+'] = 1, ['*'] = 2, ['@'] = 3 }
local customary = prefixes[link:sub(1, 1)]
if customary then
link = strip(link:sub(2))
end
if link:sub(1, 2) == '[[' then
link = link:sub(3)
end
if link:sub(-2) == ']]' then
link = link:sub(1, -3)
end
link = strip(link)
if link:sub(1, 1) == '[' or link:sub(-1) == ']' then
quit('m_lnk_brack', original)
end
if link == '' then
link = nil
elseif name then
local l = ulower(usub(link, 1, 1)) .. usub(link, 2)
local n = ulower(usub(name, 1, 1)) .. usub(name, 2)
if l == n then
link = nil -- link == name, ignoring case of first letter
end
end
return link, customary
end
local function make_link(cfg, data)
-- Return a function which, when called, stores a table that defines a
-- link exception. The table is stored in data (also a table).
local links_index = {} -- to detect attempts to define a link twice
return function (utype, fields)
-- Store a table defining a unit.
-- This is for a unit such as 'kg' that has a linked article
-- different from what is defined for the base unit ('g').
-- Throw an error if a problem occurs.
local ucode = fields[1]
local link = clean_link(fields[2])
if empty(ucode) then
quit('m_lnk_miss')
end
if empty(link) then
quit('m_lnk_none', ucode)
end
if #fields ~= 2 then
quit('m_lnk_two', ucode)
end
local unit_table = get_unit(ucode)
if not unit_table then
quit('m_lnk_undef', ucode)
end
if utype ~= unit_table.utype then
quit('m_lnk_type', ucode)
end
local symbol = unit_table.symbol
if empty(symbol) then
quit('m_lnk_sym', ucode)
end
if links_index[ucode] then
quit('m_lnk_dup', ucode)
end
links_index[ucode] = link
table.insert(data, { symbol = symbol, link = link })
end
end
local function clean_scale(scale)
-- Return cleaned scale as a string, after evaluating any expression.
-- It would be better to retain scale expressions like "5/9" so that
-- the expression is evaluated on the server and maintains the full
-- resolution of the server. However, there are many such expressions
-- in the table of all units, and it seems pointless to require the
-- server to evaluate all of them just to do one convert.
if empty(scale) then
quit('m_scl_miss')
end
assert(type(scale) == 'string', 'Bug: scale has an unexpected type')
scale = string.gsub(scale, ',', '') -- remove comma separators
if tonumber(scale) then -- not an expression
return scale
end
local status, value = pcall(evaluate, scale)
if not (status and type(value) == 'number') then
quit('m_scl_bad', scale)
end
local result = string.format('%.17g', value)
if result:find('[#n]') then
-- Lua can give results like "#INF" while Scribunto gives "inf". Either is an error.
quit('m_scl_oflow', scale)
end
-- Omit redundant zeros from results like '1.2e-005'.
-- Do not bother looking for results like '1.2e+005' as none occur in practice.
local lhs, zeros, rhs = result:match('^(.-e%-)(0+)(.*)')
if zeros then
result = lhs .. rhs
end
return result
end
local function add_alias_optional_fields(unit, start, fields, target)
-- Inspect fields[i] for i = start, start+1 ..., and extract any
-- definitions appropriate for an alias or "per", and add them to unit.
-- For an alias, target is a valid unit; for a "per", target is nil.
-- Throw error if encounter an invalid entry.
for i = start, #fields do
local field = fields[i]
if not empty(field) then
local lhs, rhs = field:match('^%s*(.-)%s*=%s*(.-)%s*$')
local good
if not empty(rhs) then
for _, item in ipairs({ 'sp', 'default', 'link', 'multiplier', 'symbol', 'symlink' }) do
if lhs == item then
if item == 'sp' then
if rhs == 'us' then
unit.sp_us = true
good = true
end
elseif item == 'link' then
local tlink
if target then
tlink = target[item]
end
local link, customary = clean_link(rhs, tlink)
if link then
unit[item] = link
end
if customary then
unit.customary = customary
end
good = true
elseif item == 'symlink' then
local pos1 = rhs:find('[[', 1, true)
local pos2 = rhs:find(']]', 1, true)
if not (pos1 and pos2 and (pos1 < pos2)) then
quit('m_als_link', unit.unitcode)
end
unit.symlink = rhs
good = true
elseif item == 'multiplier' then
if not tonumber(rhs) then
quit('m_als_mul', unit.unitcode, rhs)
end
unit[item] = rhs
good = true
else
if target and rhs == target[item] then
quit('m_als_same', item, unit.unitcode)
end
unit[item] = rhs
good = true
end
break
end
end
end
if not good then
quit('m_als_bad', field)
end
end
end
end
local function make_alias(fields, ucode, utype, symbol)
-- Return a new alias unit, or return nil if symbol is not already
-- defined as the unit code of the target unit.
-- Throw an error if invalid.
local target = get_unit(symbol)
if not target then
return nil
end
local unit = { unitcode = ucode, utype = utype, target = symbol }
add_alias_optional_fields(unit, 3, fields, target)
if alias_index[ucode] then
quit('m_als_dup', ucode)
else
alias_index[ucode] = unit
end
if target.utype ~= utype then
quit('m_als_type', ucode)
end
return unit
end
local function make_per(fields, ucode, utype, symbol)
-- Return a new "per" unit, or return nil if symbol is not of form "x/y".
-- Throw an error if invalid.
-- The top, bottom unit codes are checked later, after all units are defined.
local top, bottom = symbol:match('^(.-)/(.*)$')
if not top then
return nil
end
local unit = { unitcode = ucode, utype = utype, per = { strip(top), strip(bottom) } }
add_alias_optional_fields(unit, 3, fields)
if per_index[ucode] then
quit('m_per_dup', ucode)
else
per_index[ucode] = unit
end
return unit
end
local function make_unit(cfg, data)
-- Return a function which, when called, stores a table that defines a
-- single unit. The table is stored in data (also a table).
local fieldnames = {
-- Fields in the Conversions section are assumed to be in the following order.
'unitcode',
'symbol',
'sym_us',
'scale',
'extra',
'name1',
'name2',
'name1_us',
'name2_us',
'prefixes',
'default',
'link',
}
return function (utype, fields)
-- Store a table defining a unit.
-- Throw an error if a problem occurs.
local ucode, symbol = fields[1], fields[2]
if empty(utype) then
quit('m_miss_type')
end
if empty(ucode) then
quit('m_miss_code')
end
if empty(symbol) then
quit('m_miss_sym')
end
local prefix = symbol:sub(1, 1)
if prefix == '~' or prefix == '=' or prefix == '!' or prefix == '*' then
if symbol:sub(1, 2) == '==' then
prefix = symbol:sub(1, 2)
end
symbol = strip(symbol:sub(#prefix + 1)) -- omit prefix and any following whitespace
fields[2] = symbol
else
prefix = nil -- not a valid prefix
end
if prefix == '=' or prefix == '==' then
-- ucode is an alias (a fake unit code used in a convert template), or
-- defines a "per" unit like "$/acre" or "BTU/h".
-- For an alias, symbol is the unit code of the actual unit.
-- For a "per", symbol is of form "x/y" where x and y are unit codes,
-- or x is a recognized currency symbol and y is a unit code.
-- Checking that x and y are valid is deferred until all units have
-- been defined so, for example, "BTU/h" can be defined before "h".
local unit
if prefix == '=' then
unit = make_alias(fields, ucode, utype, symbol)
else
unit = make_per(fields, ucode, utype, symbol)
end
if not unit then
-- Do not define an alias in terms of another alias.
quit('m_als_undef', symbol)
end
insert_unique_unit(data, unit, units_index)
return
elseif prefix == '!' then
-- ucode may be incorrectly entered as a unit code.
-- symbol is a message saying what unit code should be used.
local unit = { unitcode = ucode, shouldbe = symbol }
insert_unique_unit(data, unit, nil)
return
end
-- Make the unit.
local unit = { utype = utype }
for i, name in ipairs(fieldnames) do
if not empty(fields[i]) then
unit[name] = fields[i]
end
end
-- Remove redundancy from unit.
if unit.sym_us == symbol then
unit.sym_us = nil
end
local prefixes = unit.prefixes
local name1, name2 = unit.name1, unit.name2
if name1 then
if name1 == symbol and not prefixes then
-- A unit which takes an SI prefix must not have a nil name because,
-- for example, the name for "kW" = "kilo" .. "watt" (name for "W").
-- The "not prefixes" test is needed for bnwiki where the
-- watt unit has the same name and symbol.
unit.name1 = nil
end
else
name1 = symbol
end
if name2 then
if name2 == name1 .. plural_suffix then
unit.name2 = nil
end
else
name2 = name1 .. plural_suffix
end
local name1_us, name2_us = unit.name1_us, unit.name2_us
if name1_us then
if name1_us == name1 then
unit.name1_us = nil
end
end
if name2_us then
if unit.name1_us then
if name2_us == unit.name1_us .. plural_suffix then
unit.name2_us = nil
end
elseif name2_us == name2 then
unit.name2_us = nil
end
end
-- Other changes to unit.
unit.scale = clean_scale(unit.scale)
local extra = unit.extra
if not empty(extra) then
-- Set appropriate fields for a unit that needs more than a simple
-- multiplication by a ratio of unit scales to convert values.
unit.iscomplex = true
if extra == 'volume/length' then
unit.invert = 1
elseif extra == 'length/volume' then
unit.invert = -1
elseif specials.utype[utype] == 'type_temperature' then
unit.offset = extra
elseif extra == 'invert' then
unit.invert = -1
else
unit.builtin = extra
end
end
if prefix == '~' then
-- Magic code for units like "acre" where the symbol is not really a
-- symbol, and output should use the singular or plural name instead.
unit.usename = 1
elseif prefix == '*' then
-- Magic code for units like "pitch" which have a symbol that is the same as
-- another unit with entries defined in the default or link exceptions tables.
unit.defkey = ucode -- key for default exceptions
unit.linkey = ucode -- key for link exceptions
end
local name_for_link
if prefixes then
if prefixes == 'SI' then
unit.prefixes = 1
elseif prefixes == 'SI2' then
unit.prefixes = 2
elseif prefixes == 'SI3' then
unit.prefixes = 3
else
quit('m_pfx_bad', prefixes)
end
else
-- Only units which do not accept SI prefixes have name_for_link set.
-- That is because, for example, if set name_for_link = name1 for unit g,
-- then the link is "kilogram" for kg, and "yottagram" for Yg, and so on
-- for all prefixes. That might be desirable for some units, but not all.
name_for_link = name1
end
unit.link, unit.customary = clean_link(unit.link, name_for_link)
if prefixes then
-- The SI prefix is always at the start (position = 1) for symbol and sym_us.
-- However, each name (name1, name2, name1_us, name2_us) can have the SI prefix
-- at any position, and that position can be different for each name.
-- For enwiki, the only units with names where the prefix is not at the start
-- are "square metre" and "cubic metre" ("square meter" and "cubic meter" for sp=us).
-- Some other wikis want the flexibility that the prefix position can be different
-- so the position is stored as nil (if always 1), or N (an integer, if always N),
-- or a string of four comma-separated numbers such as "5,7,9,11" which means the
-- prefix position for (name1, name2, name1_us, name2_us) is (5, 7, 9, 11)
-- respectively.
local name1, name1_us = unit.name1, unit.name1_us -- after redundancy removed
if not name1 then
quit('m_pfx_name')
end
local positions = collection()
for i, k in ipairs({ 'name1', 'name2', 'name1_us', 'name2_us' }) do
local name = unit[k]
local pos
if name then
pos = name:find('%s', 1, true)
if pos then
unit[k] = name:sub(1, pos - 1) .. name:sub(pos + 2)
end
elseif i == 2 or i == 3 then
pos = positions[1]
elseif i == 4 then
pos = positions[unit.name1_us and 3 or 2]
end
positions:add(pos or 1)
end
local pos = positions[1]
for i = 2, positions.n do
if pos ~= positions[i] then
pos = '"' .. positions:join(',') .. '"'
break
end
end
if pos ~= 1 then
unit.prefix_position = pos
end
for _, name in ipairs({ 'symbol', 'sym_us', 'name1', 'name1_us', 'name2', 'name2_us' }) do
unit['_' .. name] = unit[name]
unit[name] = nil -- force call to __index metamethod so any SI prefix can be handled
end
end
for name, v in pairs(unit) do
-- Reject if a string field includes "%s" (should not occur after above).
if type(v) == 'string' and v:find('%s', 1, true) then
quit('m_percent_s', name)
end
end
insert_unique_unit(data, unit, units_index)
end
end
local function make_combination(cfg, data)
-- Return a function which, when called, stores a table that defines a
-- single combination unit. The table is stored in data (also a table).
return function (utype, fields)
-- Store a table defining a unit.
-- This is for a combination unit that specifies more than one output.
-- The target units must be defined first.
-- Throw an error if a problem occurs.
local unit = { utype = utype, combination = {} }
for i, v in ipairs(fields) do
if i == 1 then -- unitcode
if v == '' then
quit('m_cmb_miss')
end
unit.unitcode = v
elseif v == '' then
-- Ignore empty fields.
else
local target = get_unit(v)
if not target then
quit('m_cmb_undef', v, unit.unitcode)
end
if target.utype ~= utype then
quit('m_cmb_type', v, unit.unitcode)
end
table.insert(unit.combination, v)
end
end
if #unit.combination < 2 then
quit(#unit.combination == 0 and 'm_cmb_none' or 'm_cmb_one', unit.unitcode)
end
insert_unique_unit(data, unit, units_index)
end
end
local function make_perunit(cfg, data)
-- Return a function which, when called, stores a table that defines a
-- fixup for an automatic per unit. The table is stored in data (also a table).
local pertype_index = {} -- to detect attempts to define a fixup twice
return function (utype, fields)
-- Store a table to define a fixup.
-- Typos or other errors in the input are not detected!
-- Parameter utype is ignored (it is nil).
-- Throw an error if a problem occurs.
local lhs, rhs, link, multiplier
for i, v in ipairs(fields) do
if v == '' then
-- Ignore empty fields.
elseif i == 1 then
lhs = v -- like "length/time"
elseif i == 2 then
rhs = v -- like "speed"
elseif i == 3 then
link = v
elseif i == 4 then
if not tonumber(v) then
quit('m_per_inv')
end
multiplier = v
else
quit('m_per_inv')
end
end
if lhs and (rhs or link or multiplier) then
if link or multiplier then
local parts = collection()
if rhs then
parts:add('utype = "' .. rhs .. '"')
end
if link then
parts:add('link = "' .. link .. '"')
end
if multiplier then
parts:add('multiplier = ' .. multiplier)
end
rhs = '{ ' .. parts:join(', ') .. ' }'
else
rhs = '"' .. rhs .. '"'
end
if pertype_index[lhs] then
quit('m_per_dup', lhs)
end
pertype_index[lhs] = rhs
table.insert(data, { lhs = lhs, rhs = rhs })
else
quit('m_per_inv')
end
end
end
local function make_varname(cfg, data)
-- Return a function which, when called, stores a table that defines a
-- variable name for a unit. The table is stored in data (also a table).
return function (utype, fields)
-- Set or update an entry in the data table to record that a unit has a variable name.
-- This is for slwiki where a unit name depends on the value.
-- The target units must be defined first.
-- Parameter utype is ignored (it is nil).
-- Throw an error if a problem occurs.
local count = #fields
if count ~= cfg.varcolumns then
quit('m_var_cnt')
end
local ucode
local names = {}
for i = 1, count do
local v = fields[i]
if empty(v) then
quit('m_var_miss')
end
if i == 1 then -- unitcode
ucode = v
if not get_unit(v) then
quit('m_var_undef', v)
end
else
table.insert(names, v)
end
end
if data[ucode] then
quit('m_var_dup', ucode)
end
data[ucode] = table.concat(names, '!')
end
end
local function reversed(t)
-- Return a numbered table in reverse order.
local reversed, count = {}, #t
for i = 1, count do
reversed[i] = t[count + 1 - i]
end
return reversed
end
local function make_inputmultiple(cfg, data)
-- Return a function which, when called, stores a table that defines a
-- single composite (multiple input) unit. The table is stored in data (also a table).
return function (utype, fields)
-- Set or update an entry in the data table to record that a unit
-- accepts subdivisions to make a composite input unit like '|2|ft|6|in'.
-- The target units must be defined first.
-- Throw an error if a problem occurs.
local unitcode -- dummy code required for simplicity, but which is not used in output
local alternate_code -- an alternative unit code can be specified to replace convert input
local fixed_name -- a fixed name can be specified to replace the unit's normal symbol/name
local default_code
local ucodes, scales = {}, {}
for i, v in ipairs(fields) do
-- 1=composite, 2=ucode1, 3=ucode2, 4=default, 5=alternate, 6=name
if i == 1 then
if v == '' then
quit('m_cmp_miss')
end
unitcode = v
elseif 2 <= i and i <= 5 then
if not (i == 5 and v == '') then
local target = get_unit(v, (i == 4) and utype or nil) -- the default may be an auto combination
if not target then
quit('m_cmp_undef', v, unitcode)
end
if target.utype ~= utype then
quit('m_cmp_type', v, unitcode)
end
if i < 4 then
if not target.scale then
quit('m_mul_std', v, unitcode)
end
table.insert(ucodes, v)
table.insert(scales, target.scale)
elseif i == 4 then
default_code = v
else
if scales[#scales] ~= target.scale then
quit('m_cmp_scale', v, unitcode)
end
alternate_code = v
end
end
elseif i == 6 then
if v ~= '' then
fixed_name = v
end
else
quit('m_cmp_many', unitcode)
end
end
if #ucodes ~= 2 then
quit('m_cmp_two', unitcode)
end
if not default_code then
quit('m_cmp_def', unitcode)
end
-- Component units must be specified from most-significant to least-significant,
-- and each ratio of a pair of scales must be very close to an integer.
-- Currently, there will be exactly two scales and one ratio.
local ratios, count = {}, #scales
for i = 1, count do
local scale = tonumber(scales[i])
if scale == nil or scale <= 0 then
quit('m_cmp_inval', unitcode, scales[i])
end
scales[i] = scale
end
for i = 1, count - 1 do
local ratio = scales[i] / scales[i + 1]
local rounded = math.floor(ratio + 0.5)
if rounded < 2 then
quit('m_cmp_order', unitcode)
end
if math.abs(ratio - rounded)/ratio > 1e-6 then
quit('m_cmp_int', unitcode)
end
ratios[i] = rounded
end
local text = { tostring(ratios[1]) }
local function add_text(key, value)
table.insert(text, string.format('%s = %q', key, value))
end
if default_code then
add_text('default', default_code)
end
if alternate_code then
add_text('unit', alternate_code)
end
if fixed_name then
add_text('name', fixed_name)
end
local subdiv = string.format('["%s"] = { %s }', ucodes[2], table.concat(text, ', '))
local main_code = ucodes[1]
local item = data[main_code]
if item then
table.insert(item.subdivs, subdiv)
else
data[main_code] = { subdivs = { subdiv } }
end
end
end
local function make_outputmultiple(cfg, data)
-- Return a function which, when called, stores a table that defines a
-- single multiple output unit. The table is stored in data (also a table).
return function (utype, fields)
-- Store a table defining a unit.
-- This is for a multiple unit like 'ydftin' (result in yards, feet, inches).
-- The target units must be defined first.
-- Throw an error if a problem occurs.
local unit = { utype = utype }
local ucodes, scales = {}, {}
for i, v in ipairs(fields) do
if i == 1 then -- unitcode
if v == '' then
quit('m_mul_miss')
end
unit.unitcode = v
elseif v == '' then
-- Ignore empty fields.
else
local target = get_unit(v)
if not target then
quit('m_mul_undef', v, unit.unitcode)
end
if target.utype ~= utype then
quit('m_mul_type', v, unit.unitcode)
end
if not target.scale then
quit('m_mul_std', v, unit.unitcode)
end
table.insert(ucodes, v)
table.insert(scales, target.scale)
end
end
if #ucodes < 2 then
quit(#ucodes == 0 and 'm_mul_none' or 'm_mul_one', unit.unitcode)
end
-- Component units must be specified from most-significant to least-significant
-- (so scale values will be in descending order),
-- and each ratio of a pair of scales must be very close to an integer.
-- The componenets and ratios are stored in reverse order (least significant first).
-- This script stores a unit scale as a string (might be an expression like "5/9"),
-- but scales in a multiple are handled as numbers (should never be expressions).
local ratios, count = {}, #scales
for i = 1, count do
local scale = tonumber(scales[i])
if scale == nil or scale <= 0 then
quit('m_mul_scale', unit.unitcode, scales[i])
end
scales[i] = scale
end
for i = 1, count - 1 do
local ratio = scales[i] / scales[i + 1]
local rounded = math.floor(ratio + 0.5)
if rounded < 2 then
quit('m_mul_order', unit.unitcode)
end
if math.abs(ratio - rounded)/ratio > 1e-6 then
quit('m_mul_int', unit.unitcode)
end
ratios[i] = rounded
end
unit.combination = reversed(ucodes)
unit.multiple = reversed(ratios)
insert_unique_unit(data, unit, units_index)
end
end
-- To make updating the data module easier, this script inserts a preamble
-- and a postamble so the result can be used to replace the whole page.
local data_preamble = [=[
-- Conversion data used by [[Module:Convert]] which uses mw.loadData() for
-- read-only access to this module so that it is loaded only once per page.
-- See [[:en:Template:Convert/Transwiki guide]] if copying to another wiki.
--
-- These data tables follow:
-- all_units all properties for a unit, including default output
-- default_exceptions exceptions for default output ('kg' and 'g' have different defaults)
-- link_exceptions exceptions for links ('kg' and 'g' have different links)
--
-- These tables are generated by a script which reads the wikitext of a page that
-- documents the required properties of each unit; see [[:en:Module:Convert/doc]].
]=]
local data_postamble = [=[
return {
all_units = all_units,
default_exceptions = default_exceptions,
link_exceptions = link_exceptions,
per_unit_fixups = per_unit_fixups,
}]=]
local out_unit_prefix = [[
---------------------------------------------------------------------------
-- Do not change the data in this table because it is created by running --
-- a script that reads the wikitext from a wiki page (see note above). --
---------------------------------------------------------------------------
local all_units = {]]
local out_unit_suffix = [[
}
]]
local out_default_prefix = [[
---------------------------------------------------------------------------
-- Do not change the data in this table because it is created by running --
-- a script that reads the wikitext from a wiki page (see note above). --
---------------------------------------------------------------------------
local default_exceptions = {
-- Prefixed units with a default different from that of the base unit.
-- Each key item is a prefixed symbol (unitcode for engineering notation).]]
local out_default_suffix = [[
}
]]
local out_default_item = [[
["{symbol}"] = "{default}",]]
local out_link_prefix = [[
---------------------------------------------------------------------------
-- Do not change the data in this table because it is created by running --
-- a script that reads the wikitext from a wiki page (see note above). --
---------------------------------------------------------------------------
local link_exceptions = {
-- Prefixed units with a linked article different from that of the base unit.
-- Each key item is a prefixed symbol (not unitcode).]]
local out_link_suffix = [[
}
]]
local out_link_item = [[
["{symbol}"] = "{link}",]]
local out_perunit_prefix = [[
---------------------------------------------------------------------------
-- Do not change the data in this table because it is created by running --
-- a script that reads the wikitext from a wiki page (see note above). --
---------------------------------------------------------------------------
local per_unit_fixups = {
-- Automatically created per units of form "x/y" may have their unit type
-- changed, for example, "length/time" is changed to "speed".
-- Other adjustments can also be specified.]]
local out_perunit_suffix = [[
}
]]
local out_perunit_item = [[
["{lhs}"] = {rhs},]]
local combination_specification = { -- pure combination like 'm ft', or a multiple like 'ftin'
'combination',
'multiple',
'utype',
}
local alias_specification = {
'target',
'symbol',
'sp_us',
'default',
'link',
'symlink',
'customary',
'multiplier',
}
local per_specification = {
'per',
'symbol',
'sp_us',
'utype',
'invert',
'iscomplex',
'default',
'link',
'symlink',
'customary',
'multiplier',
}
local shouldbe_specification = {
'shouldbe',
}
local unit_specification = {
'_name1',
'_name1_us',
'_name2',
'_name2_us',
'_symbol',
'_sym_us',
'prefix_position',
'name1',
'name1_us',
'name2',
'name2_us',
'varname',
'symbol',
'sym_us',
'usename',
'usesymbol',
'utype',
'alttype',
'builtin',
'scale',
'offset',
'invert',
'iscomplex',
'istemperature',
'exception',
'prefixes',
'default',
'subdivs',
'defkey',
'linkey',
'link',
'customary',
'sp_us',
}
local no_quotes = {
combination = true,
customary = true,
multiple = true,
multiplier = true,
offset = true,
per = true,
prefix_position = true,
scale = true,
subdivs = true,
}
local function add_unit_lines(results, unit, spec)
-- Add lines of Lua source to define a unit to the results collection.
local function add_line(line)
-- Had planned to replace sequences of spaces with 4-column tabs here
-- (because the CodeEditor now assumes the use of such tabs).
-- However, 4-column tabs are only visible when editing a module
-- with browser scripting and the CodeEditor enabled, and that is rare.
-- A module is usually viewed (with 8-column tabs), and some indents
-- would be messed up unless 8-column tabs are used. Therefore,
-- have decided to simply replace 8 spaces at start of line with a single
-- tab which reduces the size of the module, and is correct for viewing.
if line:sub(1, 8) == string.rep(' ', 8) then
line = '\t' .. line:sub(9)
end
results:add(line)
end
local first_item = ' ["' .. unit.unitcode .. '"] = {'
local last_item = ' },'
add_line(first_item)
for _, k in ipairs(spec) do
local v = unit[k]
if v then
local want_quotes = (type(v) == 'string' and not no_quotes[k])
if type(v) == 'boolean' then
v = tostring(v)
elseif type(v) == 'number' or k == 'scale' then
-- Replace results like '1e-006' with '1e-6'.
v = string.gsub(tostring(v), '(e[+-])0+([1-9].*)', '%1%2', 1)
elseif type(v) ~= 'string' then
quit('m_ftl_type', unit.unitcode)
end
local fmt = string.format('%8s%%-9s= %%%s,', '', want_quotes and 'q' or 's')
add_line(fmt:format(k, v))
end
end
add_line(last_item)
end
local function numbered_table_as_string(data, unit)
local t = {}
for _, v in ipairs(data) do
if type(v) == 'string' then
table.insert(t, '"' .. v .. '"')
elseif type(v) == 'number' then
table.insert(t, tostring(v))
else
quit('m_ftl_type', unit.unitcode)
end
end
return '{ ' .. table.concat(t, ', ') .. ' }'
end
local function extract_heading(line)
-- Return n, s where n = heading level number (nil if none), and
-- s = heading text (with leading/trailing whitespace removed).
local pattern = '^(==+)%s*(.-)%s*(==+)%s*$'
local before, heading, after = line:match(pattern)
if heading and #heading > 0 then
-- Don't bother checking if before == after.
return #before, heading
end
end
local function fields(line)
-- Return a numbered table of fields split from line.
-- Items are delimited by "||".
-- Each item has leading/trailing whitespace removed, and any encoded pipe
-- characters are decoded.
-- The second field (for symbol when processing units) is adjusted to
-- remove any "colspan" at the front of lines like:
-- "| unitcode || colspan="11" | !Text to display for an error message".
local t = {}
line = line .. "||" -- to get last field
for item in line:gmatch("%s*(.-)%s*||") do
table.insert(t, (item:gsub('|', '|')))
end
if t[2] then
local cleaned = t[2]:match('^%s*colspan%s*=.-|%s*(.*)$')
if cleaned then
t[2] = cleaned
end
end
return t
end
local function prepare_section(cfg, maker, lines, section, need_section, need_utype)
-- Process the first level-two section with the given section name
-- in the given table of lines of wikitext.
-- If successful, maker inserts each item into a table.
-- Otherwise, an error is thrown.
local skip = true
local errors = collection()
local utype -- unit type (from level-three heading)
local nbsp = '\194\160' -- nonbreaking space is utf-8 encoded as hex c2 a0
for linenumber, line in ipairs(lines) do
if skip then
-- Skip down to and including the starting heading.
local level, heading = extract_heading(line)
if level == 2 and heading == section then
skip = false
end
else
-- Accummulate unit definitions.
local c1 = line:sub(1, 1)
local c2 = line:sub(2, 2)
if c1 == '|' and not (c2 == '-' or c2 == '}') then
if need_utype and empty(utype) then
quit('m_hdg_lev3', line)
end
if line:find(nbsp, 1, true) then
-- For example, "acre ft" does not work if it contains nbsp.
add_warning('m_wrn_nbsp', linenumber)
end
local ok, msg = pcall(maker, utype, fields(line:sub(2)))
if not ok then
if msg:sub(-1) == '.' then msg = msg:sub(1, -2) end
errors:add(msg .. message('m_line_num', linenumber))
if errors.n >= cfg.maxerrors then
break
end
end
else
local level, heading = extract_heading(line)
if level == 3 then
utype = ulower(heading)
elseif level == 2 then
break
end
end
end
end
if skip and need_section then
quit('m_hdg_lev2', section)
end
if errors.n > 0 then
error(errors:join(), 0)
end
end
local function get_page_lines(page_title)
-- Read the wikitext of the page at the given title; split the text into
-- lines with leading and trailing space removed from each line.
-- Return a numbered table of the lines, or throw an error.
if empty(page_title) then
quit('m_no_title')
end
local t = mw.title.new(page_title)
if t then
local content = t:getContent()
if content then
if content:sub(-1) ~= '\n' then
content = content .. '\n'
end
local lines = collection()
for line in string.gmatch(content, '[\t ]*(.-)[\t\r ]*\n') do
lines:add(line)
end
return lines
end
end
quit('m_ftl_read', page_title)
end
local function prepare_data(cfg, is_sandbox)
-- Read the page of conversion data, and process the wikitext
-- in the sections with wanted level-two headings.
-- Return units, defaults, links (three tables).
-- Throw an error if a problem occurs.
local composites, defaults, links, units, perunits, varnames = {}, {}, {}, {}, {}, {}
local sections = {
{ 'overrides' , make_override , overrides , 0 },
{ 'conversions' , make_unit , units , 0 },
{ 'outmultiples', make_outputmultiple, units , 0 },
{ 'combinations', make_combination , units , 0 },
{ 'inmultiples' , make_inputmultiple , composites, 0 }, -- after all units defined so default will be defined
{ 'defaults' , make_default , defaults , 0 },
{ 'links' , make_link , links , 0 },
{ 'perunits' , make_perunit , perunits , 1 },
{ 'varnames' , make_varname , varnames , 1 },
}
local lines = get_page_lines(cfg.data_title)
for _, section in ipairs(sections) do
local heading = mtext.section_names[section[1]]
local maker = section[2](cfg, section[3])
local code = section[4]
local need_section, need_utype
if code == 0 and not is_sandbox then
need_section = true
end
if code == 0 then
need_utype = true
end
prepare_section(cfg, maker, lines, heading, need_section, need_utype)
end
check_all_defaults(cfg, units)
check_all_pers(cfg, units)
update_units(units, composites, varnames)
return units, defaults, links, perunits
end
local function _makeunits(cfg, results)
-- Read the wikitext for the conversion data.
-- Append output to given results collection, or throw error if a problem.
text_code = require(cfg.text_title)
for _, name in ipairs({ 'SIprefixes', 'eng_scales', 'currency' }) do
if type(text_code[name]) ~= 'table' then
quit('m_ftl_table', cfg.text_title, name)
end
end
local translation = text_code.translation_table
if translation then
if translation.plural_suffix then
plural_suffix = translation.plural_suffix
end
local ts = translation.specials
if ts then
if ts.utype then
specials.utype = ts.utype
end
if ts.ucode then
specials.ucode = ts.ucode
end
end
local tm = translation.mtext
if tm then
if tm.section_names then
mtext.section_names = tm.section_names
end
if tm.titles then
mtext.titles = tm.titles
end
if tm.messages then
mtext.messages = tm.messages
end
end
end
local is_sandbox
local conversion_data_title = mtext.titles.conversion_data
if cfg.data_title and cfg.data_title ~= conversion_data_title then
if is_test_run then
is_sandbox = true
data_preamble = nil
data_postamble = nil
out_unit_prefix = 'local all_units = {'
out_unit_suffix = '}'
out_default_prefix = '\nlocal default_exceptions = {'
out_default_suffix = '}'
out_default_item = '\t["{symbol}"] = "{default}",'
out_link_prefix = '\nlocal link_exceptions = {'
out_link_suffix = '}'
out_link_item = '\t["{symbol}"] = "{link}",'
out_perunit_prefix = '\nlocal per_unit_fixups = {'
out_perunit_suffix = '}'
out_perunit_item = '\t["{lhs}"] = {rhs},'
end
else
cfg.data_title = conversion_data_title
end
local units, defaults, links, perunits = prepare_data(cfg, is_sandbox)
if data_preamble then
results:add(data_preamble)
end
results:add(out_unit_prefix)
for _, unit in ipairs(units) do
local spec
if unit.target then
spec = alias_specification
elseif unit.per then
spec = per_specification
unit.per = numbered_table_as_string(unit.per, unit)
elseif unit.shouldbe then
spec = shouldbe_specification
elseif unit.combination then
spec = combination_specification
unit.combination = numbered_table_as_string(unit.combination, unit)
if unit.multiple then
unit.multiple = numbered_table_as_string(unit.multiple, unit)
end
else
spec = unit_specification
end
add_unit_lines(results, unit, spec)
end
results:add(out_unit_suffix)
for _, t in ipairs({
{ defaults, out_default_prefix, out_default_item, out_default_suffix },
{ links , out_link_prefix , out_link_item , out_link_suffix },
{ perunits, out_perunit_prefix, out_perunit_item, out_perunit_suffix } }) do
local data, prefix, item, suffix = t[1], t[2], t[3], t[4]
if #data > 0 or not is_sandbox then
results:add(prefix)
for _, unit in ipairs(data) do
results:add((item:gsub('{([%w_]+)}', unit)))
end
results:add(suffix)
end
end
if data_postamble then
results:add(data_postamble)
end
end
local function makeunits(frame)
local args = frame.args
local config = {
data_title = args[1],
text_title = args[2] or 'Module:Convert/text',
varcolumns = tonumber(args.varcolumns) or 5, -- #columns in "Variable names" section; slwiki uses 5
maxerrors = 20,
}
local results = collection()
local ok, msg = pcall(_makeunits, config, results)
if not ok then
results:add(message('m_error'))
results:add('')
results:add(msg)
end
local warn = ''
if warnings.n > 0 then
warn = message('m_warning') .. '\n\n' .. warnings:join() .. '\n\n'
end
-- Pre tags returned by a module are html tags, not like wikitext <pre>...</pre>.
-- The following renders the text as is, and preserves tab characters.
return '<pre>\n' .. mw.text.nowiki(warn .. results:join()) .. '\n</pre>\n'
end
return { makeunits = makeunits }
m1brlk8ynmd7rclztvslc8ekiai88x4
وحدة:Convert/extra
828
28897
118027
2022-08-10T20:53:28Z
ForzaGreen
14525
أنشأ الصفحة ب'-- Extra conversion data used by Module:Convert. -- -- [[Module:Convert/data]] defines all units and is transcluded in all pages -- where [[Module:Convert]] is used. Testing new units by editing that module -- would invalidate the cache for all affected pages. -- -- For quick changes and experiments with new units, this module can be edited. -- Since this module is transcluded in only a small number of pages, changes -- should cause little server overhead and shoul...'
Scribunto
text/plain
-- Extra conversion data used by Module:Convert.
--
-- [[Module:Convert/data]] defines all units and is transcluded in all pages
-- where [[Module:Convert]] is used. Testing new units by editing that module
-- would invalidate the cache for all affected pages.
--
-- For quick changes and experiments with new units, this module can be edited.
-- Since this module is transcluded in only a small number of pages, changes
-- should cause little server overhead and should propagate quickly.
--
-- If a unit is defined in the data module, any definition here is ignored,
-- so defining the same unit in both modules is not an error.
-- A unit defined here can refer to units that are also defined here, and
-- can refer to units defined in the data module.
--
-- Periodically, those extra units that are wanted permanently can be removed
-- from here after being added to [[Module:Convert/data]].
local extra_units = {
["u"] = {
symbol = "u",
name1 = "unified atomic mass unit",
utype = "mass",
scale = 1.6605389e-27,
prefixes = 1,
default = "kg",
link = "Atomic mass unit",
},
["dalton"] = {
target = "u",
symbol = "Da",
name1 = "dalton",
},
["feddan"] = {
symbol = "feddan",
usename = 1,
utype = "area",
scale = 4200,
default = "m2",
},
["Mi"] = {
name1 = "mile",
symbol = "mi",
utype = "length",
scale = 1609.344,
default = "km",
subdivs = { ["ch"] = { 80, default = "km" }, ["chain"] = { 80, default = "km" }, ["ft"] = { 5280, default = "km" }, ["yd"] = { 1760, default = "km" }, ["furlong"] = { 8, default = "km" } },
},
["micron"] = {
target = "µm",
default = "µin",
},
}
return { extra_units = extra_units }
b1xlnfayk4vwlagw13afyobwux3cwqs
وحدة:Convert/wikidata/data
828
28898
118028
2022-08-10T20:57:00Z
ForzaGreen
14525
أنشأ الصفحة ب'--[[ Cache of Wikidata information with units for Module:Convert. The codes should rarely change, and using a cache means that changing a unit at Wikidata will not cause lots of converts in articles to break. For a unit known to convert, the unit here must have: label = Wikidata label for unit (used only when listing units) ucode = unit code for input to convert (there are no optional fields because convert handles everything) For a unit not known to convert,...'
Scribunto
text/plain
--[[ Cache of Wikidata information with units for Module:Convert.
The codes should rarely change, and using a cache means that changing a
unit at Wikidata will not cause lots of converts in articles to break.
For a unit known to convert, the unit here must have:
label = Wikidata label for unit (used only when listing units)
ucode = unit code for input to convert
(there are no optional fields because convert handles everything)
For a unit not known to convert, the unit here must have:
label = Wikidata label for unit (used only when listing units)
(no ucode field)
_ucode = unit code for input to convert, and the
symbol used to display the unit when abbr=on
(convert will use the specified fields to display the unit,
and will not attempt to do a conversion)
For a unit not known to convert, the unit here may have:
name1 = singular name used to display the unit when abbr=off
name2 = plural name used to display the unit when abbr=off
link = name of article that unit will be linked to when lk=on
si = key for the SI base unit, if any
The base unit for each SI unit here must have:
symbol = symbol used to display the base unit when abbr=on
name1 = singular name of base unit used to display the unit when abbr=off
(if name1 is not given, symbol will be used, but an SI unit should have a name)
The base unit for each SI unit here may have:
name2 = plural name of base unit used to display the unit when abbr=off
link = name of article that unit will be linked to when lk=on
(applies for all SI units using this base, where the
SI unit does not define its own link field)
If name1 is not specified, the symbol is used for the name.
If name2 is not specified, a plural name is formed by appending 's' to name1.
If link is not specified, name1 is used for the link.
SI units are assumed to be simple items like V (volt) where 'mV' would
cause convert to insert:
'm' before the base symbol 'V' to make 'mV', if abbr=on
'milli' before the base name 'volt' to make 'millivolt', if abbr=off
A unit like "square meter" would not work because it needs an SI prefix
inserted before "meter" rather than at the beginning of the name.
Items that should not be used with convert as no precise unit is implied:
Q11247037 ton generic (cannot use)
Q178413 gallon generic
Q130964 calorie dubious (ambiguous, should not use)
Q216658 bushel dubious
Q420266 fluid ounce dubious
]]
local wikidata_units = {
-- Following are SI base units.
A = {
symbol = 'A',
name1 = 'ampere',
},
F = {
symbol = 'F',
name1 = 'faraday',
},
H = {
symbol = 'H',
name1 = 'henry',
},
V = {
symbol = 'V',
name1 = 'volt',
},
-- Following are aliases to convert unit codes, used with "input=<value><space><unit>".
kilograms = {
ucode = 'kg',
},
-- Following are SI units not known to convert, used with "input=<value><space><unit>".
kV = {
ucode = 'kV',
si = 'V',
},
mV = {
ucode = 'mV',
si = 'V',
},
-- Following are Wikidata units.
Q131255 = {
label = 'farad',
_ucode = 'F',
si = 'F',
},
Q163354 = {
label = 'henry',
_ucode = 'H',
si = 'H',
},
Q1916026 = {
label = 'microvolt',
_ucode = 'uV',
si = 'V',
},
Q193933 = {
label = 'dioptre',
name1 = 'dioptre',
_ucode = 'dpt',
},
Q212120 = {
label = 'ampere-hour',
name1 = 'ampere-hour',
_ucode = 'A⋅h',
},
Q2448803 = {
label = 'millivolt',
_ucode = 'mV',
si = 'V',
},
Q2451296 = {
label = 'microfarad',
_ucode = 'uF',
si = 'F',
},
Q2490574 = {
label = 'milliampere',
_ucode = 'mA',
si = 'A',
},
Q25250 = {
label = 'volt',
_ucode = 'V',
si = 'V',
},
Q25272 = {
label = 'ampere',
_ucode = 'A',
si = 'A',
},
Q2553708 = {
label = 'megavolt',
_ucode = 'MV',
si = 'V',
},
Q2554092 = {
label = 'kilovolt',
_ucode = 'kV',
si = 'V',
},
Q2636421 = {
label = 'nanohenry',
_ucode = 'nH',
si = 'H',
},
Q2679083 = {
label = 'microhenry',
_ucode = 'uH',
si = 'H',
},
Q2682463 = {
label = 'nanofarad',
_ucode = 'nF',
si = 'F',
},
Q2756030 = {
label = 'picofarad',
_ucode = 'pF',
si = 'F',
},
Q2793566 = {
label = 'gigavolt',
_ucode = 'GV',
si = 'V',
},
Q2924137 = {
label = 'millihenry',
_ucode = 'mH',
si = 'H',
},
Q3117809 = {
label = 'microampere',
_ucode = 'uA',
si = 'A',
},
Q33680 = {
label = 'radian',
name1 = 'radian',
_ucode = 'rad',
},
Q4456994 = {
label = 'millifarad',
_ucode = 'mF',
si = 'F',
},
Q47083 = {
label = 'ohm',
name1 = 'ohm',
_ucode = 'Ω',
},
Q483261 = {
label = 'atomic mass unit',
name1 = 'atomic mass unit',
_ucode = 'u',
},
Q550341 = {
label = 'volt-ampere',
name1 = 'volt-ampere',
_ucode = 'VA',
},
Q100995 = {
label = 'pound',
ucode = 'lb',
},
Q1022113 = {
label = 'cubic centimetre',
ucode = 'cc',
},
Q102573 = {
label = 'becquerel',
ucode = 'Bq',
},
Q103246 = {
label = 'sievert',
ucode = 'Sv',
},
Q1050958 = {
label = 'inch of mercury',
ucode = 'inHg',
},
Q1051665 = {
label = 'metre per second squared',
ucode = 'm/s2',
},
Q1052397 = {
label = 'rad',
ucode = 'rad',
},
Q1054140 = {
label = 'megametre',
ucode = 'Mm',
},
Q1057069 = {
label = 'hectogram',
ucode = 'hg',
},
Q1063786 = {
label = 'square inch',
ucode = 'sqin',
},
Q1092296 = {
label = 'annum',
ucode = 'year',
},
Q11570 = {
label = 'kilogram',
ucode = 'kg',
},
Q11573 = {
label = 'metre',
ucode = 'm',
},
Q11574 = {
label = 'second',
ucode = 's',
},
Q11579 = {
label = 'kelvin',
ucode = 'K',
},
Q11582 = {
label = 'liter',
ucode = 'liter',
},
Q1165588 = {
label = 'rod',
ucode = 'rod',
},
Q1165799 = {
label = 'thou',
ucode = 'thou',
},
Q11776930 = {
label = 'megagram',
ucode = 'Mg',
},
Q11929860 = {
label = 'kiloparsec',
ucode = 'kpc',
},
Q1194225 = {
label = 'pound-force',
ucode = 'lbf',
},
Q12129 = {
label = 'parsec',
ucode = 'pc',
},
Q12438 = {
label = 'newton',
ucode = 'N',
},
Q1255620 = {
label = 'dram',
ucode = 'drachm',
},
Q12874593 = {
label = 'watt-hour',
ucode = 'W.h',
},
Q128822 = {
label = 'knot',
ucode = 'kn',
},
Q1374438 = {
label = 'kilosecond',
ucode = 'ks',
},
Q1377051 = {
label = 'gigasecond',
ucode = 'Gs',
},
Q14754979 = {
label = 'zettagram',
ucode = 'Zg',
},
Q14786969 = {
label = 'megajoule',
ucode = 'MJ',
},
Q14787261 = {
label = 'megawatt hour',
ucode = 'MW.h',
},
Q1550511 = {
label = 'square yard',
ucode = 'sqyd',
},
Q160857 = {
label = 'horsepower',
ucode = 'hp',
},
Q1628990 = {
label = 'horsepower-hour',
ucode = 'hph',
},
Q163343 = {
label = 'tesla',
ucode = 'T',
},
Q1645498 = {
label = 'microgram',
ucode = 'ug',
},
Q17087835 = {
label = 'cuerda',
ucode = 'cda',
},
Q174728 = {
label = 'centimetre',
ucode = 'cm',
},
Q174789 = {
label = 'millimetre',
ucode = 'mm',
},
Q175821 = {
label = 'micrometre',
ucode = 'um',
},
Q1770733 = {
label = 'teragram',
ucode = 'Tg',
},
Q1772386 = {
label = 'decigram',
ucode = 'dg',
},
Q177493 = {
label = 'gauss',
ucode = 'G',
},
Q1777507 = {
label = 'femtosecond',
ucode = 'fs',
},
Q177974 = {
label = 'atmosphere',
ucode = 'atm',
},
Q178674 = {
label = 'nanometre',
ucode = 'nm',
},
Q180154 = {
label = 'kilometre per hour',
ucode = 'km/h',
},
Q180892 = {
label = 'solar mass',
ucode = 'solar mass',
},
Q1811 = {
label = 'astronomical unit',
ucode = 'au',
},
Q1815100 = {
label = 'centiliter',
ucode = 'cl',
},
Q182098 = {
label = 'kilowatt hour',
ucode = 'kW.h',
},
Q1823150 = {
label = 'microwatt',
ucode = 'uW',
},
Q182429 = {
label = 'metre per second',
ucode = 'm/s',
},
Q1826195 = {
label = 'deciliter',
ucode = 'dl',
},
Q185078 = {
label = 'are',
ucode = 'a',
},
Q185153 = {
label = 'erg',
ucode = 'erg',
},
Q185648 = {
label = 'torr',
ucode = 'Torr',
},
Q190095 = {
label = 'gray',
ucode = 'Gy',
},
Q191118 = {
label = 'tonne',
ucode = 'tonne',
},
Q1913097 = {
label = 'femtogram',
ucode = 'fg',
},
Q192274 = {
label = 'picometre',
ucode = 'pm',
},
Q1972579 = {
label = 'poundal',
ucode = 'pdl',
},
Q200323 = {
label = 'decimetre',
ucode = 'dm',
},
Q201933 = {
label = 'dyne',
ucode = 'dyn',
},
Q2029519 = {
label = 'hectoliter',
ucode = 'hl',
},
Q2051195 = {
label = 'gigawatt hour',
ucode = 'GW.h',
},
Q207488 = {
label = 'Rankine scale',
ucode = 'R',
},
Q208788 = {
label = 'femtometre',
ucode = 'fm',
},
Q2101 = {
label = 'elementary charge',
ucode = 'e',
},
Q21014455 = {
label = 'metre per minute',
ucode = 'm/min',
},
Q21062777 = {
label = 'megapascal',
ucode = 'MPa',
},
Q21064807 = {
label = 'kilopascal',
ucode = 'kPa',
},
Q211256 = {
label = 'miles per hour',
ucode = 'mph',
},
Q21178489 = {
label = 'barrels per day',
ucode = 'oilbbl/d',
},
Q2143992 = {
label = 'kilohertz',
ucode = 'kHz',
},
Q21467992 = {
label = 'cubic foot per second',
ucode = 'cuft/s',
},
Q215571 = {
label = 'newton metre',
ucode = 'Nm',
},
Q216795 = {
label = 'dunam',
ucode = 'dunam',
},
Q216880 = {
label = 'kilogram-force',
ucode = 'kgf',
},
Q18413919 = {
label = 'centimetre per second',
ucode = 'cm/s',
},
Q218593 = {
label = 'inch',
ucode = 'in',
},
Q2282891 = {
label = 'microliter',
ucode = 'ul',
},
Q2282906 = {
label = 'nanogram',
ucode = 'ng',
},
Q229354 = {
label = 'curie',
ucode = 'Ci',
},
Q232291 = {
label = 'square mile',
ucode = 'sqmi',
},
Q2332346 = {
label = 'milliliter',
ucode = 'ml',
},
Q23387 = {
label = 'week',
ucode = 'week',
},
Q23823681 = {
label = 'terawatt',
ucode = 'TW',
},
Q23925410 = {
label = 'gallon',
ucode = 'impgal',
},
Q23925413 = {
label = 'gallon',
ucode = 'USgal',
},
Q2438073 = {
label = 'attogram',
ucode = 'ag',
},
Q2474258 = {
label = 'millisievert',
ucode = 'mSv',
},
Q2483628 = {
label = 'attosecond',
ucode = 'as',
},
Q2489298 = {
label = 'square centimetre',
ucode = 'cm2',
},
Q2518569 = {
label = 'nanosievert',
ucode = 'nSv',
},
Q25235 = {
label = 'hour',
ucode = 'h',
},
Q25236 = {
label = 'watt',
ucode = 'W',
},
Q25267 = {
label = 'degree Celsius',
ucode = 'C',
},
Q25269 = {
label = 'joule',
ucode = 'J',
},
Q253276 = {
label = 'mile',
ucode = 'mi',
},
Q25343 = {
label = 'square metre',
ucode = 'm2',
},
Q25406 = {
label = 'coulomb',
ucode = 'coulomb',
},
Q25517 = {
label = 'cubic metre',
ucode = 'm3',
},
Q260126 = {
label = 'Roentgen equivalent man',
ucode = 'rem',
},
Q2612219 = {
label = 'petagram',
ucode = 'Pg',
},
Q2619500 = {
label = 'Foe',
ucode = 'foe',
},
Q2637946 = {
label = 'decaliter',
ucode = 'dal',
},
Q2655272 = {
label = 'exagram',
ucode = 'Eg',
},
Q2691798 = {
label = 'centigram',
ucode = 'cg',
},
Q2739114 = {
label = 'microsievert',
ucode = 'uSv',
},
Q2799294 = {
label = 'gigagram',
ucode = 'Gg',
},
Q3013059 = {
label = 'kiloannum',
ucode = 'millennium',
},
Q305896 = {
label = 'dots per inch',
ucode = 'dpi',
},
Q3207456 = {
label = 'milliwatt',
ucode = 'mW',
},
Q3221356 = {
label = 'yoctometre',
ucode = 'ym',
},
Q3239557 = {
label = 'picogram',
ucode = 'pg',
},
Q3241121 = {
label = 'milligram',
ucode = 'mg',
},
Q3267417 = {
label = 'terametre',
ucode = 'Tm',
},
Q3270676 = {
label = 'zeptometre',
ucode = 'zm',
},
Q3276763 = {
label = 'gigahertz',
ucode = 'GHz',
},
Q3277907 = {
label = 'exametre',
ucode = 'Em',
},
Q3277915 = {
label = 'zettametre',
ucode = 'Zm',
},
Q3277919 = {
label = 'petametre',
ucode = 'Pm',
},
Q3312063 = {
label = 'femtoliter',
ucode = 'fl',
},
Q3320608 = {
label = 'kilowatt',
ucode = 'kW',
},
Q3332822 = {
label = 'megaton',
ucode = 'Mt(TNT)',
},
Q35852 = {
label = 'hectare',
ucode = 'ha',
},
Q3675550 = {
label = 'cubic millimetre',
ucode = 'mm3',
},
Q3710 = {
label = 'foot',
ucode = 'ft',
},
Q3773454 = {
label = 'megaparsec',
ucode = 'Mpc',
},
Q3902688 = {
label = 'picoliter',
ucode = 'pl',
},
Q3902709 = {
label = 'picosecond',
ucode = 'ps',
},
Q39369 = {
label = 'hertz',
ucode = 'Hz',
},
Q3972226 = {
label = 'kiloliter',
ucode = 'kl',
},
Q4068266 = {
label = "apothecaries' drachm",
ucode = 'drachm',
},
Q41803 = {
label = 'gram',
ucode = 'g',
},
Q4220561 = {
label = 'kilometer per second',
ucode = 'km/s',
},
Q42289 = {
label = 'degree Fahrenheit',
ucode = 'F',
},
Q4243638 = {
label = 'cubic kilometre',
ucode = 'km3',
},
Q44395 = {
label = 'pascal',
ucode = 'Pa',
},
Q48013 = {
label = 'ounce',
ucode = 'oz',
},
Q482798 = {
label = 'yard',
ucode = 'yd',
},
Q4989854 = {
label = 'kilojoule',
ucode = 'kJ',
},
Q4992853 = {
label = 'kiloton',
ucode = 'kt(TNT)',
},
Q5139563 = {
label = 'hectopascal',
ucode = 'hPa',
},
Q5151 = {
label = 'month',
ucode = 'month',
},
Q531 = {
label = 'light-year',
ucode = 'ly',
},
Q5465723 = {
label = 'foot-poundal',
ucode = 'ftpdl',
},
Q573 = {
label = 'day',
ucode = 'd',
},
Q577 = {
label = 'year',
ucode = 'year',
},
Q5879479 = {
label = 'gigawatt',
ucode = 'GW',
},
Q6003257 = {
label = 'attometre',
ucode = 'am',
},
Q613726 = {
label = 'yottagram',
ucode = 'Yg',
},
Q6170164 = {
label = 'yoctogram',
ucode = 'yg',
},
Q667419 = {
label = 'long ton',
ucode = 'LT',
},
Q673166 = {
label = 'gravity of Earth',
ucode = 'g0',
},
Q693944 = {
label = 'grain',
ucode = 'gr',
},
Q6982035 = {
label = 'megawatt',
ucode = 'MW',
},
Q712226 = {
label = 'square kilometre',
ucode = 'km2',
},
Q723733 = {
label = 'millisecond',
ucode = 'ms',
},
Q732454 = {
label = 'Ma',
ucode = 'Myr',
},
Q732707 = {
label = 'megahertz',
ucode = 'MHz',
},
Q752079 = {
label = 'gross register ton',
ucode = 'grt',
},
Q752197 = {
label = 'kilojoule per mole',
ucode = 'kJ/mol',
},
Q7727 = {
label = 'minute',
ucode = 'min',
},
Q794261 = {
label = 'cubic metre per second',
ucode = 'm3/s',
},
Q809678 = {
label = 'barye',
ucode = 'Ba',
},
Q81292 = {
label = 'acre',
ucode = 'acre',
},
Q81454 = {
label = 'ångström',
ucode = 'angstrom',
},
Q828224 = {
label = 'kilometre',
ucode = 'km',
},
Q83327 = {
label = 'electronvolt',
ucode = 'eV',
},
Q838801 = {
label = 'nanosecond',
ucode = 'ns',
},
Q842015 = {
label = 'microsecond',
ucode = 'us',
},
Q844211 = {
label = 'kilogram per cubic metre',
ucode = 'kg/m3',
},
Q844338 = {
label = 'hectometre',
ucode = 'hm',
},
Q844976 = {
label = 'oersted',
ucode = 'Oe',
},
Q848856 = {
label = 'decametre',
ucode = 'dam',
},
Q854546 = {
label = 'gigametre',
ucode = 'Gm',
},
Q857027 = {
label = 'square foot',
ucode = 'sqft',
},
Q9048643 = {
label = 'nanoliter',
ucode = 'nl',
},
Q93318 = {
label = 'nautical mile',
ucode = 'nmi',
},
}
return { wikidata_units = wikidata_units }
e106ma36jajkh7r76vkd8vvo5tf1usx
وحدة:Convert/wikidata
828
28899
118029
2022-08-10T20:57:57Z
ForzaGreen
14525
أنشأ الصفحة ب'-- Functions to access Wikidata for Module:Convert. local Collection = {} Collection.__index = Collection do function Collection:add(item) if item ~= nil then self.n = self.n + 1 self[self.n] = item end end function Collection:join(sep) return table.concat(self, sep) end function Collection:remove(pos) if self.n > 0 and (pos == nil or (0 < pos and pos <= self.n)) then self.n = self.n - 1 return table.remove(self, pos) end end function...'
Scribunto
text/plain
-- Functions to access Wikidata for Module:Convert.
local Collection = {}
Collection.__index = Collection
do
function Collection:add(item)
if item ~= nil then
self.n = self.n + 1
self[self.n] = item
end
end
function Collection:join(sep)
return table.concat(self, sep)
end
function Collection:remove(pos)
if self.n > 0 and (pos == nil or (0 < pos and pos <= self.n)) then
self.n = self.n - 1
return table.remove(self, pos)
end
end
function Collection:sort(comp)
table.sort(self, comp)
end
function Collection.new()
return setmetatable({n = 0}, Collection)
end
end
local function strip_to_nil(text)
-- If text is a non-empty string, return its trimmed content,
-- otherwise return nothing (empty string or not a string).
if type(text) == 'string' then
return text:match('(%S.-)%s*$')
end
end
local function frequency_unit(value, unit_table)
-- For use when converting m to Hz.
-- Return true, s where s = name of unit's default output unit,
-- or return false, t where t is an error message table.
-- However, for simplicity a valid result is always returned.
local unit
if unit_table._symbol == 'm' then
-- c = speed of light in a vacuum = 299792458 m/s
-- frequency = c / wavelength
local w = value * (unit_table.scale or 1)
local f = 299792458 / w -- if w == 0, f = math.huge which works here
if f >= 1e12 then
unit = 'THz'
elseif f >= 1e9 then
unit = 'GHz'
elseif f >= 1e6 then
unit = 'MHz'
elseif f >= 1e3 then
unit = 'kHz'
else
unit = 'Hz'
end
end
return true, unit or 'Hz'
end
local function wavelength_unit(value, unit_table)
-- Like frequency_unit but for use when converting Hz to m.
local unit
if unit_table._symbol == 'Hz' then
-- Using 0.9993 rather than 1 avoids rounding which would give results
-- like converting 300 MHz to 100 cm instead of 1 m.
local w = 1 / (value * (unit_table.scale or 1)) -- Hz scale is inverted
if w >= 0.9993e6 then
unit = 'Mm'
elseif w >= 0.9993e3 then
unit = 'km'
elseif w >= 0.9993 then
unit = 'm'
elseif w >= 0.9993e-2 then
unit = 'cm'
elseif w >= 0.9993e-3 then
unit = 'mm'
else
unit = 'um'
end
end
return true, unit or 'm'
end
local specials = {
frequency = { frequency_unit },
wavelength = { wavelength_unit },
--------------------------------------------------------------------------------
-- Following is a removed experiment to show two values as a range
-- using '-' as the separator.
-- frequencyrange = { frequency_unit, '-' },
-- wavelengthrange = { wavelength_unit, '-' },
}
local function make_unit(units, parms, uid)
-- Return a unit code for convert or nil if unit unknown.
-- If necessary, add a dummy unit to parms so convert will use it
-- for the input without attempting a conversion since nothing
-- useful is available (for example, with unit volt).
local unit = units[uid]
if type(unit) ~= 'table' then
return nil
end
local ucode = unit.ucode
if ucode and not unit.si then
return ucode -- a unit known to convert
end
parms.opt_ignore_error = true
ucode = ucode or unit._ucode -- must be a non-empty string
local ukey, utable
if unit.si then
local base = units[unit.si]
ukey = base.symbol -- must be a non-empty string
local n1 = base.name1
local n2 = base.name2
if not n1 then
n1 = ukey
n2 = n2 or n1 -- do not append 's'
end
utable = {
_symbol = ukey,
_name1 = n1,
_name2 = n2,
link = unit.link or base.link,
utype = n1,
prefixes = 1,
}
else
ukey = ucode
utable = {
symbol = ucode, -- must be a non-empty string
name1 = unit.name1, -- if nil, uses symbol
name2 = unit.name2, -- if nil, uses name1..'s'
link = unit.link, -- if nil, uses name1
utype = unit.name1 or ucode,
}
end
utable.scale = 1
utable.default = ''
utable.defkey = ''
utable.linkey = ''
utable.bad_mcode = ''
parms.unittable = { [ukey] = utable }
return ucode
end
local function matches_qualifier(statement, qual)
-- Return:
-- false, nil : if statement does not match specification
-- true, nil : if matches, and statement has no qualifier
-- true, sq : if matches, where sq is the statement's qualifier
-- A match means that no qualifier was specified (qual == nil), or that
-- the statement has a qualifier matching the specification.
-- If a match occurs, the caller needs the statement's qualifier (if any)
-- so statements that duplicate the qualifier are not used, after the first.
-- Then, if convert is showing all values for a property such as the diameter
-- of a telescope's mirror (diameters of primary and secondary mirrors), it
-- will not show alternative values that could in principle be present for the
-- same item (telescope) and property (diameter) and qualifier (primary/secondary).
local target = (statement.qualifiers or {}).P518 -- P518 is "applies to part"
if type(target) == 'table' then
for _, q in ipairs(target) do
if type(q) == 'table' then
local value = (q.datavalue or {}).value
if value then
if qual == nil or qual == value.id then
return true, value.id
end
end
end
end
end
if qual == nil then
return true, nil -- only occurs if statement has no qualifier
end
return false, nil -- statement's qualifier is not relevant because statement will be skipped
end
local function get_statements(parms, pid)
-- Get specified item and return a list of tables with each statement for property pid.
-- Each table is of form {statqual=sq, stmt=statement} where sq = statement qualifier (nil if none).
-- Statements are in Wikidata's order except that those with preferred rank
-- are first, then normal rank. Any other rank is ignored.
local stored = {} -- qualifiers of statements that are first for the qualifier, and will be returned
local qid = strip_to_nil(parms.qid) -- nil for current page's item, or an item id (expensive)
local qual = strip_to_nil(parms.qual) -- nil or id of wanted P518 (applies to part) item in qualifiers
local result = Collection.new()
local entity = mw.wikibase.getEntity(qid)
if type(entity) == 'table' then
local statements = (entity.claims or {})[pid]
if type(statements) == 'table' then
for _, rank in ipairs({ 'preferred', 'normal' }) do
for _, statement in ipairs(statements) do
if type(statement) == 'table' and rank == statement.rank then
local is_match, statqual = matches_qualifier(statement, qual)
if is_match then
result:add({ statqual = statqual, stmt = statement })
end
end
end
end
end
end
return result
end
local function input_from_property(tdata, parms, pid)
-- Given that pid is a Wikidata property identifier like 'P123',
-- return a collection of {amount, ucode} pairs (two strings)
-- for each matching item/property, or return nothing.
--------------------------------------------------------------------------------
-- There appear to be few restrictions on how Wikidata is organized so it is
-- very likely that any decision a module makes about how to handle data
-- will be wrong for some cases at some time. This meets current requirements.
-- For each qualifier (or if no qualitifer), if there are any preferred
-- statements, use them and ignore any normal statements.
-- For each qualifier, for the preferred statements if any, or for
-- the normal statements (but not both):
-- * Accept each statement if it has no qualifier (this will not occur
-- if qual=x is specified because other code already ensures that in that
-- case, only statements with a qualifier matching x are considered).
-- * Ignore any statements after the first if it has a qualifier.
-- The rationale is that for the diameter at [[South Pole Telescope]], want
-- convert to show the diameters for both the primary and secondary mirrors
-- if the convert does not specify which diameter is wanted.
-- However, if convert is given the wanted qualifier, only one value
-- (_the_ diameter) is wanted. For simplicity/consistency, that is also done
-- even if no qual=x is specified. Unclear what should happen.
-- For the wavelength at [[Nançay Radio Telescope]], want to show all three
-- values, and the values have no qualifiers.
--------------------------------------------------------------------------------
local result = Collection.new()
local done = {}
local skip_normal
for _, t in ipairs(get_statements(parms, pid)) do
local statement = t.stmt
if statement.mainsnak and statement.mainsnak.datatype == 'quantity' then
local value = (statement.mainsnak.datavalue or {}).value
if value then
local amount = value.amount
if amount then
amount = tostring(amount) -- in case amount is ever a number
if amount:sub(1, 1) == '+' then
amount = amount:sub(2)
end
local unit = value.unit
if type(unit) == 'string' then
unit = unit:match('Q%d+$') -- unit item id is at end of URL
local ucode = make_unit(tdata.wikidata_units, parms, unit)
if ucode then
local skip
if t.statqual then
if done[t.statqual] then
skip = true
else
done[t.statqual] = true
end
else
if statement.rank == 'preferred' then
skip_normal = true
elseif skip_normal then
skip = true
end
end
if not skip then
result:add({ amount, ucode })
end
end
end
end
end
end
end
return result
end
local function input_from_text(tdata, parms, text, insert2)
-- Given string should be of form "<value><space><unit>" or
-- "<value1><space>ft<space><value2><space>in" for a special case (feet and inches).
-- Return true if values/units were extracted and inserted, or return nothing.
text = text:gsub(' ', ' '):gsub('%s+', ' ')
local pos = text:find(' ', 1, true)
if pos then
-- Leave checking of value to convert which can handle fractions.
local value = text:sub(1, pos - 1)
local uid = text:sub(pos + 1)
if uid:sub(1, 3) == 'ft ' and uid:sub(-3) == ' in' then
-- Special case for enwiki to allow {{حول|input=5 ft 10+1/2 in}}
insert2(uid:sub(4, -4), 'in')
insert2(value, 'ft')
else
insert2(value, make_unit(tdata.wikidata_units, parms, uid) or uid)
end
return true
end
end
local function adjustparameters(tdata, parms, index)
-- For Module:Convert, adjust parms (a table of {{حول}} parameters).
-- Return true if successful or return false, t where t is an error message table.
-- This is intended mainly for use in infoboxes where the input might be
-- <value><space><unit> or
-- <wikidata-property-id>
-- If successful, insert values and units in parms, before given index.
local text = parms.input -- should be a trimmed, non-empty string
local pid = text:match('^P%d+$')
local sep = ','
local special = specials[parms[index]]
if special then
parms.out_unit = special[1]
sep = special[2] or sep
table.remove(parms, index)
end
local function quit()
return false, pid and { 'cvt_no_output' } or { 'cvt_bad_input', text }
end
local function insert2(first, second)
table.insert(parms, index, second)
table.insert(parms, index, first)
end
if pid then
parms.input_text = '' -- output an empty string if an error occurs
local result = input_from_property(tdata, parms, pid)
if result.n == 0 then
return quit()
end
local ucode
for i, t in ipairs(result) do
-- Convert requires each input unit to be identical.
if i == 1 then
ucode = t[2]
elseif ucode ~= t[2] then
return quit()
end
end
local item = ucode
if item == parms[index] then
-- Remove specified output unit if it is the same as the Wikidata unit.
-- For example, {{حول|input=P2044|km}} with property "12 km".
table.remove(parms, index)
end
for i = result.n, 1, -1 do
insert2(result[i][1], item)
item = sep
end
return true
else
if input_from_text(tdata, parms, text, insert2) then
return true
end
end
return quit()
end
--------------------------------------------------------------------------------
--- List units and check syntax of definitions ---------------------------------
--------------------------------------------------------------------------------
local specifications = {
-- seq = sequence in which fields are displayed
base = {
title = 'SI base units',
fields = {
symbol = { seq = 2, mandatory = true },
name1 = { seq = 3, mandatory = true },
name2 = { seq = 4 },
link = { seq = 5 },
},
noteseq = 6,
header = '{| class="wikitable"\n!si !!symbol !!name1 !!name2 !!link !!note',
item = '|-\n|%s ||%s ||%s ||%s ||%s ||%s',
footer = '|}',
},
alias = {
title = 'Aliases for convert',
fields = {
ucode = { seq = 2, mandatory = true },
si = { seq = 3 },
},
noteseq = 4,
header = '{| class="wikitable"\n!alias !!ucode !!base !!note',
item = '|-\n|%s ||%s ||%s ||%s',
footer = '|}',
},
known = {
title = 'Units known to convert',
fields = {
ucode = { seq = 2, mandatory = true },
label = { seq = 3, mandatory = true },
},
noteseq = 4,
header = '{| class="wikitable"\n!qid !!ucode !!label !!note',
item = '|-\n|%s ||%s ||%s ||%s',
footer = '|}',
},
unknown = {
title = 'Units not known to convert',
fields = {
_ucode = { seq = 2, mandatory = true },
si = { seq = 3 },
name1 = { seq = 4 },
name2 = { seq = 5 },
link = { seq = 6 },
label = { seq = 7, mandatory = true },
},
noteseq = 8,
header = '{| class="wikitable"\n!qid !!_ucode !!base !!name1 !!name2 !!link !!label !!note',
item = '|-\n|%s ||%s ||%s ||%s ||%s ||%s ||%s ||%s',
footer = '|}',
},
}
local function listunits(tdata, ulookup)
-- For Module:Convert, make wikitext to list the built-in Wikidata units.
-- Return true, wikitext if successful or return false, t where t is an
-- error message table. Currently, an error return never occurs.
-- The syntax of each unit definition is checked and a note is added if
-- a problem is detected.
local function safe_cells(t)
-- This is not currently needed, but in case definitions ever use wikitext
-- like '[[kilogram|kg]]', escape the text so it works in a table cell.
local result = {}
for i, v in ipairs(t) do
if v:find('|', 1, true) then
v = v:gsub('(%[%[[^%[%]]-)|(.-%]%])', '%1\0%2') -- replace pipe in piped link with a zero byte
v = v:gsub('|', '|') -- escape '|'
v = v:gsub('%z', '|') -- restore pipe in piped link
end
result[i] = v:gsub('{', '{') -- escape '{'
end
return unpack(result)
end
local wdunits = tdata.wikidata_units
local speckeys = { 'base', 'alias', 'unknown', 'known' }
for _, sid in ipairs(speckeys) do
specifications[sid].units = Collection.new()
end
local keys = Collection.new()
for k, v in pairs(wdunits) do
keys:add(k)
end
table.sort(keys)
local note_count = 0
for _, key in ipairs(keys) do
local unit = wdunits[key]
local ktext, sid
if key:match('^Q%d+$') then
ktext = '[[d:' .. key .. '|' .. key .. ']]'
if unit.ucode then
sid = 'known'
else
sid = 'unknown'
end
elseif unit.ucode then
ktext = key
sid = 'alias'
else
ktext = key
sid = 'base'
end
local result = { ktext }
local spec = specifications[sid]
local fields = spec.fields
local note = Collection.new()
for k, v in pairs(unit) do
if fields[k] then
local seq = fields[k].seq
if result[seq] then
note:add('duplicate ' .. k) -- cannot happen since keys are unique
else
result[seq] = v
end
else
note:add('invalid ' .. k)
end
end
for k, v in pairs(fields) do
local value = result[v.seq]
if value then
if k == 'si' and not wdunits[value] then
note:add('need si ' .. value)
end
if k == 'label' then
local wdl = mw.wikibase.label(key)
if wdl ~= value then
note:add('label changed to ' .. tostring(wdl))
end
end
else
result[v.seq] = ''
if v.mandatory then
note:add('missing ' .. k)
end
end
end
local text
if note.n > 0 then
note_count = note_count + 1
text = '*' .. note:join('<br />')
end
result[spec.noteseq] = text or ''
spec.units:add(result)
end
local results = Collection.new()
if note_count > 0 then
local text = note_count .. (note_count == 1 and ' note' or ' notes')
results:add("'''Search for * to see " .. text .. "'''\n")
end
for _, sid in ipairs(speckeys) do
local spec = specifications[sid]
results:add("'''" .. spec.title .. "'''")
results:add(spec.header)
local fmt = spec.item
for _, unit in ipairs(spec.units) do
results:add(string.format(fmt, safe_cells(unit)))
end
results:add(spec.footer)
end
return true, results:join('\n')
end
return { _adjustparameters = adjustparameters, _listunits = listunits }
m52ijgnieu99atcybp1znuj0bqi0ykd
وحدة:ConvertNumeric
828
28900
118030
2022-08-10T20:59:06Z
ForzaGreen
14525
أنشأ الصفحة ب'-- Module for converting between different representations of numbers. See talk page for user documentation. -- For unit tests see: [[Module:ConvertNumeric/testcases]] -- When editing, preview with: Module_talk:ConvertNumeric/testcases -- First edit [[Module:ConvertNumeric/sandbox]] and preview with Module_talk:ConvertNumeric/sandbox/testcases local ones_position = { [0] = 'صفر', [1] = 'واحد', [2] = 'إثنان', [3] = 'ثلاثة', [4] = 'أربعة',...'
Scribunto
text/plain
-- Module for converting between different representations of numbers. See talk page for user documentation.
-- For unit tests see: [[Module:ConvertNumeric/testcases]]
-- When editing, preview with: Module_talk:ConvertNumeric/testcases
-- First edit [[Module:ConvertNumeric/sandbox]] and preview with Module_talk:ConvertNumeric/sandbox/testcases
local ones_position = {
[0] = 'صفر',
[1] = 'واحد',
[2] = 'إثنان',
[3] = 'ثلاثة',
[4] = 'أربعة',
[5] = 'خمسة',
[6] = 'ستة',
[7] = 'سبعة',
[8] = 'ثمانية',
[9] = 'تسعة',
[10] = 'عشرة',
[11] = 'إحدى عشر',
[12] = 'إثنى عشر',
[13] = 'ثلاثة عشر',
[14] = 'أربعة عشر',
[15] = 'خمسةعشر',
[16] = 'ستة عشر',
[17] = 'سبعة عشر',
[18] = 'ثمانية عشر',
[19] = 'تسعة عشر'
}
local ones_position_ord = {
[0] = 'صفري',
[1] = 'أول',
[2] = 'ثاني',
[3] = 'ثالث',
[4] = 'رابع',
[5] = 'خامس',
[6] = 'سادس',
[7] = 'سابع',
[8] = 'ثامن',
[9] = 'تاسع',
[10] = 'عاشر',
[11] = 'حادي عشر',
[12] = 'ثاني عشر',
[13] = 'ثالث عشر',
[14] = 'رابع عشر',
[15] = 'خامس عشر',
[16] = 'سادس عشر',
[17] = 'سابع عشر',
[18] = 'ثامن عشر',
[19] = 'تاسع عشر'
}
local ones_position_plural = {
[0] = 'صفرين',
[1] = 'واحد',
[2] = 'إثنان',
[3] = 'ثلاثة',
[4] = 'أربعة',
[5] = 'خمسة',
[6] = 'ستة',
[7] = 'سبعة',
[8] = 'ثمانية',
[9] = 'تسعة',
[10] = 'عشر',
[11] = 'إحدى عشر',
[12] = 'إثنى عشر',
[13] = 'ثلاثة عشر',
[14] = 'أربعة عشر',
[15] = 'خمسة عشر',
[16] = 'ستة عشر',
[17] = 'سبعة عشر',
[18] = 'ثمانية عشر',
[19] = 'تسعة عشر'
}
local tens_position = {
[2] = 'عشرون',
[3] = 'ثلاثون',
[4] = 'أربعون',
[5] = 'خمسون',
[6] = 'ستون',
[7] = 'سبعون',
[8] = 'ثمانون',
[9] = 'تسعون'
}
local tens_position_ord = {
[2] = 'عشرون',
[3] = 'ثلاثون',
[4] = 'أربعون',
[5] = 'خمسون',
[6] = 'ستون',
[7] = 'سبعون',
[8] = 'ثمانون',
[9] = 'تسعون'
}
local tens_position_plural = {
[2] = 'عشرون',
[3] = 'ثلاثون',
[4] = 'أربعون',
[5] = 'خمسون',
[6] = 'ستون',
[7] = 'سبعون',
[8] = 'ثمانون',
[9] = 'تسعون'
}
local groups = {
[1] = 'ألف',
[2] = 'مليون',
[3] = 'مليار',
[4] = 'تريليون',
[5] = 'كوادريليون',
[6] = 'كوينتليون~',
[7] = 'sextillion',
[8] = 'septillion',
[9] = 'octillion',
[10] = 'nonillion',
[11] = 'decillion',
[12] = 'undecillion',
[13] = 'duodecillion',
[14] = 'tredecillion',
[15] = 'quattuordecillion',
[16] = 'quindecillion',
[17] = 'sexdecillion',
[18] = 'septendecillion',
[19] = 'octodecillion',
[20] = 'novemdecillion',
[21] = 'vigintillion',
[22] = 'unvigintillion',
[23] = 'duovigintillion',
[24] = 'tresvigintillion',
[25] = 'quattuorvigintillion',
[26] = 'quinquavigintillion',
[27] = 'sesvigintillion',
[28] = 'septemvigintillion',
[29] = 'octovigintillion',
[30] = 'novemvigintillion',
[31] = 'trigintillion',
[32] = 'untrigintillion',
[33] = 'duotrigintillion',
[34] = 'trestrigintillion',
[35] = 'quattuortrigintillion',
[36] = 'quinquatrigintillion',
[37] = 'sestrigintillion',
[38] = 'septentrigintillion',
[39] = 'octotrigintillion',
[40] = 'noventrigintillion',
[41] = 'quadragintillion',
[51] = 'quinquagintillion',
[61] = 'sexagintillion',
[71] = 'septuagintillion',
[81] = 'octogintillion',
[91] = 'nonagintillion',
[101] = 'centillion',
[102] = 'uncentillion',
[103] = 'duocentillion',
[104] = 'trescentillion',
[111] = 'decicentillion',
[112] = 'undecicentillion',
[121] = 'viginticentillion',
[122] = 'unviginticentillion',
[131] = 'trigintacentillion',
[141] = 'quadragintacentillion',
[151] = 'quinquagintacentillion',
[161] = 'sexagintacentillion',
[171] = 'septuagintacentillion',
[181] = 'octogintacentillion',
[191] = 'nonagintacentillion',
[201] = 'ducentillion',
[301] = 'trecentillion',
[401] = 'quadringentillion',
[501] = 'quingentillion',
[601] = 'sescentillion',
[701] = 'septingentillion',
[801] = 'octingentillion',
[901] = 'nongentillion',
[1001] = 'millinillion',
}
local roman_numerals = {
I = 1,
V = 5,
X = 10,
L = 50,
C = 100,
D = 500,
M = 1000
}
-- Converts a given valid roman numeral (and some invalid roman numerals) to a number. Returns -1, errorstring on error
local function roman_to_numeral(roman)
if type(roman) ~= "string" then return -1, "roman numeral not a string" end
local rev = roman:reverse()
local raising = true
local last = 0
local result = 0
for i = 1, #rev do
local c = rev:sub(i, i)
local next = roman_numerals[c]
if next == nil then return -1, "roman numeral contains illegal character " .. c end
if next > last then
result = result + next
raising = true
elseif next < last then
result = result - next
raising = false
elseif raising then
result = result + next
else
result = result - next
end
last = next
end
return result
end
-- Converts a given integer between 0 and 100 to Arabic text (e.g. 47 -> forty-seven)
local function numeral_to_arabic_less_100(num, ordinal, plural, zero)
local terminal_ones, terminal_tens
if ordinal then
terminal_ones = ones_position_ord
terminal_tens = tens_position_ord
elseif plural then
terminal_ones = ones_position_plural
terminal_tens = tens_position_plural
else
terminal_ones = ones_position
terminal_tens = tens_position
end
if num == 0 and zero ~= nil then
return zero
elseif num < 20 then
return terminal_ones[num]
elseif num % 10 == 0 then
return terminal_tens[num / 10]
else
return terminal_ones[num % 10] .. ' و ' .. tens_position[math.floor(num / 10)]
end
end
local function standard_suffix(ordinal, plural)
if ordinal then return '' end
if plural then return '' end -- s
return ''
end
-- Converts a given integer (in string form) between 0 and 1000 to Arabic text (e.g. 47 -> forty-seven)
local function numeral_to_arabic_less_1000(num, use_and, ordinal, plural, zero)
num = tonumber(num)
if num < 100 then
return numeral_to_arabic_less_100(num, ordinal, plural, zero)
elseif num % 100 == 0 then
return ones_position[num/100] .. ' مئة' .. standard_suffix(ordinal, plural)
else
return ones_position[math.floor(num/100)] .. ' مئة ' .. (use_and and 'و ' or '') .. numeral_to_arabic_less_100(num % 100, ordinal, plural, zero)
end
end
-- Converts a number expressed as a string in scientific notation to a string in standard decimal notation
-- e.g. 1.23E5 -> 123000, 1.23E-5 = .0000123. Conversion is exact, no rounding is performed.
local function scientific_notation_to_decimal(num)
local exponent, subs = num:gsub("^%-?%d*%.?%d*%-?[Ee]([+%-]?%d+)$", "%1")
if subs == 0 then return num end -- Input not in scientific notation, just return unmodified
exponent = tonumber(exponent)
local negative = num:find("^%-")
local _, decimal_pos = num:find("%.")
-- Mantissa will consist of all decimal digits with no decimal point
local mantissa = num:gsub("^%-?(%d*)%.?(%d*)%-?[Ee][+%-]?%d+$", "%1%2")
if negative and decimal_pos then decimal_pos = decimal_pos - 1 end
if not decimal_pos then decimal_pos = #mantissa + 1 end
local prev_len = #num
-- Remove leading zeros unless decimal point is in first position
while decimal_pos > 1 and mantissa:sub(1,1) == '0' do
mantissa = mantissa:sub(2)
decimal_pos = decimal_pos - 1
end
-- Shift decimal point right for exponent > 0
while exponent > 0 do
decimal_pos = decimal_pos + 1
exponent = exponent - 1
if decimal_pos > #mantissa + 1 then mantissa = mantissa .. '0' end
-- Remove leading zeros unless decimal point is in first position
while decimal_pos > 1 and mantissa:sub(1,1) == '0' do
mantissa = mantissa:sub(2)
decimal_pos = decimal_pos - 1
end
end
-- Shift decimal point left for exponent < 0
while exponent < 0 do
if decimal_pos == 1 then
mantissa = '0' .. mantissa
else
decimal_pos = decimal_pos - 1
end
exponent = exponent + 1
end
-- Insert decimal point in correct position and return
return (negative and '-' or '') .. mantissa:sub(1, decimal_pos - 1) .. '.' .. mantissa:sub(decimal_pos)
end
-- Rounds a number to the nearest integer (NOT USED)
local function round_num(x)
if x%1 >= 0.5 then
return math.ceil(x)
else
return math.floor(x)
end
end
-- Rounds a number to the nearest two-word number (round = up, down, or "on" for round to nearest)
-- Numbers with two digits before the decimal will be rounded to an integer as specified by round.
-- Larger numbers will be rounded to a number with only one nonzero digit in front and all other digits zero.
-- Negative sign is preserved and does not count towards word limit.
local function round_for_Arabic(num, round)
-- If an integer with at most two digits, just return
if num:find("^%-?%d?%d%.?$") then return num end
local negative = num:find("^%-")
if negative then
-- We're rounding magnitude so flip it
if round == 'up' then round = 'down' elseif round == 'down' then round = 'up' end
end
-- If at most two digits before decimal, round to integer and return
local _, _, small_int, trailing_digits, round_digit = num:find("^%-?(%d?%d?)%.((%d)%d*)$")
if small_int then
local small_int_len = #small_int
if small_int == '' then small_int = '0' end
if (round == 'up' and trailing_digits:find('[1-9]')) or (round == 'on' and tonumber(round_digit) >= 5) then
small_int = tostring(tonumber(small_int) + 1)
end
return (negative and '-' or '') .. small_int
end
-- When rounding up, any number with > 1 nonzero digit will round up (e.g. 1000000.001 rounds up to 2000000)
local nonzero_digits = 0
for digit in num:gfind("[1-9]") do
nonzero_digits = nonzero_digits + 1
end
num = num:gsub("%.%d*$", "") -- Remove decimal part
-- Second digit used to determine which way to round lead digit
local _, _, lead_digit, round_digit, round_digit_2, rest = num:find("^%-?(%d)(%d)(%d)(%d*)$")
if tonumber(lead_digit .. round_digit) < 20 and (1 + #rest) % 3 == 0 then
-- In Arabic numbers < 20 are one word so put 2 digits in lead and round based on 3rd
lead_digit = lead_digit .. round_digit
round_digit = round_digit_2
else
rest = round_digit_2 .. rest
end
if (round == 'up' and nonzero_digits > 1) or (round == 'on' and tonumber(round_digit) >= 5) then
lead_digit = tostring(tonumber(lead_digit) + 1)
end
-- All digits but lead digit will turn to zero
rest = rest:gsub("%d", "0")
return (negative and '-' or '') .. lead_digit .. '0' .. rest
end
local denominators = {
[2] = { 'half', plural = 'halves' },
[3] = { 'third' },
[4] = { 'quarter', us = 'fourth' },
[5] = { 'fifth' },
[6] = { 'sixth' },
[8] = { 'eighth' },
[9] = { 'ninth' },
[10] = { 'tenth' },
[16] = { 'sixteenth' },
}
-- Return status, fraction where:
-- status is a string:
-- "finished" if there is a fraction with no whole number;
-- "ok" if fraction is empty or valid;
-- "unsupported" if bad fraction;
-- fraction is a string giving (numerator / denominator) as Arabic text, or is "".
-- Only unsigned fractions with a very limited range of values are supported,
-- except that if whole is empty, the numerator can use "-" to indicate negative.
-- whole (string or nil): nil or "" if no number before the fraction
-- numerator (string or nil): numerator, if any (default = 1 if a denominator is given)
-- denominator (string or nil): denominator, if any
-- sp_us (boolean): true if sp=us
-- negative_word (string): word to use for negative sign, if whole is empty
-- use_one (boolean): false: 2+1/2 → "two and a half"; true: "two and one-half"
local function fraction_to_Arabic(whole, numerator, denominator, sp_us, negative_word, use_one)
if numerator or denominator then
local finished = (whole == nil or whole == '')
local sign = ''
if numerator then
if finished and numerator:sub(1, 1) == '-' then
numerator = numerator:sub(2)
sign = negative_word .. ' '
end
else
numerator = '1'
end
if not numerator:match('^%d+$') or not denominator or not denominator:match('^%d+$') then
return 'unsupported', ''
end
numerator = tonumber(numerator)
denominator = tonumber(denominator)
local dendata = denominators[denominator]
if not (dendata and 1 <= numerator and numerator <= 99) then
return 'unsupported', ''
end
local numstr, denstr
local sep = '-'
if numerator == 1 then
denstr = sp_us and dendata.us or dendata[1]
if finished or use_one then
numstr = 'one'
elseif denstr:match('^[aeiou]') then
numstr = 'an'
sep = ' '
else
numstr = 'a'
sep = ' '
end
else
numstr = numeral_to_arabic_less_100(numerator)
denstr = dendata.plural
if not denstr then
denstr = (sp_us and dendata.us or dendata[1]) .. 's'
end
end
if finished then
return 'finished', sign .. numstr .. sep .. denstr
end
return 'ok', ' and ' .. numstr .. sep .. denstr
end
return 'ok', ''
end
-- Takes a decimal number and converts it to Arabic text.
-- Return nil if a fraction cannot be converted (only some numbers are supported for fractions).
-- num (string or nil): the number to convert.
-- Can be an arbitrarily large decimal, such as "-123456789123456789.345", and
-- can use scientific notation (e.g. "1.23E5").
-- May fail for very large numbers not listed in "groups" such as "1E4000".
-- num is nil if there is no whole number before a fraction.
-- numerator (string or nil): numerator of fraction (nil if no fraction)
-- denominator (string or nil): denominator of fraction (nil if no fraction)
-- capitalize (boolean): whether to capitalize the result (e.g. 'One' instead of 'one')
-- use_and (boolean): whether to use the word 'and' between tens/ones place and higher places
-- hyphenate (boolean): whether to hyphenate all words in the result, useful for use as an adjective
-- ordinal (boolean): whether to produce an ordinal (e.g. 'first' instead of 'one')
-- plural (boolean): whether to pluralize the resulting number
-- links: nil: do not add any links; 'on': link "billion" and larger to Orders of magnitude article;
-- any other text: list of numbers to link (e.g. "billion,quadrillion")
-- negative_word: word to use for negative sign (typically 'negative' or 'minus'; nil to use default)
-- round: nil or '': no rounding; 'on': round to nearest two-word number; 'up'/'down': round up/down to two-word number
-- zero: word to use for value '0' (nil to use default)
-- use_one (boolean): false: 2+1/2 → "two and a half"; true: "two and one-half"
local function _numeral_to_arabic(num, numerator, denominator, capitalize, use_and, hyphenate, ordinal, plural, links, negative_word, round, zero, use_one)
if not negative_word then
if use_and then
-- TODO Should 'minus' be used when do not have sp=us?
-- If so, need to update testcases, and need to fix "minus zero".
-- negative_word = 'minus'
negative_word = 'negative'
else
negative_word = 'negative'
end
end
local status, fraction_text = fraction_to_Arabic(num, numerator, denominator, not use_and, negative_word, use_one)
if status == 'unsupported' then
return nil
end
if status == 'finished' then
-- Input is a fraction with no whole number.
-- Hack to avoid executing stuff that depends on num being a number.
local s = fraction_text
if hyphenate then s = s:gsub("%s", "-") end
if capitalize then s = s:gsub("^%l", string.upper) end
return s
end
num = scientific_notation_to_decimal(num)
if round and round ~= '' then
if round ~= 'on' and round ~= 'up' and round ~= 'down' then
error("Invalid rounding mode")
end
num = round_for_Arabic(num, round)
end
-- Separate into negative sign, num (digits before decimal), decimal_places (digits after decimal)
local MINUS = '−' -- Unicode U+2212 MINUS SIGN (may be in values from [[Module:Convert]])
if num:sub(1, #MINUS) == MINUS then
num = '-' .. num:sub(#MINUS + 1) -- replace MINUS with '-'
elseif num:sub(1, 1) == '+' then
num = num:sub(2) -- ignore any '+'
end
local negative = num:find("^%-")
local decimal_places, subs = num:gsub("^%-?%d*%.(%d+)$", "%1")
if subs == 0 then decimal_places = nil end
num, subs = num:gsub("^%-?(%d*)%.?%d*$", "%1")
if num == '' and decimal_places then num = '0' end
if subs == 0 or num == '' then error("Invalid decimal numeral") end
-- For each group of 3 digits except the last one, print with appropriate group name (e.g. million)
local s = ''
while #num > 3 do
if s ~= '' then s = s .. ' ' end
local group_num = math.floor((#num - 1) / 3)
local group = groups[group_num]
local group_digits = #num - group_num*3
s = s .. numeral_to_arabic_less_1000(num:sub(1, group_digits), false, false, false, zero) .. ' '
if links and (((links == 'on' and group_num >= 3) or links:find(group)) and group_num <= 13) then
s = s .. '[[Orders_of_magnitude_(numbers)#10' .. group_num*3 .. '|' .. group .. ']]'
else
s = s .. group
end
num = num:sub(1 + group_digits)
num = num:gsub("^0*", "") -- Trim leading zeros
end
-- Handle final three digits of integer part
if s ~= '' and num ~= '' then
if #num <= 2 and use_and then
s = s .. ' and '
else
s = s .. ' '
end
end
if s == '' or num ~= '' then
s = s .. numeral_to_arabic_less_1000(num, use_and, ordinal, plural, zero)
elseif ordinal or plural then
-- Round numbers like "one million" take standard suffixes for ordinal/plural
s = s .. standard_suffix(ordinal, plural)
end
-- For decimal places (if any) output "point" followed by spelling out digit by digit
if decimal_places then
s = s .. ' point'
for i = 1, #decimal_places do
s = s .. ' ' .. ones_position[tonumber(decimal_places:sub(i,i))]
end
end
s = s:gsub("^%s*(.-)%s*$", "%1") -- Trim whitespace
if ordinal and plural then s = s .. 's' end -- s suffix works for all ordinals
if negative and s ~= zero then s = negative_word .. ' ' .. s end
s = s:gsub("negative zero", "zero")
s = s .. fraction_text
if hyphenate then s = s:gsub("%s", "-") end
if capitalize then s = s:gsub("^%l", string.upper) end
return s
end
local p = { -- functions that can be called from another module
roman_to_numeral = roman_to_numeral,
spell_number = _numeral_to_arabic,
}
function p.numeral_to_arabic(frame)
local args = frame.args
local num = args[1]
num = num:gsub("^%s*(.-)%s*$", "%1") -- Trim whitespace
num = num:gsub(",", "") -- Remove commas
if num ~= '' then -- a fraction may have an empty whole number
if not num:find("^%-?%d*%.?%d*%-?[Ee]?[+%-]?%d*$") then
-- Input not in a valid format, try to pass it through #expr to see
-- if that produces a number (e.g. "3 + 5" will become "8").
num = frame:preprocess('{{#expr: ' .. num .. '}}')
end
end
-- Pass args from frame to helper function
return _numeral_to_arabic(
num,
args['numerator'],
args['denominator'],
args['case'] == 'U' or args['case'] == 'u',
args['sp'] ~= 'us',
args['adj'] == 'on',
args['ord'] == 'on',
args['pl'] == 'on',
args['lk'],
args['negative'],
args['round'],
args['zero'],
args['one'] == 'one' -- experiment: using '|one=one' makes fraction 2+1/2 give "two and one-half" instead of "two and a half"
) or ''
end
---- recursive function for p.decToHex
local function decToHexDigit(dec)
local dig = {"0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F"}
local div = math.floor(dec/16)
local mod = dec-(16*div)
if div >= 1 then return decToHexDigit(div)..dig[mod+1] else return dig[mod+1] end
end -- I think this is supposed to be done with a tail call but first I want something that works at all
---- finds all the decimal numbers in the input text and hexes each of them
function p.decToHex(frame)
local args=frame.args
local parent=frame.getParent(frame)
local pargs={}
if parent then pargs=parent.args end
local text=args[1] or pargs[1] or ""
local minlength=args.minlength or pargs.minlength or 1
minlength=tonumber(minlength)
local prowl=mw.ustring.gmatch(text,"(.-)(%d+)")
local output=""
repeat
local chaff,dec=prowl()
if not(dec) then break end
local hex=decToHexDigit(dec)
while (mw.ustring.len(hex)<minlength) do hex="0"..hex end
output=output..chaff..hex
until false
local chaff=mw.ustring.match(text,"(%D+)$") or ""
return output..chaff
end
return p
syuj5yz8nbf3e5yaltrb0mr01fzbvzs
وحدة:Convert/text
828
28901
118031
2022-08-10T21:05:26Z
ForzaGreen
14525
أنشأ الصفحة ب'-- Text used by Module:Convert, for ar.wikipedia.org (English). -- This is a separate module to simplify translation for use on another wiki. -- See [[:en:Template:Convert/Transwiki guide]] if copying to another wiki. local translation_table = { numdot = '،', -- decimal mark numsep = '،', -- separator for number grouping per_word = 'لكل', -- for units like "miles per gallon" plural_suffix = '', -- disable plural unit names --[[ from_en...'
Scribunto
text/plain
-- Text used by Module:Convert, for ar.wikipedia.org (English).
-- This is a separate module to simplify translation for use on another wiki.
-- See [[:en:Template:Convert/Transwiki guide]] if copying to another wiki.
local translation_table = {
numdot = '،', -- decimal mark
numsep = '،', -- separator for number grouping
per_word = 'لكل', -- for units like "miles per gallon"
plural_suffix = '', -- disable plural unit names
--[[ from_en = {
['0'] = '٠',
['1'] = '٢',
['2'] = '۲',
['3'] = '٣',
['4'] = '٤',
['5'] = '٥',
['6'] = '٦',
['7'] = '۷',
['8'] = '۸',
['9'] = '۹',
},
to_en = {
-- Arabic Numbers
['٠'] = '0',
['١'] = '1',
['٢'] = '2',
['٣'] = '3',
['٤'] = '4',
['٥'] = '5',
['٦'] = '6',
['٧'] = '7',
['٨'] = '8',
['٩'] = '9',
},--]]
specials = { -- for special processing by makeunits
-- PLEASE DO NOT CHANGE THE FOLLOWING
-- until all the units have been fixed
-- (the text used here must be the same as that used in the unit definitions).
utype = {
-- ["unit type in local language"] = "name_used_in_this_script"
["fuel efficiency"] = "type_fuel_efficiency",
["length"] = "type_length",
["temperature"] = "type_temperature",
["volume"] = "type_volume",
},
ucode = {
exception = {
-- ["unit code in local language"] = "name_used_in_module_convert"
["ft"] = "integer_more_precision",
["in"] = "subunit_more_precision",
["lb"] = "integer_more_precision",
},
istemperature = {
-- Common temperature scales (not keVT or MK).
-- ["unit code in local language"] = 1
["C"] = true,
["F"] = true,
["K"] = true,
["R"] = true,
},
usesymbol = {
-- Use unit symbol not name if abbr not specified.
-- ["unit code in local language"] = 1
["C"] = 1,
["F"] = 1,
["K"] = 1,
["R"] = 1,
["C-change"] = 1,
["F-change"] = 1,
["K-change"] = 1,
},
alttype = {
-- Unit has an alternate type that is a valid conversion.
-- ["unit code in local language"] = "alternate type in local language"
["Nm"] = "energy",
["ftlb"] = "torque",
["ftlb-f"] = "torque",
["ftlbf"] = "torque",
["inlb"] = "torque",
["inlb-f"] = "torque",
["inlbf"] = "torque",
["inoz-f"] = "torque",
["inozf"] = "torque",
},
},
},
mtext = {
-- Text used by Module:Convert/makeunits.
titles = {
-- name_used_in_this_script = "Title of page"
conversion_data = 'Module:Convert/data/شرح/1',
},
},
}
-- Some units accept an SI prefix before the unit code, such as "kg" for kilogram.
local SIprefixes = {
-- The prefix field is what the prefix should be, if different from the prefix used.
['Y'] = { exponent = 24, name = 'يوتا', prefix = 'يو' },
['Z'] = { exponent = 21, name = 'زيتا', prefix = 'زتـ' },
['E'] = { exponent = 18, name = 'إكساء', prefix = 'يـ' },
['P'] = { exponent = 15, name = 'بيتا', prefix = 'بتـ' },
['T'] = { exponent = 12, name = 'تيرا', prefix = 'تـ' },
['G'] = { exponent = 9, name = 'جيجا', prefix = 'جـ' },
['M'] = { exponent = 6, name = 'ميجا', prefix = 'مج'},
['k'] = { exponent = 3, name = 'كيلو' , prefix = 'كـ' },
['h'] = { exponent = 2, name = 'هكتو', prefix = 'هـ' },
['da']= { exponent = 1, name = 'ديكا', prefix = 'دا'},
['d'] = { exponent = -1, name = 'ديسي', prefix = 'د' },
['c'] = { exponent = -2, name = 'سنتي', prefix = 'سـ' },
['m'] = { exponent = -3, name = 'ملي', prefix = 'مـ' },
['μ'] = { exponent = -6, name = 'ميكرو', prefix = 'مكـ' }, -- key = 'GREEK SMALL LETTER MU' (U+03BC) utf-8 CE BC
['µ'] = { exponent = -6, name = 'ميكرو', prefix = 'مكـ' }, -- key = 'MICRO SIGN' (U+00B5) utf-8 C2 B5
['u'] = { exponent = -6, name = 'ميكرو', prefix = 'مكـ' }, -- not an SI prefix, but allow for people typing this
['n'] = { exponent = -9, name = 'نانو', prefix = 'نـ' },
['p'] = { exponent =-12, name = 'بيكو', prefix = 'بـ' },
['f'] = { exponent =-15, name = 'فيمتو', prefix = 'فـ' },
['a'] = { exponent =-18, name = 'أتو', prefix = 'آ' },
['z'] = { exponent =-21, name = 'زيبتو', prefix = 'زبـ' },
['y'] = { exponent =-24, name = 'يوكتو', prefix = 'يكـ' },
}
-- Some units can be qualified with one of the following prefixes, when linked.
local customary_units = {
{ "US", link = "وحدات قياس عرفية أمريكية" },
{ "U.S.", link = "وحدات قياس عرفية " },
{ "imperial", link = "وحدات إمبراطورية" },
{ "imp", link = "وحدات إمبراطورية" },
}
-- Names when using engineering notation (a prefix of "eN" where N is a number; example "e6km").
-- key = { "name", link = "article title", exponent = numeric_key_value }
-- If lk=on and link is defined, the name of the number will appear as a link.
local eng_scales = {
["3"] = { "ألف", exponent = 3 },
["6"] = { "مليون", exponent = 6 },
["9"] = { "بليون", link = "1000000000 (عدد)", exponent = 9 },
["12"] = { "تريليون", link = "1000000000000 (عدد)", exponent = 12 },
["15"] = { "كدريليون", link = "1000000000000000 (عدد)", exponent = 15 },
}
local all_categories = {
unit = "[[Category:Convert errors]]",
option = "[[Category:Convert errors]]",
warning = '[[Category:Convert invalid options]]',
tracking = '[[Category:Convert tracking]]',
}
-- For some error messages, the following puts the wanted style around
-- each unit code marked like '...%{ft%}...'.
local unitcode_regex = '%%([{}])'
local unitcode_replace = { ['{'] = '"', ['}'] = '"' } -- no longer need the more elaborate substitute used before 2013-09-28
-- All messages that may be displayed if a problem occurs.
local all_messages = {
-- Message format string: $1=title, $2=text, $3=category, $4=anchor.
-- Each displayed message starts with "Convert:" so can easily locate by searching article.
cvt_format = '<sup class="noprint Inline-Template" style="white-space:nowrap;">[<i>[[Help:Convert messages#$4|<span title="Convert: $1">convert: $2</span>]]</i>]</sup>$3<span class="error"></span>',
cvt_format2 = '<sup class="noprint Inline-Template" style="white-space:nowrap;">[[Help:Convert messages#$4|<span title="Convert: $1">$2</span>]]</sup>$3<span class="error"></span>',
cvt_format_preview = '<strong class="error">Error in convert: $1 [[Help:Convert messages#$4|(help)]]</strong>$3',
-- Each of following messages is a table:
-- { [1] = 'title', -- mouseover title text
-- [2] = 'text', -- link text displayed in article
-- [3] = 'category key', -- key to lookup category in all_categories
-- [4] = 'anchor', -- anchor for link to relevant section on help page
-- regex = gsub_regex,
-- replace = gsub_table,
-- } Mouseover title text Link text CatKey Anchor
cvt_bad_input = { 'input "$1" must be a number and unit' , 'invalid input' , 'option', 'invalid_input' },
cvt_bad_num = { 'Value "$1" must be a number' , 'invalid number' , 'option', 'invalid_number' },
cvt_big_prec = { 'Precision "$1" is too large' , 'precision too large' , 'option', 'precision_too_large' },
cvt_invalid_num = { 'Number has overflowed' , 'number overflow' , 'option', 'number_overflow' },
cvt_no_num = { 'Needs the number to be converted' , 'needs a number' , 'option', 'needs_number' },
cvt_no_num2 = { 'Needs another number for a range' , 'needs another number', 'option', 'needs_another_number' },
cvt_bad_frac = { '"$1" needs an integer above 1' , 'invalid fraction' , 'option', 'invalid_fraction' },
cvt_bad_prec = { 'Precision "$1" must be an integer' , 'invalid precision' , 'option', 'invalid_precision' },
cvt_bad_sigfig = { '"$1" needs a positive integer' , 'invalid sigfig' , 'option', 'invalid_sigfig' },
cvt_empty_option = { 'Ignored empty option "$1"' , 'empty option' , 'option', 'empty_option' },
cvt_deprecated = { 'Option "$1" is deprecated' , '*' , 'option', 'deprecated_option', format = 'cvt_format2', nowarn = true },
cvt_no_spell = { 'Spelling is not available' , 'bug, ask for help' , 'option', 'ask_for_help' },
cvt_unknown_option = { 'Ignored invalid option "$1"' , 'invalid option' , 'option', 'invalid_option' },
cvt_wd_fail = { 'Unable to access Wikidata' , 'wikidata problem' , 'option', 'wikidata_problem' },
cvt_bad_default = { 'Unit "$1" has an invalid default' , 'bug, ask for help' , 'unit' , 'ask_for_help' },
cvt_bad_unit = { 'Unit "$1" is invalid here' , 'unit invalid here' , 'unit' , 'unit_invalid_here' },
cvt_no_default = { 'Unit "$1" has no default output unit' , 'bug, ask for help' , 'unit' , 'ask_for_help' },
cvt_no_unit = { 'Needs name of unit' , 'needs unit name' , 'unit' , 'needs_unit_name' },
cvt_unknown = { 'Unit name "$1" is not known' , 'unknown unit' , 'unit' , 'unknown_unit' },
cvt_should_be = { '$1' , 'ambiguous unit' , 'unit' , 'ambiguous_unit', regex = unitcode_regex, replace = unitcode_replace },
cvt_mismatch = { 'Cannot convert "$1" to "$2"' , 'unit mismatch' , 'unit' , 'unit_mismatch' },
cvt_bug_convert = { 'Bug: Cannot convert between specified units', 'bug, ask for help' , 'unit' , 'ask_for_help' },
cvt_lookup = { 'Unit "$1" is incorrectly defined' , 'bug, ask for help' , 'unit' , 'ask_for_help' },
}
-- Text to join input value/unit with output value/unit.
local disp_joins = {
-- [1]=before output, [2]=after output, [3]=between outputs in a combination; default "; "
-- [wantname] gives default abbr=off
["or"] = { " أو " , "" , " or ", wantname = true },
["sqbr-sp"] = { " [" , "]" },
["sqbr-nbsp"] = { " [" , "]" },
["comma"] = { ", " , "" , ", " },
["slash-sp"] = { " / " , "" , wantname = true },
["slash-nbsp"] = { " / ", "" , wantname = true },
["slash-nosp"] = { "/" , "" , wantname = true },
["b"] = { " (" , ")" },
["(or)"] = { " (" , ")", " or " },
["br"] = { "<br />" , "" , wantname = true },
["br()"] = { "<br />(" , ")", wantname = true },
}
-- Text to separate values in a range.
local range_types = {
-- Specifying a table requires either:
-- * "off" and "on" values (for "abbr=off" and "abbr=on"), or
-- * "input" and "output" values (for LHS and RHS);
-- other fields are optional.
-- When "adj=on|abbr=off" applies, spaces in range text are replaced with hyphens.
-- With "exception = true", that also occurs with "adj=on|abbr=on".
-- If "adj" is defined here, that text (unchanged) is used with "adj=on".
["+"] = " + ",
[","] = ", ",
[", and"] = "، و",
[", or"] = "، أو",
["by"] = " by ",
["-"] = "–",
["to about"] = " to about ",
["and"] = { off = " و ", on = " و ", exception = true },
["and(-)"] = { input = " و ", output = "–" },
["or"] = { off = " أو " , on = " أو " , exception = true },
["to"] = { off = " إلى " , on = " إلى " , exception = true },
["to(-)"] = { input = " to ", output = "–" },
["+/-"] = { off = " ± ", on = " ± ", adj = " ± ", is_range_change = true },
["by(x)"] = { input = " by ", output = " × ", out_range_x = true },
["x"] = { off = " by ", on = " × ", abbr_range_x = true },
["X"] = { off = " by ", on = " × " }, -- TEMPORARY and undocumented option for experiments to compare with new abbr_range_x
["xx"] = " × ",
["*"] = "×", -- use "*" to replace "x" in {{convert/2}} which is different from "x" in old {{convert}}
["/"] = " / ", -- for a table of high/low temperatures with {{convert|83|/|63|F|disp=br()|abbr=values}}
}
local range_aliases = {
-- ["alternative name for a range"] = "standard range name"
["&"] = "و",
["–"] = "-",
["–"] = "-",
["to-"] = "to(-)",
["×"] = "x",
["×"] = "x",
["±"] = "+/-",
["±"] = "+/-",
}
-- Convert accepts range text delimited with whitespace, for example, {{convert|1 to 2|ft}}.
-- In addition, the following "words" are accepted without spaces, for example, {{convert|1-2|ft}}.
-- Words must be in correct order for searching, for example, 'x' after 'xx'.
local range_words = { '-', '–', 'xx', 'x', '*' }
local ranges = {
types = range_types,
aliases = range_aliases,
words = range_words,
}
-- Valid option names.
local en_option_name = {
-- ["local text for option name"] = "en name used in this module"
["$"] = "$",
["abbr"] = "abbr",
["adj"] = "adj",
["comma"] = "comma",
["debug"] = "debug",
["disp"] = "disp",
["frac"] = "frac",
["input"] = "input",
["lang"] = "lang",
["lk"] = "lk",
["order"] = "order",
["qid"] = "qid",
["qual"] = "qual",
["qualifier"] = "qual",
["round"] = "round",
["sigfig"] = "sigfig",
["sing"] = "adj", -- "sing" is an old alias for "adj"
["sortable"] = "sortable",
["sp"] = "sp",
["spell"] = "spell",
["stylein"] = "stylein",
["styleout"] = "styleout",
["tracking"] = "tracking",
}
-- Valid option values.
-- Convention: parms.opt_xxx refers to an option that is set here
-- (not intended to be set by the template which invokes this module).
-- Example: At enwiki, "abbr" includes:
-- ["comma"] = "opt_nocomma"
-- As a result, if the template uses abbr=comma, Module:Convert sets:
-- parms["opt_nocomma"] = true
-- parms["abbr"] = nil
-- Therefore parms.abbr will be nil, or will have one of the listed values
-- that do not start with "opt_".
-- An option value of form "xxx?" is the same as "xxx" but shows the input as deprecated.
local en_option_value = {
-- $=x is handled as a special case: x should be a currency symbol that will be used instead of "$"
["abbr"] = {
-- ["local text for option value"] = "en value used in this module"
["def"] = "", -- ignored (some wrapper templates call convert with "abbr=def" to mean "default abbreviation")
["h"] = "on", -- abbr=on + use "h" for hand unit (default)
["hh"] = "opt_hand_hh", -- abbr=on + use "hh" for hand unit
["in"] = "in", -- use symbol for LHS unit
["none"] = "off", -- old name for "off"
["off"] = "off", -- use name for all units
["on"] = "on", -- use symbol for all units
["out"] = "out", -- use symbol for RHS unit (default)
["unit"] = "unit", -- abbr=on but abbreviate units only: e6km → million km (not ×10⁶ km)
["values"] = "opt_values", -- show only input and output numbers, not units
["~"] = "opt_also_symbol", -- show input unit symbol as well as name
},
["adj"] = {
["mid"] = "opt_adjectival, opt_adj_mid", -- adj=on with user-specified text after input unit (between input and output)
["off"] = "", -- ignored (off is the default)
["on"] = "opt_adjectival", -- unit name is singular and hyphenated
["pre"] = "opt_one_preunit", -- user-specified text before input unit
["ri0"] = "opt_ri=0", -- round input with precision = 0
["ri1"] = "opt_ri=1", -- round input with precision = 1
["ri2"] = "opt_ri=2", -- round input with precision = 2
["ri3"] = "opt_ri=3", -- round input with precision = 3
},
["comma"] = {
["5"] = "opt_comma5", -- only use numsep grouping if 5 or more digits
["gaps"] = "opt_gaps", -- use gaps, not numsep, to separate groups of digits
["gaps3"] = "opt_gaps, opt_gaps3", -- group only in threes rather than default of no gap before a single digit after decimal mark
["off"] = "opt_nocomma", -- no numsep in input or output numbers
},
["debug"] = {
["yes"] = "opt_sortable_debug", -- make the normally hidden sort key visible
},
["disp"] = {
["5"] = "opt_round=5?", -- round output value to nearest 5
["b"] = "b", -- join: '(...)'
["(or)"] = "(or)", -- join: '(...)' with 'or' between outputs in a combination
["br"] = "br", -- join: '<br />'
["br()"] = "br()", -- join: '<br />(...)'
["comma"] = "comma", -- join: ','
["flip"] = "opt_flip", -- reverse order of input/output
["number"] = "opt_output_number_only", -- display output value (not input, and not output symbol/name)
["or"] = "or", -- join: 'or'
["out"] = "opt_output_only",
["output number only"] = "opt_output_number_only",
["output only"] = "opt_output_only",
["preunit"] = "opt_two_preunits", -- user-specified text before input and output units
["sqbr"] = "sqbr", -- join: '[...]'
["table"] = "opt_table", -- output is suitable for a table cell with align="right"
["tablecen"] = "opt_tablecen", -- output is suitable for a table cell with align="center"
["unit"] = "opt_input_unit_only", -- display input symbol/name (not output, and not input value)
["unit or text"] = "opt_input_unit_only, opt_ignore_error", -- display input symbol/name, or given unit code if not known
["unit2"] = "opt_output_unit_only",
["x"] = "x", -- join: <first>...<second> (user-specified text)
},
-- frac=x is handled as a special case: x must be an integer (possibly in local language) = 2 or more
-- input=x is handled as a special case: x should be <value><space><unitcode> or <wikidata-property-id>
["lang"] = { -- language for output digits (both en and local digits are always accepted for input)
["en"] = "opt_lang_en", -- use en digits for numbers, regardless of local language
["local"] = "opt_lang_local", -- use local digits for numbers (default, although config can change default to en)
},
["lk"] = {
["in"] = "in", -- link LHS unit name or symbol
["off"] = "off", -- do not link: same as default except for hand unit
["on"] = "on", -- link all unit names or symbols (but not twice for the same unit)
["out"] = "out", -- link RHS unit name or symbol
},
["order"] = {
["flip"] = "opt_flip", -- reverse order of input/output
["out"] = "opt_order_out", -- do not show input; instead, use order in output combination, with the first output shown as the input
},
-- qid=x is handled as a special case: x should be a Wikidata Q item identifier.
-- qual=x is handled as a special case: x should be a Wikidata Q item identifier.
["round"] = {
["0.5"] = "opt_round=0.5", -- round output value to nearest 0.5
["5"] = "opt_round=5", -- round output value to nearest 5
["10"] = "opt_round=10", -- round output value to nearest 10 (same as but clearer than "|-1")
["25"] = "opt_round=25", -- round output value to nearest 25
["50"] = "opt_round=50", -- round output value to nearest 50
["each"] = "opt_round_each", -- using default precision in a range, round each output separately (default uses highest precision of each item in range)
},
-- sigfig=x is handled as a special case: x must be an integer (possibly in local language) = 1 or more
["sortable"] = {
["off"] = "", -- ignored (off is the default)
["on"] = "opt_sortable_on", -- output sort key for use in a sortable table, based on value from converting to a standard base unit
["debug"] = "opt_sortable_on, opt_sortable_debug", -- |sortable=debug is the same as |sortable=on|debug=yes
},
["sp"] = {
["us"] = "opt_sp_us", -- use U.S. spelling (like "meter" instead of default "metre")
},
["spell"] = { -- only English spelling is supported; not scientific notation; only some fractions
["in"] = "opt_spell_in", -- spell input value in words
["In"] = "opt_spell_in, opt_spell_upper", -- spell input value in words with first letter uppercase
["on"] = "opt_spell_in, opt_spell_out", -- spell input and output values in words
["On"] = "opt_spell_in, opt_spell_out, opt_spell_upper", -- same, with first letter of first word in result uppercase
},
-- stylein=x is handled as a special case: x can be any text
-- styleout=x is handled as a special case: x can be any text
-- tracking=x is handled as a special case: x can be any text
}
return {
SIprefixes = SIprefixes,
all_categories = all_categories,
all_messages = all_messages,
currency = { ['$'] = true, ['£'] = true, ['€'] = true, ['₱'] = true, ['₽'] = true, ['¥'] = true },
customary_units = customary_units,
disp_joins = disp_joins,
en_option_name = en_option_name,
en_option_value = en_option_value,
eng_scales = eng_scales,
ranges = ranges,
}
2mjxffqvgcpkvvrjw5gu51riz70dwev