On 04.12.2009, at 11:27, Tiemo Kieft wrote:
> So transposing it is not enough. I need the part above the main
> diagonal to be 'transposed' and put underneath the main diagonal.
> Maybe I wasn't as clear as I hoped. Let me restate the issue.
So you want to symmetrize your matrix, right? If po
This is what it should look like:
>>| 1 | 2 | 3 |
>>
>> 1 | 0 | A | B |
>>
>> 2 | A | 0 | C |
>>
>> 3 | B | C | 0 |
>>
>
> Perhaps I'm misapprehending the issue, but why isn't the following
> sufficient:
>
> (defn transpo
On Dec 3, 4:28 am, Tiemo Kieft wrote:
> Hi,
>
> I'm trying to create a matrix, basically it's a vector of vectors. I copied
> the code from ants.clj to create the matrix, however, I have to mirror the
> matrix around it's main diagonal (see below). Currently I'm doing this by
> first creating
Matrix arithmetic is one of those cases where I feel indexing is
clearer than filter/map functions.
However, if you're representing matrices as vectors as vectors, this
will likely come with a little bit of extra overhead.
That's not a problem usually because if you plan on doing any sort of
heav
Hi,
I'm trying to create a matrix, basically it's a vector of vectors. I copied the
code from ants.clj to create the matrix, however, I have to mirror the matrix
around it's main diagonal (see below). Currently I'm doing this by first
creating the matrix like this:
(apply vector (map (fn [i]