Skip to main content
edited tags
Link
Michael E2
  • 244.8k
  • 18
  • 351
  • 774
added 85 characters in body
Source Link

The problem is how to determine the repetitive sequences and replace the part with consecutive sequences For example: A={{1,3,4},{2,3,5},{1,6}} Then, detect there are the repetitive case for 1 and 3 and become A={{1,4,6},{3,5,7},{2,8}}

Updates

Q1:How can I assign the repetitive sequences in lists(transpose tableform) with the rules:

-Highest level & no blocked on the top will be assigned lower number.

-High level with similar repetition will follow later.

-The one underneath the other number will be much later.

For enter image description here For example:Input

A={{2,1},{2,2},{1,2},{1},{2,1,1}};
Print[Rotate[
  Grid[Map[Rotate[#, -90 Degree] &, A, {-1}], Frame -> All], 
  90 Degree]]

enter image description here

And implement the rules to get the output:

enter image description here

Q2:How can I generate all the possible list outcomes without the rules when the lists have repetitive cases?

The problem is how to determine the repetitive sequences and replace the part with consecutive sequences For example: A={{1,3,4},{2,3,5},{1,6}} Then, detect there are the repetitive case for 1 and 3 and become A={{1,4,6},{3,5,7},{2,8}}

Updates

Q1:How can I assign the repetitive sequences in lists(transpose tableform) with the rules:

-Highest level & no blocked on the top will be assigned lower number.

-High level with similar repetition will follow later.

-The one underneath the other number will be much later.

For example:Input

A={{2,1},{2,2},{1,2},{1},{2,1,1}};
Print[Rotate[
  Grid[Map[Rotate[#, -90 Degree] &, A, {-1}], Frame -> All], 
  90 Degree]]

enter image description here

And implement the rules to get the output:

enter image description here

Q2:How can I generate all the possible list outcomes without the rules when the lists have repetitive cases?

The problem is how to determine the repetitive sequences and replace the part with consecutive sequences For example: A={{1,3,4},{2,3,5},{1,6}} Then, detect there are the repetitive case for 1 and 3 and become A={{1,4,6},{3,5,7},{2,8}}

Updates

Q1:How can I assign the repetitive sequences in lists(transpose tableform) with the rules:

-Highest level & no blocked on the top will be assigned lower number.

-High level with similar repetition will follow later.

-The one underneath the other number will be much later. enter image description here For example:Input

A={{2,1},{2,2},{1,2},{1},{2,1,1}};
Print[Rotate[
  Grid[Map[Rotate[#, -90 Degree] &, A, {-1}], Frame -> All], 
  90 Degree]]

enter image description here

And implement the rules to get the output:

enter image description here

Q2:How can I generate all the possible list outcomes without the rules when the lists have repetitive cases?

added 24 characters in body
Source Link

The problem is how to determine the repetitive sequences and replace the part with consecutive sequences For example: A={{1,3,4},{2,3,5},{1,6}} Then, detect there are the repetitive case for 1 and 3 and become A={{1,4,6},{3,5,7},{2,8}}

Updates

Q1:How can I assign the repetitive sequences in lists(transpose tableform) with the rules:

-Highest level & no blocked on the top will be assigned lower number.

-High level with similar repetition will follow later.

-The one underneath the other number will be much later.

For example:Input

A={{2,1},{2,2},{1,2},{1},{2,1,1}};
Print[Rotate[
  Grid[Map[Rotate[#, -90 Degree] &, A, {-1}], Frame -> All], 
  90 Degree]]

enter image description here

And implement the rules to get the output:

enter image description here

Q2:How can I generate all the possible list outcomes without the rules when the lists have repetitive cases?

The problem is how to determine the repetitive sequences and replace the part with consecutive sequences For example: A={{1,3,4},{2,3,5},{1,6}} Then, detect there are the repetitive case for 1 and 3 and become A={{1,4,6},{3,5,7},{2,8}}

Updates

Q1:How can I assign the repetitive sequences in lists(transpose tableform) with the rules:

-Highest level will be assigned lower number.

-High level with similar repetition will follow later.

-The one underneath the other number will be much later.

For example:Input

A={{2,1},{2,2},{1,2},{1},{2,1,1}};
Print[Rotate[
  Grid[Map[Rotate[#, -90 Degree] &, A, {-1}], Frame -> All], 
  90 Degree]]

enter image description here

And implement the rules to get the output:

enter image description here

Q2:How can I generate all the possible list outcomes without the rules when the lists have repetitive cases?

The problem is how to determine the repetitive sequences and replace the part with consecutive sequences For example: A={{1,3,4},{2,3,5},{1,6}} Then, detect there are the repetitive case for 1 and 3 and become A={{1,4,6},{3,5,7},{2,8}}

Updates

Q1:How can I assign the repetitive sequences in lists(transpose tableform) with the rules:

-Highest level & no blocked on the top will be assigned lower number.

-High level with similar repetition will follow later.

-The one underneath the other number will be much later.

For example:Input

A={{2,1},{2,2},{1,2},{1},{2,1,1}};
Print[Rotate[
  Grid[Map[Rotate[#, -90 Degree] &, A, {-1}], Frame -> All], 
  90 Degree]]

enter image description here

And implement the rules to get the output:

enter image description here

Q2:How can I generate all the possible list outcomes without the rules when the lists have repetitive cases?

added 744 characters in body
Source Link
Loading
added 744 characters in body
Source Link
Loading
Source Link
Loading