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

  • Home
  • SEARCH
  • 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 8933835
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T09:38:20+00:00 2026-06-15T09:38:20+00:00

Does anyone use the GINAC? Can you tell me how to init an ex

  • 0

Does anyone use the GINAC? Can you tell me how to init an ex object with a string, or convert a string to ex?

  • 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-06-15T09:38:21+00:00Added an answer on June 15, 2026 at 9:38 am

    If you have a string that contains the correct expression syntax, you can use the constructor documented here to turn it into an ex object.

    You need to supply a second argument, which must be a list (in the sense of a lst object) of symbols. This list must contain the user-defined symbols you use in the expression. If you don’t use any user-defined symbols, use an empty list.

    Example with no user-defined symbols:

      using namespace std;
      using namespace GiNaC;
    
      ex myex("2+3",lst());      // Output will be '5'
    
      cout myex << endl;
    

    Example using two user-defined symbols:

      using namespace std;
      using namespace GiNaC;
    
      symbol x("x");
      symbol y("y");
      ex myex("x^3+y",lst(x,y));
    
      cout << myex + y << endl;     // Output will be '2*y+x^3'
    

    In the last example, you can see that the character 'y' in the input string "x^3+y" was indeed interpreted as the symbol y: myex + y is simplified to "2*y+x^3".

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

Sidebar

Related Questions

Does anyone use hashCode() anywhere? Can anyone give me an example of the exact
Does anyone know how i can use BST for config.time_zone in my rails config/environment.rb
Does anyone use true or false when setting a query string param for a
Does anyone know how i can use Sharekit to post a video to facebook?
Does anyone here use phpmailer? I downloaded the files for phpmailer 5.2.1 (the newest
Does anyone know anyway to use something similar to polygon.getKml() except for the current
Does anyone know the syntax to use to add pattern styles to the cell
Does anyone know how to use an icon instead of text for the UINavigationController
Does anyone know how to use the command line compiler ('cl' and 'link') in
Does anyone know how to use different provider for membership? Actually i want to

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.