How to make Latin look up table

1 vue (au cours des 30 derniers jours)
sadiqa ilyas
sadiqa ilyas le 1 Jan 2020
Commenté : Image Analyst le 2 Jan 2020
I want to use a look up table for example if L1 is latin table and B is another table
I want b1=(k*B(1,1))*B(1,2))*(B(1,3)).
b2=(b1*B(2,1))*B(2,2))*B(2,3))
b3=(b2*B(3,1)*B(3,2))*B(3,3))
L1=latsq(5);
L1 =
1 2 3 4 5
2 3 4 5 1
3 4 5 1 2
4 5 1 2 3
5 1 2 3 4
k=2;
B =
2 3 4
1 2 3
1 2 3
b1=(k,2),3),4)=(2,2),3),4)%now use L1i.e (2,2)=3, (3,3)=5
b1=(3,3),4)=(5,4)=3
How to perform this in matlab

Réponses (1)

Image Analyst
Image Analyst le 1 Jan 2020
Modifié(e) : Image Analyst le 1 Jan 2020
I'm not sure if there is a Latin Square generating function in MATLAB though there are some design of experiments functions in the stats toolbox.
In the past I've coded up (in Visual Basic) a Latin Square generating function, using the algorithm in Wikipedia, but I don't have MATLAB code for it.
Look at the File Exchange links on the left of this page to see user-submitted functions.
  2 commentaires
sadiqa ilyas
sadiqa ilyas le 2 Jan 2020
latin square is generated ,I want to use it as look up table.
Image Analyst
Image Analyst le 2 Jan 2020
I don't understand your syntax:
b1=(k,2),3),4)=(2,2),3),4)%now use L1i.e (2,2)=3, (3,3)=5
b1=(3,3),4)=(5,4)=3
That is meaningless to me. I have no idea how to create b1 from L1, k, and B. Please explain how L1 is to be used as a look up table for either the values or index locations of B.

Connectez-vous pour commenter.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by