5

question1:

(code 1 something wrong, Why? and how to overcome this to achieve the next code's effect)

Inner[RotationTransform,{Pi/4,Pi/4,Pi/4},{{0,0,1},{1,0,0},{0,0,1}},Composition]

(code2 it's ok, but seems type too much characters)

Inner[RotationTransform,{Pi/4,Pi/4,Pi/4},{xx,yy,zz},Composition]/.
                                           Thread[Rule[{xx,yy,zz},{{0,0,1},{1,0,0},{0,0,1}}]]

Any other codes or tips are welcome.

Dr. belisarius
  • 115,881
  • 13
  • 203
  • 453
HyperGroups
  • 8,619
  • 1
  • 26
  • 63

1 Answers1

8

you can just add Unevaluated to prevent Inner from seeing inside:

Inner[RotationTransform, {Pi/4, Pi/4, Pi/4}, 
 Unevaluated /@ {{0, 0, 1}, {1, 0, 0}, {0, 0, 1}}, Composition]
kptnw
  • 1,406
  • 8
  • 15