Carl Love

Carl Love

28115 Reputation

25 Badges

13 years, 126 days
Himself
Wayland, Massachusetts, United States
My name was formerly Carl Devore.

MaplePrimes Activity


These are replies submitted by Carl Love

Does OS X Mavericks use backslash as a directory name separator? I thought that only Windows used that. (Even Windows allows the forward slash instead.) Try replacing the double backslashes \\ with single forward slashes /.

@rit The identify command is extremely powerful and sophisticated. See ?idenitfy . But alas, it is not enough for the original problem as you posed it.

See my Answer to your previous question (just posted).

@Kitonum 

or 1/(1-exp(a*x)*erfc(a*x)).

@janhardo I am not familiar with that error message, and I have no idea what it means. Please attach the .m file so that we can have a better look at it.

@rit I don't know of any algorithm or Maple command for it. This is very close to what is done by the identify command. See test #9 at ?identify. However, that is for products, not sums. isolve returns an error. Here's a crude procedure for a brute force search over nonnegative integer exponents only. Obviously, this can be optimized:

PowerSearch:= proc(S, a, b)
     local i,j;
     if S <= 1 or a <= 1 or b <= 1 then
          error "Invalid input: All arguments must be greater than 1."
     end if;
     for i from 0 while a^i <= S do
          for j from 0 while a^i + b^j <= S do
               if S = a^i + b^j then return i,j end if
          end do
     end do;
     [][]  #No solution
end proc:

PowerSearch(191.715, 12.2, 3.5);

@Kitonum The unimodality is now proven (see above). There are at least two ways to make the fsolve work for large k. A simplistic way is to increase the value of Digits. Digits = 30 works for the k=50 case that you presented. A better way is to divide out a large positive factor, which, of course, doesn't change the zeros. It turns out that C(n,k) can be factored out of its own derivative with respect to k.

C:= (n,k,a,b)-> binomial(n,k)*a^(n-k)*b^k:
fsolve(simplify(D[2](C)(n,50,1,2)/C(n,50,1,2)), n= 50..infinity);

74.7487626691704

which agrees with your result.

@Axel Vogt Thanks. I have been thinking about this unimodality proof for a few days. To generalize, the generalized binomial coefficient function

C:= (n,k,a,b)-> binomial(n,k)*a^(n-k)*b^k

is unimodal as a function of k for 0 <= k <= n when a > 0 and b > 0. The derivative with respect to k is remarkably simple:

D[2](C)(n,k,a,b) = (Psi(n-k+1) - Psi(k+1) + ln(b/a))*C(n,k,a,b)

We can ignore the factor C(n,k,a,b) because it is strictly positive in the region of interest. We can ignore the shift by ln(a/b) because it does not depend on k. It remains prove that Psi(n-k+1) - Psi(k+1) is monotonic for 0 <= k <= n, which Axel did.

@oldstudent You can't use the plot command to plot equations. There are two options. The first is to subtract one side of the equation from the other and plot that, so that the x intercepts of the resulting plot are the roots of the equation:

plot(2*sin(2*x*Pi/180) - 1, x= 0..360);

The second is to plot separately the left side and right side of the equation, so that the x coordinates of the intersection points are the roots of the equation:

plot([2*sin(2*x*Pi/180), 1], x= 0..360);

You should get used to working in radians instead of degrees. All higher mathematics is done in radians, and nearly all mathematical software uses radians by default.

 

 

 

@janhardo It does appear that `mod` is defined in the .m file. To see it do

showstat(`mod`);

Note the backquotes, which are required since mod is a keyword.

There may be procedures inside modules in your file. The anames process won't find those. So do this also:

before:= {anames(`module`)}:
read "MyFile.m"
:
newmods:= {anames(`module`)} minus before;

Note once again the backquotes, which are required because module is a keyword.

If you do have modules in the .m file, let me know. Listing the procedures in modules is a little bit more complicated.

 

I think we need some type of general form for the final expression, such as a^i + b^j with i, j integer.

@janhardo Once procedures are stored in .m format, you cannot see them exactly as they were originally written. However, you can see something fairly close to the original using showstat. This still requires knowing the names of the procedures. So, if you know that there is a procedure named MyProc, do

showstat(MyProc);

@Markiyan Hirnyk I do use it because I have to know that the point returned by fsolve is the unique point of zero derivative.

@Markiyan Hirnyk I mean that it is unimodal when viewed as a function on the real numbers, as in this plot

plot(binomial(5,k), k= 0..5);

The more general question is How do you convert a "random variable" (as that term is used by the Statistics package) into a "stochastic process" (as that term is used by the Finance package).

First 541 542 543 544 545 546 547 Last Page 543 of 710