Post Reply 
Problem solving for a variable in Prime
12-28-2014, 06:09 AM
Post: #1
Problem solving for a variable in Prime
Is is possible for Prime to solve for s in the equation attached, which is a cumulative distribution function? There is a strange message like "Unable to check if antiderivative -1...(some strange characters embedded in a equation with erf() and taylor()..) has singlular points for definite integration in [40..]. The answer returned is [[]]. Thanks in advance.

   
Find all posts by this user
Quote this message in a reply
12-28-2014, 10:42 AM
Post: #2
RE: Problem solving for a variable in Prime
Try fsolve instead. Solution is 1,5606.
Find all posts by this user
Quote this message in a reply
12-28-2014, 10:47 AM
Post: #3
RE: Problem solving for a variable in Prime
(12-28-2014 10:42 AM)akmon Wrote:  Try fsolve instead. Solution is 1,5606.

Thank you, i tried but couldn't get the correct answer (still [[]]). I am on emulator by the way.


Attached File(s) Thumbnail(s)
   
Find all posts by this user
Quote this message in a reply
12-28-2014, 10:53 AM (This post was last modified: 12-28-2014 10:54 AM by akmon.)
Post: #4
RE: Problem solving for a variable in Prime
I've complex, use i and increasing disabled in cas settings. The rest is enabled. All in rad mode.
Find all posts by this user
Quote this message in a reply
12-28-2014, 11:04 AM
Post: #5
RE: Problem solving for a variable in Prime
(12-28-2014 10:53 AM)akmon Wrote:  I've complex, use i and increasing disabled in cas settings. The rest is enabled. All in rad mode.

Thank you! It worked!
Find all posts by this user
Quote this message in a reply
12-28-2014, 07:12 PM
Post: #6
RE: Problem solving for a variable in Prime
t (the integration variable) is defined as equal to 40? That seems non-sensical to me.
Find all posts by this user
Quote this message in a reply
12-28-2014, 08:33 PM
Post: #7
RE: Problem solving for a variable in Prime
(12-28-2014 06:18 PM)compsystems Wrote:  failed to reproduce the input, please complete

solve( ∫( (1/(√(2*π)*s))*e^(-(t-u)^2/(2*s^2)),t, t,∞), t=0.1 )

Press space key between dt and =
Find all posts by this user
Quote this message in a reply
12-28-2014, 10:48 PM (This post was last modified: 12-29-2014 12:39 AM by Snorre.)
Post: #8
RE: Problem solving for a variable in Prime
Hello compsystems,

Your expression
Quote:solve( ∫( (1/(√(2*π)*s))*e^(-(t-u)^2/(2*s^2)),t, t,∞), t=0.1 )
looks odd because you're using the same name "t" for two different variables. You should rename one of them (either the red or blue), e.g. to τ (tau).

(1) t within the integrand refers to the integration variable t.
(2) t to be solved refers to the integration lower limit t.
(3) t and t are two distinct variables (each having their own context/scope/lifetime).

So you are trying to find a lower integration limit t (somewhere near 0.1) so that the integral becomes zero (the to-solve-equation is implicitly set to =0), which would only hold if both limits are equal (since your integrand has everywhere the same sign).

But your expression differs from that of factor. Look at his screenshots:
Quote:solve( ∫( (1/(√(2*π)*s))*e^(-(t-u)^2/(2*s^2))=0.1, t, t, ∞), s )
Here we have two distinct t again. Now we're searching for s so that the integral becomes 0.1. Since the lower limit t is a free variable the result depends on whatever t is set to.

Hello factor,

I do not know the original problem, but I think the lower limit should not be t but something like either 0 or -∞. (On your calc you seem to have set t to 40, which becomes the lower integration limit). Maybe you're not searching for an s but for t as compsystems suggested (if so, don't name your integration variable also t since it's not forbidden but a bit confusing).
Furthermore I doubt the Prime is able to solve that integral. You should paraphrase it in terms of "erf"/"erfc"/"NORMALD_CDF"/"NORMALD_ICDF" functions and set your lower integration limit and u to concrete values before solving numerically.
Find all posts by this user
Quote this message in a reply
12-29-2014, 01:54 PM (This post was last modified: 12-29-2014 02:02 PM by factor.)
Post: #9
RE: Problem solving for a variable in Prime
(12-28-2014 10:48 PM)Snorre Wrote:  Hello factor,

I do not know the original problem, but I think the lower limit should not be t but something like either 0 or -∞. (On your calc you seem to have set t to 40, which becomes the lower integration limit). Maybe you're not searching for an s but for t as compsystems suggested (if so, don't name your integration variable also t since it's not forbidden but a bit confusing).
Furthermore I doubt the Prime is able to solve that integral. You should paraphrase it in terms of "erf"/"erfc"/"NORMALD_CDF"/"NORMALD_ICDF" functions and set your lower integration limit and u to concrete values before solving numerically.

Thanks for the explanation. I should have explained more on the original question which is from an article I can't seem to find the link now, and the settings go like this: a math teacher was asking a question to his students in which the students are expected to find the std deviation, s, using the equation z=(t-u)/s, where t is a sample value (of something like height or what, i forgot), and u is the mean. It is also given that z = 0.1 which put the sample in the 10% top. So it is like given that A's height is 40, the mean is 38, and A is within 10% top of the height... the students are expected to do the math to find s.

However, some students unexpectedly devised other creative methods to the problem, and one being using the (other brand calculator's) CAS capability to directly solve the equation (thus from 40 to infinity).

As far as I remember, that equation as typed by that student, although seems very legitimate, didn't give any result other than an error from the (other brand calculator). It turns out some "hints" are required for that equation to work. I have that equation in my calc and wondered if the Prime will solve it faster. And it is faster, compared to the equivalent PC software of that (other brand calculator).
Find all posts by this user
Quote this message in a reply
12-29-2014, 03:34 PM (This post was last modified: 12-30-2014 07:18 AM by Snorre.)
Post: #10
RE: Problem solving for a variable in Prime
Hello factor,

OK, then your solve-expression and setting t=40 is totally valid.
Since there doesn't exist a closed form solution to that integral (I think that's the reason we have the approximate erf and CDF functions for), you should take a closer look at NORMALD_CDF (which gives the integration over the left side). But to be sure consult the on-device-help.
Your desired solution may look like: solve(1-normald_cdf(u,s,t)=0.1,s).
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)