+inline
+std::ostream& operator<< (std::ostream& os, const CTeoria& t)
+{
+#ifdef LOG
+ return os << t.nombre << "," << t.funcion << "," << t.p << "," << t.k;
+#else // ! LOG
+ return os << "CTeoria(nombre=" << t.nombre << ", funcion=" << t.funcion
+ << ", p=" << t.p << ", k=" << t.k << ")";
+#endif // LOG
+}
+
+template < >
+inline
+std::ostream& operator<< (std::ostream& os, CIndiceMagico<CTeoria*>& im)
+{
+ unsigned c = im.count();
+ if (c-- == 0) return os << "";
+ for (unsigned i = 0; i < c; ++i)
+ os << *im[i] << "\n";
+ os << *im[c];
+ return os;
+}