登录
首页 » 算法 » 这是一个简单的演示如何评价文本的数学表达式

这是一个简单的演示如何评价文本的数学表达式

于 2022-02-20 发布 文件大小:117.37 kB
0 124
下载积分: 2 下载次数: 1

代码说明:

This a simple demo of how to evaluate mathematical expressions in text format, including provision for variables and functions. The code consists of three simple classes: 1) Calc - which does the main calculations, 2) Stack - which is used to push and pop intermediate operators and numbers and 3) Symbol Table. The symbol table is a collection of calc symbols, a type structure consisting of various elements, including the expression name, function name, and the final value of the expression The evaluation procedure is done in three steps: 1) simplify the expression by removing all the elements within () and storing them in subexpressions within the symbol table. 2) Each of these sub expressions are then converted to RPN format (Reverse polar notation) and evaluated 3) Finally, the main expression is converted to RPN and evaluated-This is a simple demo of how to evaluate mathematical expressions in text format, including provision for variables and functi

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • BCH 大数据量的编码
    这是一个bch编码的程序,以前看到的都是小数据量的用不到循环语句,而这个用到了循环语句,所以解决了数据量大的问题。在用的时候只需要把数据导入到里面就完全ok了,不信你可以试试。
    2022-05-12 13:36:28下载
    积分:1
  • 最优化问题:变尺度求最多元非线性函数的最值问题
    最优化问题:变尺度算法求最多元非线性函数的最值问题-optimization problem : Changing the scaling algorithm for the nonlinear function of the value problems
    2023-01-11 00:15:03下载
    积分:1
  • C语言最小二乘实现
    最小二乘法(又称最小平方法)是一种数学优化技术。它通过最小化误差的平方和寻找数据的
    2023-06-19 15:20:03下载
    积分:1
  • HybirdSat求解器smt
    开源的的smt求解器,用于求解约束集的可满足性,能够支持位向量的求解,速度还算不错。
    2022-02-20 09:49:11下载
    积分:1
  • Dialog自适应屏幕分辨率
    子控件自适应窗口大小的改变 对所有需要改变窗口大小的Dialog提供调用接口    * @方法功能:  子控件自适应窗口大小的改变        * @参数介绍:        -hWnd:要缩放的Dialog的窗口句柄,可在Dialog中通过GetSafeHwnd()方法获得;        -typeFlag: 缩放标志,其可能取值如下:0表示原始大小(缺省),1最大化,2按照times的值放大或缩小一定倍数后居中。        -times : Dialog的放大倍数,缺省值为1.0,只有当typeFlag值为2时才有效    * @返回值:FALSE表示传入的第一个参数hWnd=NULL,否则返回TRUE;    * @注意事项:        -1、所有子控件的大小是按照原来的Dialog同比例进行放大,以免放大后失真        -2、放大后如果窗口大小超过显示器可用区域(除去任务栏),会自动调整使得窗口最大化但是长和宽的比例扔保持不变,以免失真        -3、放大后所有的子控件的字体采用的是系统默认字体,所有字体大小是放大后的统一大小        -4、当typeFlag=2&×
    2022-03-11 14:18:59下载
    积分:1
  • 图形3D变换
        一种3D图像变换方法: 通过图像3D坐标的空间关系, 借助双线性插值运算, 对图形进行3D变换, 使其变形为投影仪所需要的预畸变图像, 然后将其投影到非平面物体上, 便能让观察者看到任意角度的投影图形, 从而实现投影3D变换。
    2022-06-13 16:47:11下载
    积分:1
  • 高斯赛德尔逆矩阵
    高斯赛德尔逆矩阵算法类-high Shisaideer inverse matrix algorithm category
    2022-03-02 18:55:12下载
    积分:1
  • jaccobi迭代和GS迭代求解线性方程组,并有著名病态对称正定矩阵Hilbert矩阵的生成程序和其不同维数下,求解结果的对比作图...
    jaccobi迭代法和GS迭代法求解线性方程组,并有著名病态对称正定矩阵Hilbert矩阵的生成程序和其不同维数下,求解结果的对比作图-jaccobi iteration and GS iterative method for solving linear equations, and a well-known pathological symmetric positive definite matrix Hilbert matrix formation process and the different dimension, the results of the solution Comparative mapping
    2022-11-30 18:35:03下载
    积分:1
  • QR方求实系数多项式方程的全部根
    QR方法求实系数多项式方程的全部根-QR method realistic polynomial equation coefficients of all-
    2022-03-11 04:15:56下载
    积分:1
  • 这是用来验证卡号世界各地LUHN
    This the Luhn algorithm used to verify card numbers throughout the world. -This is the Luhn algorithm used to verify card numbers throughout the world.
    2022-12-16 15:10:03下载
    积分:1
  • 696518资源总数
  • 106155会员总数
  • 8今日下载