Template:DecodeTextFormula

From Encyclopedia of Scientonomy
Jump to navigation Jump to search

Use this template to convert a text formula that includes a <subject>, <predicate>, and <object> (in the sense of RDF) and their variations into a proper text. This is useful when formulating page titles or formulation texts for questions or answers. If no formula is given, the object will be returned.

NOTE: As any "printing" template, it doesn't store any values anywhere, but merely returns a value.

Parameters:

  • |formula= - the term.
  • |subject= - the singular form of the subject of the formulation. Must be a term (definitional topic) registered in the encyclopedia.
  • |object= - the object of the formulation. Can be a term or any other value.
  • |predicate= - the predicate of the formulation. Optional. Can be a term or any other value.
  • |link= - if not empty, links will be added to values (if the respective pages exist).


Additional Formatting

If any of the three terms is a Definitional Topic page, then additional formatting is supported for that term:

lowercase or Capitalize Each Word: To tell the software that it should be lowercase, the variable name should be all lowercase, e.g.:

  • <subject> will produce “theory”, “method”, "epistemic elements", etc.

If the first letter is capitalized, then the software will go with the Capital Each Word option, e.g.:

  • <Subject> will produce “Theory”, “Method”, "Epistemic Element" etc.


singular or plural: The usual way of using the variable will tell the software that the singular form is required, e.g.:

  • <subject> will produce “theory”, “method”, "epistemic elements", while <Subject> will produce “Theory”, “Method”, "Epistemic Element" all in singular form.

To indicate that the plural form is required, an “s” should be added at the end of the variable before the closing “>”, e.g.:

  • <subjects> will produce “theories”, while <Subjects> will produce “Theories”.


If the term is singular, it can be printed with or without an article: If an indefinite article is to be added in front of the variable, this can be achieved by adding an “a ” after the opening “<” of the variable, e.g.:

  • <a subject> will produce “an epistemic element”, “a theory”, "a method" while <a Subject> will produce “an Epistemic Element”, “a Theory”, "a Method"

Note that with <object> it should be <an object> or <an Object>.

IMPORTANT: This parameter is ignored if the plural form is requested. There is no <an objects> or <an Objects>.


If the term is not registered in the encyclopedia, then the following will apply:

  • For lowercase, a simple {{lc:string}} will be applied.
  • For plural, {{Plural|string}} is used to add an "s" to the end of the term.
  • For singulars with articles, {{AnAWord|string}} is used to add an "a "/"an " to the word.