Skip to main content
1-Visitor
November 23, 2018
Question

Basic Function Incorrect Result

  • November 23, 2018
  • 1 reply
  • 3371 views

Greetings,

I just started learning Mathcad and have been getting incorrect calculations using the sin function, when t=1s and 2s, Mathcad gives me the same result and the result is not even correct (t=1s, it should've been 3.41 not 4.33; when t=2s, it should've been 2.193), I am also getting a straight curve instead of a sin wave. Can anybody help me out? Capture.PNG

 

 

 

1 reply

12-Amethyst
November 23, 2018

Change your Range Variable, t....

You are plotting only 2 points -1 and 0.001 and it is drawing a line between the two points.  The first point is -1 sec - the second point is 0.001 seconds - that gives an interval of 1.001 seconds - therefore the thirdpoint would be 1.002 seconds which is larger than the final limit of 1sec....

You clearly wanted to plot from -1. to +1sec in 0.001 intervals....

Change the range variable to

     t:=-1 s,-0.999 s .. 1 s

that should fix it....

Hope that helps....(dont have MC installed at home so I cant fix it or show an example).

24-Ruby IV
November 23, 2018

VTsin.png

Jim351-VisitorAuthor
1-Visitor
November 23, 2018

Thank you for your reply @ValeryOchkov. I still don't know why E(t) function gives me the same result even though I specified two different variables for t=1s and t=2s. Could you shed some lights on it?