<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.nars2000.org/index.php?action=history&amp;feed=atom&amp;title=System_Function_MF</id>
	<title>System Function MF - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.nars2000.org/index.php?action=history&amp;feed=atom&amp;title=System_Function_MF"/>
	<link rel="alternate" type="text/html" href="https://wiki.nars2000.org/index.php?title=System_Function_MF&amp;action=history"/>
	<updated>2026-05-08T05:32:24Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.38.7</generator>
	<entry>
		<id>https://wiki.nars2000.org/index.php?title=System_Function_MF&amp;diff=3150&amp;oldid=prev</id>
		<title>WikiSysop: Created page with &quot;=⎕MF - Monitor Function= This function is available in both &#039;&#039;monadic&#039;&#039; and &#039;&#039;dyadic&#039;&#039; forms.  =Monadic Function, Numeric Argument=  {{BoxStart|&lt;apll&gt;Z←⎕MF R&lt;/apll&gt; |Set...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.nars2000.org/index.php?title=System_Function_MF&amp;diff=3150&amp;oldid=prev"/>
		<updated>2018-04-06T04:47:15Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;=⎕MF - Monitor Function= This function is available in both &amp;#039;&amp;#039;monadic&amp;#039;&amp;#039; and &amp;#039;&amp;#039;dyadic&amp;#039;&amp;#039; forms.  =Monadic Function, Numeric Argument=  {{BoxStart|&amp;lt;apll&amp;gt;Z←⎕MF R&amp;lt;/apll&amp;gt; |Set...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;=⎕MF - Monitor Function=&lt;br /&gt;
This function is available in both &amp;#039;&amp;#039;monadic&amp;#039;&amp;#039; and &amp;#039;&amp;#039;dyadic&amp;#039;&amp;#039; forms.&lt;br /&gt;
&lt;br /&gt;
=Monadic Function, Numeric Argument=&lt;br /&gt;
&lt;br /&gt;
{{BoxStart|&amp;lt;apll&amp;gt;Z←⎕MF R&amp;lt;/apll&amp;gt;&lt;br /&gt;
|Sets or returns and sets a property of monitoring functions}}&lt;br /&gt;
{{BoxLine |&amp;lt;apll&amp;gt;R&amp;lt;/apll&amp;gt; &amp;amp;nbsp; is an integer singleton (&amp;lt;apll&amp;gt;¯2&amp;lt;/apll&amp;gt;, &amp;lt;apll&amp;gt;¯1&amp;lt;/apll&amp;gt;, &amp;lt;apll&amp;gt;1&amp;lt;/apll&amp;gt;, &amp;lt;apll&amp;gt;2&amp;lt;/apll&amp;gt;, or &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt;)}}&lt;br /&gt;
{{BoxEnd  |&amp;lt;apll&amp;gt;Z&amp;lt;/apll&amp;gt; &amp;amp;nbsp; is a numeric scalar specific to the value of &amp;lt;apll&amp;gt;R&amp;lt;/apll&amp;gt;}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;5&amp;quot; cellspacing=&amp;quot;0&amp;quot; rules=&amp;quot;all&amp;quot; summary=&amp;quot;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;apll&amp;gt;&amp;amp;nbsp;R&amp;lt;/apll&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Effect&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;apll&amp;gt;Z&amp;lt;/apll&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;apll&amp;gt;¯2&amp;lt;/apll&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;(None)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Returns the Timer Source currently in use&amp;lt;br /&amp;gt;The default value is &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt; (Performance Timer scaled to milliseconds &amp;amp;mdash; Scaled Performance)&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;apll&amp;gt;¯1&amp;lt;/apll&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;(None)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Returns the current tick frequency in milliseconds&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;apll&amp;gt;&amp;amp;nbsp;1&amp;lt;/apll&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Sets the new Timer Source to the Millisecond Timer&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Returns the old timer source (&amp;lt;apll&amp;gt;1&amp;lt;/apll&amp;gt;, &amp;lt;apll&amp;gt;2&amp;lt;/apll&amp;gt;, or &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt;)&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;apll&amp;gt;&amp;amp;nbsp;2&amp;lt;/apll&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Sets the new Timer Source to the Performance Timer&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Returns the old timer source (&amp;lt;apll&amp;gt;1&amp;lt;/apll&amp;gt;, &amp;lt;apll&amp;gt;2&amp;lt;/apll&amp;gt;, or &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt;)&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;apll&amp;gt;&amp;amp;nbsp;3&amp;lt;/apll&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Sets the new Timer Source to the Performance Timer scaled to milliseconds (Scaled Performance)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;Returns the old timer source (&amp;lt;apll&amp;gt;1&amp;lt;/apll&amp;gt;, &amp;lt;apll&amp;gt;2&amp;lt;/apll&amp;gt;, or &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt;)&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are three Timer Sources available for timing functions:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;apll&amp;gt;1&amp;lt;/apll&amp;gt;:  Millisecond Timer, in units of a millisecond (Integers)&lt;br /&gt;
* &amp;lt;apll&amp;gt;2&amp;lt;/apll&amp;gt;:  Performance Timer dependent on the computer hardware and the Operating System (raw data) (Integers)&lt;br /&gt;
* &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt;:  Performance Timer dependent on the computer hardware and the Operating System, but scaled to units of milliseconds (Scaled Performance) (Floating Point numbers)&lt;br /&gt;
&lt;br /&gt;
The expression &amp;lt;apll&amp;gt;⎕MF ¯2&amp;lt;/apll&amp;gt; returns the current Timer Source (&amp;lt;apll&amp;gt;1&amp;lt;/apll&amp;gt;, &amp;lt;apll&amp;gt;2&amp;lt;/apll&amp;gt;, or &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt;). Typically, you should use a Timer Source of &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt; as it uses the highest precision Timer Frequency and returns its result in easily understood units of milliseconds.  Under Windows, Timer Sources &amp;lt;apll&amp;gt;2&amp;lt;/apll&amp;gt; and &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt; both obtain their timing data from the function &amp;lt;b&amp;gt;QueryPerformanceCounter&amp;lt;/b&amp;gt; which has a resolution of one microsecond or better.&lt;br /&gt;
&lt;br /&gt;
The expression &amp;lt;apll&amp;gt;⎕MF ¯1&amp;lt;/apll&amp;gt; returns the number of milliseconds per unit.  For the Millisecond timer, this value is &amp;lt;apll&amp;gt;1.0&amp;lt;/apll&amp;gt;.  For the other two timers, it varies based on the computer hardware and the Operating System.  Under Windows, it uses the function &amp;lt;b&amp;gt;QueryPerformanceFrequency&amp;lt;/b&amp;gt; &amp;amp;mdash; to obtain the number of clock ticks per second, use &amp;lt;apll&amp;gt;1000÷⎕MF ¯1&amp;lt;/apll&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Monadic Function, Character Argument=&lt;br /&gt;
&lt;br /&gt;
{{BoxStart|&amp;lt;apll&amp;gt;Z←⎕MF R&amp;lt;/apll&amp;gt;&lt;br /&gt;
|returns the Monitor Data for the function named in &amp;lt;apll&amp;gt;R&amp;lt;/apll&amp;gt;}}&lt;br /&gt;
{{BoxLine |&amp;lt;apll&amp;gt;R&amp;lt;/apll&amp;gt; &amp;amp;nbsp; is a character scalar or vector}}&lt;br /&gt;
{{BoxEnd  |&amp;lt;apll&amp;gt;Z&amp;lt;/apll&amp;gt; &amp;amp;nbsp; is a 3-column numeric vector of Monitor Data, one row per function line including the function header}}&lt;br /&gt;
&lt;br /&gt;
The columns of the result as as follows:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;apll&amp;gt;[1]&amp;lt;/apll&amp;gt; time of execution on this line including subfunctions&lt;br /&gt;
* &amp;lt;apll&amp;gt;[2]&amp;lt;/apll&amp;gt; always &amp;lt;apll&amp;gt;0&amp;lt;/apll&amp;gt;&lt;br /&gt;
* &amp;lt;apll&amp;gt;[3]&amp;lt;/apll&amp;gt; count of the number of times this line was executed&lt;br /&gt;
&lt;br /&gt;
The first column of the result is a floating point number if the Timer Source is Scaled Performance (type &amp;lt;apll&amp;gt;3&amp;lt;/apll&amp;gt;), integer otherwise.&lt;br /&gt;
&lt;br /&gt;
The first row of the result applies to the function header where its first element is the sum of the Timer Values of all lines in the function.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Dyadic Function=&lt;br /&gt;
&lt;br /&gt;
{{BoxStart|&amp;lt;apll&amp;gt;L ⎕MF R&amp;lt;/apll&amp;gt;&lt;br /&gt;
| Enables or disable Function Monitoring}}&lt;br /&gt;
{{BoxLine |&amp;lt;apll&amp;gt;L&amp;lt;/apll&amp;gt; &amp;amp;nbsp; is a Boolean singleton}}&lt;br /&gt;
{{BoxLine |&amp;lt;apll&amp;gt;R&amp;lt;/apll&amp;gt; &amp;amp;nbsp; is a character scalar or vector of zero or more function names.}}&lt;br /&gt;
{{BoxEnd  |&amp;lt;apll&amp;gt;Z&amp;lt;/apll&amp;gt; &amp;amp;nbsp; is a Boolean vector one element per function named in &amp;lt;apll&amp;gt;R&amp;lt;/apll&amp;gt; indicating the success (&amp;lt;apll&amp;gt;1&amp;lt;/apll&amp;gt;) or failure (&amp;lt;apll&amp;gt;0&amp;lt;/apll&amp;gt;) of the operation.}}&lt;br /&gt;
&lt;br /&gt;
Function Monitoring is turned on (&amp;lt;apll&amp;gt;L=1&amp;lt;/apll&amp;gt;) or off (&amp;lt;apll&amp;gt;L=0&amp;lt;/apll&amp;gt;) for each of the functions named in &amp;lt;apll&amp;gt;R&amp;lt;/apll&amp;gt;.  For either value of &amp;lt;apll&amp;gt;L&amp;lt;/apll&amp;gt;, all of the internal counters for each function are set to zero.&lt;br /&gt;
&lt;br /&gt;
{{System Variables}}&lt;br /&gt;
{{Article footer}}&lt;/div&gt;</summary>
		<author><name>WikiSysop</name></author>
	</entry>
</feed>