Carl Love

Carl Love

28025 Reputation

25 Badges

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

MaplePrimes Activity


These are answers submitted by Carl Love

I suggest that you check the units of time in your problem. Are you consistently using the same time unit? The 3600 makes me suspicious.

The equation can be easily proven to have no positive real solution. The integrand is

and the interval of integration is 0..70. For dd > 0, this function is positive and has a unique maximum at t = 17. That maximum is 870. It follows that the maximum possible value of the integral is 870*70 = 60900. This is not even close to your value of V ~ 5.7e7. But if you take out the 3600, then the equation makes sense.

I have never seen this phenomenon before, but apparently the complex option to fsolve is required in this case even though the returned answer is real. So just change the last command to

fsolve(eq, dd, complex);

and it will return almost immediately with the result

(I use Digits = 15.)

I hope that someone else can comment on this phenomenon.

The equation has two real solutions in the complex domain. One of those solutions is -1-sqrt(2). If you plug this in for x in the original equation, you get a negative under the square root sign. That's not allowed in RealDomain. If you want those solutions, don't use RealDomain.

Build each frame of the animation with display, then put those frames in sequence. Like this:

display([seq(display([A[g],B[g]]), g= 1..G)], insequence= true);

To leave a space without printing the quote marks, use back quotes ` `. This is the character under the Escape on most US keyboards. It's also called accent grave. It has ASCII value 96. These quote marks do not appear in the pretty-printed output.

A conversion to algebraic normal form is available in the Logic package; it just goes by a different name: MOD2. It is part of command Canonicalize as option form= MOD2.

Logic:-Canonicalize(&not a, form= MOD2);

Logic:-Canonicalize(a &or b, form= MOD2);

In this form, XOR is represented by +, and AND is represented by juxtaposition/multiplication.

 

A command to plot the quadratic is

plot(x^2+2, x= -2..2);

There is no need to specify a y-range. However, note that the y-axis of the plot starts at 2, not 0. If you want it to start at 0, then you need to specify the y-range:

plot(x^2+2, x= -2..2, y= 0..6);

remove(t-> degree(t,x)=1, poly);

Use plot3d instead of implicitplot. You just need to take the lhs of your equations (equivalent to getting rid of the "=0" part). Note from the plot that there are vast regions of the b-c plane where the floating-point evaluation of your functions is 0. Now reduce the view. Redo the plot3d with option view= [-200..200, -200..200, -1..1]. The piecewise-linear nature of the plots leads me to believe that the numerical evaluation of your expressions is highly suspect, and thus the results of both implicitplot and DirectSearch (or any other numerical solver) are worthless.

See command fprintf. This lets you print exactly what you want to a file.

One way is to extract the data from the plot.

sol1:= dsolve(
     [diff(u(theta),theta) = 427.2461*u(theta)+385620.123/u(theta)-25671.3871,
      u(0) = .6
     ], numeric
):
plots[odeplot](sol1, 0..0.18, color = red):
A:= op([1,1], %);

A[1..10, 1..2];

There are two ways to "clear" a variable.

1.

unassign('a');

2.

a:= 'a';

In either case the single quotes are required.

@verdin The solution for the real and for the imaginary parts could be run in separate processes. This has the potential to cut your time in half. There is no obvious way to parallelize the individual solves, so I don't think that you could get any more savings than that.

Make your two equations to be solved into a list and apply Grid:-Map to it. This will run the solves in separate processes.

How about this. The key to emphasizing the inequality aspect is using plot option filled. I overlayed two copies of the plot so that I could have both the grid and the surface without the grid being black. The transparency option also serves to highlight the "solid" nature of the object being plotted (i.e., that it is more than a surface).

Fplot:= x^2*y, x= 0..1, y= 0..1, grid= [10$2], filled:
plots:-display(
     [plot3d(Fplot, style= wireframe), plot3d(Fplot, style= patchnogrid)],
     orientation= [130,65], axes= boxed,
     view= [(0..1) $ 3], transparency= 0.2
);


The mapping < 2, 2 > -> < 1, 1, 1 > and < 1, 4 > -> < 1, 2, 0 > is just a random choice made to make an example. The point of the wiki page is that once those two choices are made, the action of the mapping on any other vector in R^2 is determined.

First 301 302 303 304 305 306 307 Last Page 303 of 395