Al momento, stai seguendo questo contributo
- Vedrai gli aggiornamenti nel tuo feed del contenuto seguito
- Potresti ricevere delle email a seconda delle tue preferenze per le comunicazioni
This is similar to submission "24185-partitions" in the exchange, but with the set containing identical elements. The partitioning is a also a way of writing the input n as a sum of positive integers.
An optional argument s can be supplied to output a subset of partitions with number of parts less than or equal to s.
The number of ways of partitioning is according to the sequence
http://oeis.org/A000041
Example 1: intpartition(4) gives {[1 1 1 1],[1 1 2],[1 3],[2 2],4}
Example 2: intpartition(10,2) gives {[3,7],[4,6],[5,5],10}
Cita come
Hin Kwan Wong (2026). Integer partitions (https://it.mathworks.com/matlabcentral/fileexchange/33616-integer-partitions), MATLAB Central File Exchange. Recuperato .
Informazioni generali
- Versione 1.3.0.0 (1,74 KB)
Compatibilità della release di MATLAB
- Compatibile con qualsiasi release
Compatibilità della piattaforma
- Windows
- macOS
- Linux
| Versione | Pubblicato | Note della release | Action |
|---|---|---|---|
| 1.3.0.0 | --Added optional parameter s to specify maximum size of the partitions.
|
||
| 1.1.0.0 | corrected description |
||
| 1.0.0.0 |
