Bill:
Not really, I do have short term memory problem but its not that bad :-)
The stitch operator works great to create a single matrix of column
vectors and the following works
     pauliX dot qb0,.qb1
I should have added that I want to actually update the values of qb0
qb1, something like
     qb0 qb1 =: pauliX dot qb0 qb1
sorry about that...
thanks
*P

bill lam wrote:
> Pascal Heus wrote:
>> All:
>> I have a few matrices/vectors operations that I'm a bit struggling with.
>> Suggestions on any of the issues below would be much appreciated (I'm
>> getting close to a semester project deadline....)
>>
>> (1) Apply a dot product to  multiple vectors
>> I have define a dot product verb and I'm trying to apply the same matrix
>> to multiple verb at once. I though J would do this automatically but it
>> doesn't seem so
>>      dot =: 4 : ' x +/ . *  y'
>>      qb0 =: ,. 1 0
>>      qb1 =: ,. 0 1
>>      pauliX   =: 2 2 $ (0 1 1 0)
>>      pauliX dot qb0  NB. Works
>>      pauliX dot qb0 qb1 NB. Syntax error
>>      pauliX dot (,. 1 0) (,. 0 1) NB. Syntax error
>
> Did you forget what you had asked and been answered not long ago?
>


-- 
Technological progress is like an axe in the hands of a pathological criminal.
- Albert Einstein
www.quotator.net

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to