Carl Love

Carl Love

28055 Reputation

25 Badges

12 years, 358 days
Himself
Wayland, Massachusetts, United States
My name was formerly Carl Devore.

MaplePrimes Activity


These are answers submitted by Carl Love

Why is 3 any different than the 11 that I showed you how to add to every term last week?

nilaiASCII +~ kekuncirahsia;

What you want can be done with a single simplify with side relations command. First you need to freeze the expressions e^epsilon and e^(-epsilon) so that every expression in the matrix is polynomial. (Note that these aren't the same as exp(epsilon) and exp(-epsilon); however, I've continued with your erroneous usage.) The expression that you have labeled (3) I call ex. Then all that you need to do is

M1:= subs(e^epsilon= freeze(e^epsilon), e^(-epsilon)= freeze(e^(-epsilon)), M):
thaw(simplify(ex, {seq(seq(T[i]*U[j]= M1[i,j], i= 1..op([1,1], M)), j= 1..op([1,2], M))}));

Since theta(t) only appears in derivatives, it is easy to reduce the order. Change diff(theta(t), t) to dtheta(t) and diff(theta(t), t, t) to diff(dtheta(t), t):

eq1:=J*diff(dtheta(t),t)+b*dtheta(t)=K*i(t):
eq2:=L*diff(i(t),t)+R*i(t)=V(t)-K*dtheta(t):
DCMotor:=[eq1,eq2];
Sys:=DiffEquation(DCMotor,[V(t)],[dtheta(t)]);

The following command will take care of the asymptotes automatically:

Student:-Precalculus:-RationalFunctionPlot((x-1)/(x-2));

alpha__0:= x-> sqrt(d/x)/2*exp((-D__s - i)*Omega*x/V__La):
alpha__90:= x-> 3*sqrt(d/32/x)*exp((-D__s - i)*Omega*x/V__s):
alpha__theta:= (x,theta)-> alpha__0(x)*cos(theta)^2 + alpha__90(x)*sin(theta)^2:

If you intend for the i to refer to the complex unit sqrt(-1), then you'll need to change it to I.

MyArray:= (n,N)-> Array((1..N)$n, ()-> [args]);

A:= MyArray(3,3);

nilaiASCII +~ nops(nilaiASCII);

Here's how I like to solve recurrences by hand with the assistance of Maple. I start with a(n) and work backwards (towards a(0) or a(1)) with a "stunted" (i.e., partially inert) recursive procedure.

a:= n-> ''a''(n-1)/n:

Note that those quotes are two pairs of single quotes, not one pair of double quotes.

eval(a(n));

eval(%);

eval(%);

At this point, I see the pattern: a(n) = a(0)/n!

 

It may be most efficient to do it from the original integer representation. I haven't checked its speed, but here's a procedure to do it that way:

nOneBits:= proc(n::nonnegint)
local q:= n, ct:= 0;
     while q <> 0 do ct:= ct+irem(q,2,'q') end do;
     ct
end proc:
     
nOneBits(255);

     8

Is this what you're looking for?

OpList:= proc(ex)
local r:= [op(ex)], op0:= op(0,ex);
     `if`(r = [ex], ex, `if`([op0]=[], r, [op0, r]))
end proc:
 
Atomize:= proc(ex)
local r, newr:= ex;
     while r <> newr do
          r:= newr;
          newr:= subsindets[flat](r, Not({list,symbol}), OpList)
     end do
end proc:

Atomize(x*y+z-7^sin(w));

See also ?ToInert and ?dismantle.

They're both good answers so far, but I find this a little bit clearer. I'll suppose that your Vector system of equations is named Sys. Then do

X:= [u,v,w,alpha,beta,gamma]:
(M,Sys):= LinearAlgebra:-GenerateMatrix(convert(Sys, list), diff~(X(t), t$2)):
(C,Sys):= LinearAlgebra:-GenerateMatrix(convert(-Sys, list), diff~(X(t), t)):
(K,F):= LinearAlgebra:-GenerateMatrix(convert(-Sys, list), X(t)):

Do you mean this?

convert("0123456789", bytes);

convert~(%, binary);

map2(nprintf, "%08d", %);

 

Try

eval[recurse](eq, [ChgtVariables]);

You can get the leading zeros with nprintf. Here's my procedure:

myproc:= proc(p::prime, {base::And(posint, Not(identical(1))):= 10})
local n,q,r;
     if irem(base,p)=0 then return 0 end if;
     for n in numtheory:-divisors(p-1) do
          q:= iquo(base^n-1, p, 'r');
          if r=0 then return (n, nprintf("%0*d", n, q)) end if
     end do
end proc:

If you don't want the leading zeros, then return (n,q).

 

So, you want to print 200,000 3D plots? You simply need to change  plot3d to (print@plot3d).

First 233 234 235 236 237 238 239 Last Page 235 of 395