jefryyhalim

15 Reputation

One Badge

6 years, 312 days

MaplePrimes Activity


These are replies submitted by jefryyhalim

@mmcdara Hi! Somehow when I ran the model you sent me back, I'm getting the same real numbers too. I used to get complex numbers as the results and it's changing every time I ran it. 

In the previous replies, It is mentioned that if I use Digits:=15 the  "inconsistent results" doesn't occur. However, when I change the parameter (hup, hlp, and hp||i on line 8, 9, 11), If hup=hlp=hp||i then it gives me real number (the erratic behaviour does not occur). However, if hup does not equal hlp or hp||i or vice versa, it gives me float(undefined).

I'm still not sure why tho, my guess is just something is not correct with the ODE I put for deq1-5. But it seems to be reasonable since I use dsolve for eq||(2..5) for Vup1(x),Vp1(x),Vp2(x),Vlp1(x). I essentially have 4 equation for 4 unknowns. But sometimes it gives me float(undefined) or complex number even though all the values and equations are real numbers.

Thanks!

@Carl Love Hi Carl,

The reason I put epsilon there is so that Maple can evaluate it. If I only put Pi/2, the Vp/tan(Pi/2) will produce an error as tan(Pi/2) is 1/0. I put epsilon so that Vp/tan(Pi/2 + epsilon)  would produce a number that really small (say to ^-12) so it's negligible.

I have a similar model to that, and it works fine and I'm getting the results I want with Digits:=10 and tan(Pi/2+epsilon). The main difference between these models is just on the additional deq6 and another unknown Vlp2(x). Please find attached the other similar model.

Thanks!

@Carl Love Hi Carl, thanks for your fast response.

The reason I commented Digits:=15 is that when I use Digits:=15, it gives me float(undefined) as the results, depending on what parameter value I put (hup, hlp, and hp||i on line 8, 9, 11). If hup=hlp=hp||i then it gives me real number (the erratic behaviour does not occur). However, if hup does not equal hlp or hp||i or vice versa, it gives me float(undefined).

Then the problems are most likely in the ODE I put, are they?

Thanks!

@Carl Love As the calculation was complex, to save you time, the problems occurs when I'm solving deq1, deq2, deq3, deq4, and deq5 at the "longitudinal behaviour" section.

Thanks again!

@Carl Love Hi Carl, I already put restart: at the beginning of my code. I pressed shift-command-enter (I'm using Mac) to run the code and I literally just pressed shift-command-enter again and I'm getting different results.

Please find attached the worksheet.

Thanks a lot!

1 2 Page 2 of 2