[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Spotting "cousin marriages" in a tree

Subject: Re: Spotting "cousin marriages" in a tree
From: Phil Endecott <spam_from_xslt_list@xxxxxxxxxxxx>
Date: Thu, 29 Jul 2004 12:43:37 +0100
cousin marriage
Michael Kay wrote:
You may be hoping for too much. Graph algorithms such as looking for cycles
often have complexity of O(n^2) or worse, whatever language they are
implemented in.

Michael,


This can clearly be done in O(n log n) time using either of the aproaches I propose, i.e. checking if the thing has already been output or removing duplicates in a second phase using a key. All that is stopping me is that XSLT doesn't - as far as I know - allow for keys to be used on exsl:node-set()s, or for the already-generated partial result tree to be searched.

Come on, someone must have a clever idea! Please!

--Phil.

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.