# Building a homomorphism from group algebra to matrix space

I would like to define an algebra homomorphism between a group algebra over the integers and a complex matrix space. More precisely I have a free group F on 4 generators and the associated group algebra G and I would like to construct a homomorphism which sends each of the generators to a certain complex matrix. Inspired by a similar question, I have tried multiple things, but nothing seems to work

I have

```
F.<A,B,C,D>=FreeGroup(4)
F.inject_variables()
R=MatrixSpace(CC,2)
A1 = matrix(CC,[[0,I],[I,0]])
B1 = matrix(CC,[[I,0],[0,-I]])
C1 = matrix(CC,[[0,1],[-1,0]])
G=GroupAlgebra(F, ZZ)
```

I would like to define the homomorphism G->R which sends A to A1, B to B1 and both C and D to C1.

Link to the related question: https://ask.sagemath.org/question/106...