Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7678001
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T17:32:45+00:00 2026-05-31T17:32:45+00:00

I am using xmaxima to solve two simultaneous non-linear equations using the ‘solve’ command.The

  • 0

I am using xmaxima to solve two simultaneous non-linear equations using the ‘solve’ command.The answer displayed is x=[ans1, ans2,..], y=[ans1,ans2,…], But it is’int getting stored onto the variable ‘x’ and ‘y’ .
How do I assign the output to a variable so that I can use the output for further calculations.
The xmaxima code is as below:

A:0.500000000000000$
B:0.709506070053745$
C:0.242527534593605$
D:0.719012140107490$
E: 0.357164044380080$
F:-0.505315948652670$
G:0.181895650945204$
H: 0.300000000000000$

[x,y]=solve([x^2*(A*y^3+B*y-C)-D*x*y^2+E*y^3,A*x^2+(x/y^2)*(H*y+G)+F],[x,y]),numer;

output is:
[x, y] = [[x = 0.0611142802814223, y = 0.167915465898175], 
[x = - 6.026109660574413, y = 0.305609155632444], 
[x = 0.290917101108745, y = 0.445210848095313], 
[x = 0.456144541234576 %i + 1.180400965797426, 
y = 0.869595022612534 %i + 0.051360830266336], 
[x = 1.180400965797425 - 0.456144541234575 %i, 
y = 0.051360830266336 - 0.869595022612534 %i], 
[x = 0.0609759975012744 %i - 0.777728688525087, 
y = 0.792517145089706 %i - 0.51072855430292], 
[x = - 0.0609759975012744 %i - 0.777728688525087, 
y = - 0.792517145089706 %i - 0.51072855430292], 
[x = 0, y = 0]]
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T17:32:46+00:00Added an answer on May 31, 2026 at 5:32 pm

    Firstly, note that there is more than one solution, so you have to decide what you want to do with them. One option is the following:

    (%i9) solutions: solve([x^2*(A*y^3+B*y-C)-D*x*y^2+E*y^3,A*x^2+(x/y^2)*(H*y+G)+F],[x,y]), numer$
    
    <snipped some info lines from rat>
    
    (%i10) xvals: map(rhs, map(first, solutions));
    (%o10) [.06111426947129051, - 6.026109660574413, .2909171173159695, 
    .4561445354339108 %i + 1.180400961416986, 
    1.180400961416985 - .4561445354339104 %i, 
    .06097600174281474 %i - 0.77772869099467, 
    - .06097600174281463 %i - 0.77772869099467, 0]
    
    (%i11) yvals: map(rhs, map(second, solutions));
    (%o11) [.1679154401926679, .3056091599125177, .4452108480953128, 
    .8695950265919334 %i + .05136082885038127, 
    .05136082885038127 - .8695950265919334 %i, 
    0.792517152411182 %i - .5107285531053073, 
    - 0.792517152411182 %i - .5107285531053073, 0]
    

    Then you can get hold of the x,y pair for a solution via xvals[k] and yvals[k] (where you choose k between 1 and 8).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using Git Bash or MinGW Shell , if I put in a command with
Using the classic code snippet: if (x & (x-1)) == 0 If the answer
Using C#, I want to format a decimal to only display two decimal places
Using online interfaces to a version control system is a nice way to have
Using PyObjC , you can use Python to write Cocoa applications for OS X.
Using ASP.NET MVC there are situations (such as form submission) that may require a
Using C# .NET 3.5 and WCF, I'm trying to write out some of the
Using TortoiseSVN against VisualSVN I delete a source file that I should not have
Using C# and System.Data.SqlClient, is there a way to retrieve a list of parameters
Using VS2008, C#, .Net 2 and Winforms how can I make a regular Button

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.