[Mathematica] Combining statements

  • Mathematica
  • Thread starter martix
  • Start date
  • #1
150
0

Main Question or Discussion Point

FromDigits /@ Permutations[Range[9], {4}]

MapThread[Power, Transpose [FactorInteger[1234]]]

MapThread[Power, Transpose [FactorInteger[#]]] &[FromDigits /@ Permutations[Range[9], {4}]]

Expression 1 and 2 work, so why not 3???

General goal:
Find the factors of all permutations of the digits 1-9 with length 4(with the factors raised to their respective powers).
 

Answers and Replies

  • #2
CompuChip
Science Advisor
Homework Helper
4,302
47
Shouldn't it be:
MapThread[Power, Transpose [FactorInteger[#]]]& @ (FromDigits /@ Permutations[Range[9], {4}])
?
 
  • #3
150
0
Indeed it should :) Thanks.
Minor mistake:
MapThread[Power, Transpose [FactorInteger[#]]]& /@ (FromDigits /@ Permutations[Range[9], {4}])
 

Related Threads on [Mathematica] Combining statements

Replies
1
Views
3K
Replies
1
Views
5K
Replies
2
Views
11K
  • Last Post
Replies
1
Views
3K
Replies
9
Views
2K
Replies
7
Views
3K
  • Last Post
Replies
1
Views
2K
Replies
5
Views
2K
  • Last Post
Replies
1
Views
993
Top