<!doctype HTML public "-//W3C//DTD HTML 4.0 Frameset//EN">

<html>

<!--(==============================================================)-->
<!--(Document created with RoboEditor. )============================-->
<!--(==============================================================)-->

<head>

<title>pnsingletdown</title>

<!--(Meta)==========================================================-->

<meta name=generator content="RoboHELP by eHelp Corporation - www.ehelp.com">
<meta name=generator-major-version content=0.1>
<meta name=generator-minor-version content=1>
<meta name=filetype content=kadov>
<meta name=filetype-version content=1>
<meta name=page-count content=1>
<meta name=layout-height content=801>
<meta name=layout-width content=775>
<meta name=date content="11 16, 2001 1:00:45 PM">


<!--(Links)=========================================================-->

<link REL=StyleSheet HREF=default.css>



</head>

<!--(Body)==========================================================-->


<body>

<h1>pnsingletdown</h1>

<h2>Purpose</h2>

<p>Fetch the child of a parse tree node, obeying rules about going down 
 a &quot;singlet chain.&quot; That is, get child only if no branching and 
 if not going down past node with BASE flag set.</p>

<h2>Syntax</h2>

<p style="line-height: normal;
			margin-bottom: 14pt;
			margin-top: 14pt;
			x-text-tab-stops: repeat 1in;
			white-space: nowrap;
			font-family: monospace;
			font-size: 10pt;">returnedPnode = pnsingletdown(aPnode)</p>

<p style="margin-left: 40px;
			line-height: normal;
			margin-bottom: 14pt;
			margin-top: 14pt;
			x-text-tab-stops: repeat 1in;
			white-space: nowrap;
			font-family: monospace;
			font-size: 10pt;">returnedPnode - type: pnode<br>
aPnode - type: pnode</p>

<h2>Returns</h2>

<h2>Remarks</h2>

<h2>Example</h2>

<p style="line-height: normal;
			margin-bottom: 14pt;
			margin-top: 14pt;
			x-text-tab-stops: repeat 1in;
			white-space: nowrap;
			font-family: monospace;
			font-size: 10pt;"># Example shows a way to &quot;layer&quot; semantics in parse tree.<br>
@POST<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;<!--kadov_tag{{</spaces>}}-->G(&quot;last&quot;) = lasteltnode(4); <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}--># Get last noun node.<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;<!--kadov_tag{{</spaces>}}-->G(&quot;noun sem&quot;) = <span style="font-weight: bold;">pnsingletdown</span>(G(&quot;last&quot;)); # Get semantic node under _noun.<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;<!--kadov_tag{{</spaces>}}-->if (G(&quot;noun sem&quot;) <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}--># If got a semantic guy, eg &quot;_house&quot;,<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}-->&amp;&amp; (G(&quot;name&quot;) = pnname(G(&quot;noun sem&quot;)))# (and get the name of the node)<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}-->&amp;&amp; strchr(G(&quot;noun sem&quot;),&quot;_&quot;) ) <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}--># and it's nonliteral.<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}-->{<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}-->group(1,4,G(&quot;name&quot;)); <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}--># &quot;Promote&quot; the sem, eg, &quot;_house&quot;.<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}-->group(1,1,&quot;_np&quot;); <!--kadov_tag{{<spaces>}}-->&nbsp;<!--kadov_tag{{</spaces>}}--># Now layer on the np. <!--kadov_tag{{<spaces>}}-->&nbsp;<!--kadov_tag{{</spaces>}}-->Note numbering has changed.<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}-->}<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;<!--kadov_tag{{</spaces>}}-->else<br>
 <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}-->group(1,4,&quot;_np&quot;); <!--kadov_tag{{<spaces>}}-->&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<!--kadov_tag{{</spaces>}}--># No semantic guy, just build noun phrase.<br>
@RULES<br>
_xNIL &lt;- _det [s] _quan [s] _adj [s plus] _noun [s plus] @@</p>

<h2>See Also</h2>

<p style="margin-bottom: 0;"><a href="pndown.htm">pndown</a>, <a href="pnup.htm">pnup</a>, 
 <a href="pnprev.htm">pnprev</a>, <a href="pnnext.htm">pnnext</a>, <a href="Table_of_Parse_Tree_Functions.htm">Parse 
 Tree Functions</a> </p>

<p>&nbsp;</p>

<p>&nbsp;</p>

</body>

</html>
