]> www.ginac.de Git - ginac.git/commit
Implemented the Blitz++ trick to allow the initialization of lists and matrices
authorChristian Bauer <Christian.Bauer@uni-mainz.de>
Tue, 30 Sep 2003 19:58:59 +0000 (19:58 +0000)
committerChristian Bauer <Christian.Bauer@uni-mainz.de>
Tue, 30 Sep 2003 19:58:59 +0000 (19:58 +0000)
commit6d1e12e7c09d1e70d6c76b57aafb213cbcfba6eb
tree7c723e7dd9101c45f2d6f9c90336ad5fac7fc9d2
parente5e2d88f74c915d5db25964f15746085de6b9106
Implemented the Blitz++ trick to allow the initialization of lists and matrices
from comma-separated sequences of expressions, like this:

  lst l;
  l = x, 2, y, x+y;

  matrix M(3, 3);
  M = x, y, 0,
     -y, x, 0,
      0, 0, 1;

This is both faster and produces much smaller code than the old constructors
lst(ex, ex, ...) and matrix(unsigned, unsigned, lst), especially in the case
of matrices, and is now the recommended way to create these objects.
check/exam_indexed.cpp
doc/tutorial/ginac.texi
ginac/container.h
ginac/matrix.h