User Tools

Site Tools


tutorials:common_graph_queries

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
tutorials:common_graph_queries [2024/05/06 14:49] TimObtutorials:common_graph_queries [2025/01/10 11:42] (current) – removed gaetan
Line 1: Line 1:
-In the following a set queries is listed and the results of them applied on the graph in the image. This graph is created by the turtle query: ''A[F A][R F A] F A ;''  
  
-{{:tutorials:graph_query_example.png?400|}} 
-  
-|Query | Result | Description | 
-|**Basic** ||| 
-|A  or a:A | {a1,a2,a3,a4} | addresses all instances of module A  | 
-|a:A,a.len==1  or A(1) | all A with len==1 | unary predicates | 
-|**Node based path pattern** ||| 
-|(* A F *) A  | {a3} | direct combination of nodes | 
-|(* F *) A | {a2,a3,a4} | other example | 
-|**Edge based path pattern** ||| 
-|**ANY_EDGE** ||| 
-| %%(* A --> *) F %% | {f1,f2} | next node | 
-| %%A (*<-- F*) %% | {a2,a3,a4} | prev node | 
-| %%(* F -- *) A  %% | {a1,a2,a3,a4} | undirected |  
-|**SUCCESSOR_EDGE** ||| 
-| %%(* A > *) F %% | {f2} | next  node | 
-| %%A (* < F *) %% | {a2,a3,a4} | prev  node | 
-| %%(* F --- *) A  %% | {a1,a2,a3,a4} | undirected |  
-|**BRANCH_EDGE** ||| 
-| %%(*A +>*) F %% | {f1} | next  node | 
-| %%A (* <+ F *) %% | {} | prev  node | 
-| %%(*F -+- *) A  %% | {a1} | undirected |  
-|**Single Match, Late Match and Optional Patterns** ||| 
-| %%A (: --> F)%% | {f1} | find first pattern | 
-| %%A (& --> F)%% | {f1} | find last pattern | 
-| %%A (? +> F)%% | {Null} | changes nothing to NULL | 
-|**Transitive closures** ||| 
-| %%(* A > > *) A %% | {a3} | Path described by single edges | 
-| %%(* A +> > *) A %% | {a2} | other example | 
-| %%(* A (-->)* *) A %% | {a1,a2,a3,a4} |(0-to-n edges possible) | 
-| %%(* A (-->)+ *) A %% | {a2,a3,a4} | (1-to-n edges possible) | 
-| %%(* A (-->)? *) F %% | {f1,f2} | (0-to-1 edges possible) | 
-| %%(* A (-->){2} *)F %%  | {f2} | min 2 edges | 
-| %%(* A (-->){1,2} *) A %% | {a2,a3} | min 1 max 2 edges |  
-|**Combined** ||| 
-| %%f:F, A +> f, A < f %% | {f1} | patterns combined by comma |  
tutorials/common_graph_queries.1714999743.txt.gz · Last modified: 2024/05/06 14:49 by TimOb