About Site Map Submit Contact Us Log in | Create an account
Create an account Log In
Average Rating
User Rating:
Visitors Rating:
My rating:

Write review
  • Last update: 5 years ago
  • Total downloads: 74
  • Operating system: Linux, Mac OS X, Win All, BSD, Solaris
  • Publisher: Yash (1 other programs)
See full specifications

scripts default iconSubfactorial (Scripts) Publisher's description

This function is limited by largest floating point number that can be

Usage :
r = subfactorial(n) calculates the subfactorial of a non -negative integer (n) using the inclusion-exclusion principle.
The subfactorial can be written as,
!n = n! sum( (-1)^k / k! ), for k = 0 to n
!n : subfactorial(n)
n! : factorial(n) = 1*2*3*...*n

Remark :
This function is limited by largest floating point number that can be
defined, as given by the realmax. Since,
subfactorial(170) < realmax < subfactorial(171)
Maximum value of input (n) cannot exceed 170.
Higher value of (n) will return NaN.

a = subfactorial(12);
returns -> a = 176214841

See Also:

System Requirements:

MATLAB 6.0 (R12)
Program Release Status: New Release
Program Install Support: Install and Uninstall

Subfactorial (Scripts) Tags:

Click on a tag to find related softwares

Is Subfactorial (Scripts) your software?

Manage your software

Most Popular

scripts default icon ASK, OOK, FSK, BPSK, QPSK, 8PSK modulation 1.1
ASK, OOK, FSK, BPSK, QPSK, 8PSK modulation contain several functions for digital modulation simulation
scripts default icon Simulink Communication Labs 1.1
Simulink Communication Labs allows you to learn communication systems in greater depth.
scripts default icon M-QAM modulation and demodulation 1.1
M-QAM modulation and demodulation is the QAM modulation and demodulation tech.
scripts default icon LZW Compression/Decompression 1.1
LZW Compression/Decompression - Updated LZW compressor and decompressor with reasonable performance
scripts default icon InSPIRE utility to plot a 2D displacement field (Scripts) 1.0
This program plots the deformation field (displace vectors) contained in vector.txt.