1 ;;;-*- Mode: Lisp; Package: metabang.graph -*-
5 $Id: graph-matrix.lisp,v 1.1 2005/05/01 21:40:26 gwking Exp $
7 Copyright 1992 - 2005 Experimental Knowledge Systems Lab,
8 University of Massachusetts Amherst MA, 01003-4610
9 Professor Paul Cohen, Director
15 CtF uses an adj list (vector of edges with lists) or adj matrix (vector with vectors)
17 I think I'd like a numeric class and then a object one... maybe someday
19 (in-package metabang.graph)
21 ;;; ---------------------------------------------------------------------------
23 (defclass* graph-matrix (basic-graph)
24 ((adjencency-matrix nil r))
26 :vertex-class 'graph-matrix-vertex
27 :undirected-edge-class 'graph-matrix-edge)
29 (:documentation "Stub for matrix based graph. Not implemented."))
31 ;;; ---------------------------------------------------------------------------
33 (defmethod initialize-instance :after ((object graph-matrix) &key)
34 (setf (slot-value object 'adjencency-matrix)
37 ;;; ---------------------------------------------------------------------------
39 (defmethod make-vertex-container ((graph graph-matrix) initial-size)
40 (make-container 'vector-container :initial-size initial-size
43 ;;; ---------------------------------------------------------------------------
45 (defmethod make-edge-container ((graph graph-matrix) initial-size)
46 (make-container 'vector-container :initial-size initial-size
49 ;;; ---------------------------------------------------------------------------
51 (defclass* graph-matrix-edge (basic-edge)
55 (:documentation "Stub for matrix based graph. Not implemented."))
57 ;;; ---------------------------------------------------------------------------
59 (defclass* graph-matrix-vertex (basic-vertex)
62 (:documentation "Stub for matrix based graph. Not implemented."))
64 ;;; ---------------------------------------------------------------------------