jschulzb

150 Reputation

9 Badges

14 years, 46 days

MaplePrimes Activity


These are questions asked by jschulzb

Hi,

I need fsolve to round down its solutions but the 'Rounding" operator doesnt work . Here's a simple example

restart;
Digits:=5:
Rounding=-infinity:
fsolve(sin(x)=0, x=2..4);

The answer is 3.1416 but I need it to return 3.1415. There also doesnt seem to be a command to obtain the nth digit of a number, aka. digit(3, 3.14) = 4 in case I wanted to write a quick procedure to round down the answer.

Any suggestions?

Thanks,

Hi,

     So I'm trying to animate a ball moving around in a moving circle. I can do a sequence of points, and a sequence of static circles which works okay but I'd like a continuous animation. Here is the points where the ball hits the circle (x,y) position and the times (t).  and the animation of the circle

restart;
with(plots);

x1 := [.9, -0.6953537244e-1, .5084436548, .5084436548, -.5253004431, -.4186356935,
     -.8180728424, -.8180728424,...

Hi, 

     I'm using fsolve in a loop, as an example can we find the first 10 roots of sin(x) and store then in an array.

 restart;

x:=array(0..10):

x[0]:=0:

for i from 1 to 10 do

x[i]:= fsolve(sin(y)=0, y=x[i-1]..10 , avoid={y=x[i-1]});

end do;
 
Firstly this solve only 0,2*Pi, 3*Pi...Why does it skip Pi? also can I change the range to x[i-1]..infinity? 

Sorry, this seems like a silly question. But is there an easy way to convert trig funcitons, or even non trig functions to orthogonal (in this case Legendre) polynomials? 

Hi,

     So I've got a numerical solution to a D.E. and want to find which parameters (v, theta) cause the second event to occur. Here's my dsolve

> soln:= dsolve({eqx, eqy, inty, intx, x(0)=0, y(0)=0}, {x(t), y(t)}, numeric, method = rkf45, output=listprocedure, parameters=[v, theta], events=[ [ [diff(y(t),t)=0, y(t)

 The first event is "Does the trajectory reach its max at a height less than 3.05m? If so, stop computation"...

4 5 6 7 Page 6 of 7