complicated cas problem
11-21-2017, 02:56 PM
Post: #1
 webmasterpdx Senior Member Posts: 541 Joined: Sep 2015
complicated cas problem
I have 2 functions. The first is a staircase function:

f1=atan(cot(pi*x))/pi + x - 1/2

The second is basically, fermats equation...x^n + y^n = z^n
I can prove it only needs to be true in the positive domain....so I can use:
y = f2 = (z^n - x^n)^(1/n)
If n = 2, this is a circle.

So, I wanted to see where these 2 functions intersect as in:
f1(x) = f2(x)

I tried:

solve(f1(x) = f2(x),{x,y}) and I only get an empty square brackets (matrix) as a result.

Then I tried n:=2, and it tells me I have a bad argument.
I tried z:=5 and I get the same result.

How do I get the intersection of 2 functions like this algebraicly.

I know when I plot these functions with the values of z and n above, that (x,y) = (4,3) is a result....when I look at the plots....so it should be easy to solve.

???
11-21-2017, 03:09 PM
Post: #2
 parisse Senior Member Posts: 1,243 Joined: Dec 2013
RE: complicated cas problem
You should first clarify what are the unknowns, how many equations you have and whether f1 and f2 are expressions or functions, and if they are functions which arguments they take.
Hint: if you have one equation and more than one unknown, you can't solve generically.
11-21-2017, 04:07 PM
Post: #3
 webmasterpdx Senior Member Posts: 541 Joined: Sep 2015
RE: complicated cas problem
I'm using the new beta v2.
I also tried assume(z>y) assume(z>x)
11-21-2017, 04:28 PM
Post: #4
 parisse Senior Member Posts: 1,243 Joined: Dec 2013
RE: complicated cas problem
Your post does not clarify anything, it's not a question of which firmware you are running, it's a question of clarifying the maths, especially the fact I hinted: you are searching 2 unknowns and you have only one equation.
11-21-2017, 05:42 PM
Post: #5
 webmasterpdx Senior Member Posts: 541 Joined: Sep 2015
RE: complicated cas problem
Won't cas give you results in terms of the unknowns?
I do describe them as functions f1(x) and f2(x), with the unknowns x,y,z,n.

Then I tried to give n and z values, and it still didn't give me any results.

I actually have 2 equations/functions....f1(x) and f2(x)

f1(x) = y = atan(cot(pi*x))/pi + x - 1/2
f2(x) = y = (z^n - x^n)^1/n

Look at the examples for the help for solve. It does solve for 3 variables with 2 equations....
solve([x^2-y^2=0 x^2-z^2=0],[x y z]) ->
{[x x x],[x -x -x],[x x -x],[x -x x]}

So, I tried to simplify the problem a bit with:

f(x):=atan(cot(pi*x))/pi+x-1/2
g(x):=(25-x^2)^(1/2)
solve(f(x)=g(x),x)

and I get an error, as it gives me a blank matrix.

Also, I tried this:

f:=atan(cot(pi*x))/pi+x-1/2
g:=(25-x^2)^(1/2)

I thought that doing this should be the same as f(x):=, but it gave me a different result when I tried:

solve(f=g,x)

....it said that it was evaluating pi(x) instead of multiplying....and gave me an error????

Please try this out...someone familiar with CAS.
Thx
-Donald
11-21-2017, 06:19 PM
Post: #6
 webmasterpdx Senior Member Posts: 541 Joined: Sep 2015
RE: complicated cas problem
I'm going to repost this problem as I discovered that it can crash the calculator where I had to hit the reset button....
11-21-2017, 08:29 PM (This post was last modified: 11-21-2017 08:38 PM by Arno K.)
Post: #7
 Arno K Senior Member Posts: 463 Joined: Mar 2015
RE: complicated cas problem
You will have to take into account that the calc will not try to simplify first, so it has to deal with a transcendental equation, I think you should try fsolve() here, that gives you the required [4.].
Arno
Edit: This even works when I define y:="left-side" and z:="right-side", without the intervall there is a message telling you to better use an interval for bisection.
 « Next Oldest | Next Newest »

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