summaryrefslogtreecommitdiff
path: root/src/theory/arrays/skolem_cache.h
blob: b07e87dc667aec30cb5ba79bd5f5a3e9cce5a6a2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
/*********************                                                        */
/*! \file skolem_cache.h
 ** \verbatim
 ** Top contributors (to current version):
 **   Andrew Reynolds
 ** This file is part of the CVC4 project.
 ** Copyright (c) 2009-2020 by the authors listed in the file AUTHORS
 ** in the top-level source directory) and their institutional affiliations.
 ** All rights reserved.  See the file COPYING in the top-level source
 ** directory for licensing information.\endverbatim
 **
 ** \brief Arrays skolem cache
 **/

#include "cvc4_private.h"

#ifndef CVC4__THEORY__ARRAYS__SKOLEM_CACHE_H
#define CVC4__THEORY__ARRAYS__SKOLEM_CACHE_H

#include "expr/node.h"

namespace CVC4 {
namespace theory {
namespace arrays {

/**
 * The arrays skolem cache, which provides static methods for constructing
 * skolems with witness forms.
 */
class SkolemCache
{
 public:
  SkolemCache();
  ~SkolemCache() {}

  /**
   * Get the skolem correspoding to the index that witnesses the disequality
   * deq between arrays a and b. The witness form of this skolem is:
   * (witness ((x T)) (=> (not (= a b)) (not (= (select a x) (select b x)))))
   * This skolem is unique for deq, calling this method will always return the
   * same skolem over the lifetime of deq.
   */
  static Node getExtIndexSkolem(Node deq);

 private:
  /**
   * Get the bound variable x of the witness term above for disequality deq
   * between arrays.
   */
  static Node getExtIndexVar(Node deq);
};

}  // namespace arrays
}  // namespace theory
}  // namespace CVC4

#endif
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback