First time here? Check out the FAQ!

Ask Your Question
0

solving system of equations

asked 13 years ago

Hun gravatar image

I'm trying to solve a system of equations, but somehow Sage does not solve for it. I have solved similar systems of equations before using the same methods, but somehow it is not working this time around. What is causing Sage to not solve this?

var('r,B,a,y,k,d,c,N,A,theta')
h=solve([r==B*(a*(y/k)+1-d), y==c+k*(r-1+d), (1-a)*(y/N)==((1-theta)/theta)*(c/(1-N)), y==A*k^a*N^(1-a)],y,c,N,k)
show(h)
Preview: (hide)

Comments

I also have a system that Sage cranks and cranks on but never returns an answer: var('r,s,m,n,l,A,B,C,D,E,F') solve([2*m - 2*r==2*A*m*l + B*n*l + D*l, 2*n-2*s==B*m*l + 2*C*l*n + E*l, A*m + B*m*n + C*n^2 + D*m + E*n + F == 0], m, n, l) Any thoughts as to why this happens?

daviddoria gravatar imagedaviddoria ( 12 years ago )

1 Answer

Sort by » oldest newest most voted
1

answered 8 years ago

dan_fulea gravatar image

Let us rewrite the code, so that every human eye can digest the question:

var( 'r,B,a,y,k,d,c,N,A,theta' )
eq1 = r == B * ( a*y / k + 1 - d )
eq2 = y == c + k * (r-1+d)
eq3 = (1-a)*(y/N) == (1-theta) / theta * c / (1-N)
eq4 = y == A * k^a * N^(1-a)
h   = solve( [ eq1, eq2, eq3, eq4 ], [y,c,N,k] )

Now we will look closer to the eq4 and see that variable k to the power... variable a. The doc of solve refers to algebraic equations.

Docstring: Algebraically solve an equation or system of equations (over the complex numbers) for given variables. Inequalities and systems of inequalities are also supported.

Preview: (hide)
link

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 13 years ago

Seen: 2,080 times

Last updated: Jan 19 '12