~a-j-delaney/libamore/cunit-dev

« back to all changes in this revision

Viewing changes to src/libAMoRE/sfexp.h

  • Committer: buraq
  • Date: 2004-04-16 17:04:28 UTC
  • Revision ID: vcs-imports@canonical.com-20040416170428-ko6l3kyx1c5jyrll
initial

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*!\file  sfexp.h
 
2
 * \brief declarations for starfree expressions
 
3
 *  Copyright (c) ?    - 2000 Lehrstuhl fuer Informatik VII, RWTH Aachen
 
4
 *  Copyright (c) 2000 - 2002 Burak Emir
 
5
 *  This file is part of the libAMoRE library.
 
6
 *
 
7
 *  libAMoRE is  free software; you can redistribute it and/or
 
8
 *  modify it under the terms of the GNU Lesser General Public
 
9
 *  License as published by the Free Software Foundation; either
 
10
 *  version 2.1 of the License, or (at your option) any later version.
 
11
 *  You should have received a copy of the GNU Lesser General Public
 
12
 *  License along with the GNU C Library; if not, write to the Free
 
13
 *  Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
 
14
 *  02111-1307 USA
 
15
 */
 
16
#ifndef _SFEXP_H
 
17
#define _SFEXP_H
 
18
 
 
19
#include "global.h" /* basic types */
 
20
 
 
21
/** a starfree regular expression. 
 
22
 *  @ingroup LDO_DECL
 
23
 */
 
24
struct sexp {
 
25
    /**  indexed 0 to mno-1 */
 
26
    array ulength;
 
27
    /**  indexed 0 to mno-1 */
 
28
    array vlength;
 
29
    /**  indexed 0 to mno-1 */
 
30
    array w0length;
 
31
    /**  indexed 0 to mno-1 */
 
32
    array w1length; 
 
33
    /** length of u[x] :   2*ulength[x]   element,generator */
 
34
    arrayofarray u;
 
35
    /** length of v[x] :   2*vlength[x]   generator,element */ 
 
36
    arrayofarray v;
 
37
    /** length of w0[x] :   3*w0length[x]  generator,element,generator */
 
38
    arrayofarray w0;
 
39
    /** length of w1[x] :   1*w1length[x]     */
 
40
    arrayofarray w1;                   
 
41
    /** 0 to mno-1 */
 
42
    b_array computed;                       
 
43
} ;
 
44
 
 
45
/** pointer to a starfree regular expression 
 
46
 *  @ingroup LDO_DECL
 
47
 */
 
48
typedef struct sexp *starfexp; 
 
49
 
 
50
 
 
51
/** allocates a new starfexp
 
52
 */
 
53
starfexp newsfexp() ;
 
54
 
 
55
 
 
56
/** frees the memory used by the starfree regular expression sf.
 
57
 *  flag == TRUE iff memory for the array's has been allocated
 
58
 *  mno is the number of monoid elements
 
59
 */
 
60
void freesf(starfexp sf, boole flag, posint mno) ;
 
61
 
 
62
#endif