mirror of
https://github.com/ArashPartow/exprtk.git
synced 2025-07-08 03:09:03 +00:00
C++ Mathematical Expression Library (ExprTk) https://www.partow.net/programming/exprtk/index.html
This commit is contained in:
committed by
Arash Partow
parent
f46bffcd69
commit
cc1b800c2b
@ -2,8 +2,8 @@
|
||||
**************************************************************
|
||||
* C++ Mathematical Expression Toolkit Library *
|
||||
* *
|
||||
* Simple Example 6 *
|
||||
* Author: Arash Partow (1999-2023) *
|
||||
* Simple Example 06 *
|
||||
* Author: Arash Partow (1999-2024) *
|
||||
* URL: https://www.partow.net/programming/exprtk/index.html *
|
||||
* *
|
||||
* Copyright notice: *
|
||||
@ -11,6 +11,7 @@
|
||||
* permitted under the guidelines and in accordance with the *
|
||||
* most current version of the MIT License. *
|
||||
* https://www.opensource.org/licenses/MIT *
|
||||
* SPDX-License-Identifier: MIT *
|
||||
* *
|
||||
**************************************************************
|
||||
*/
|
||||
@ -30,10 +31,10 @@ void vector_function()
|
||||
typedef exprtk::parser<T> parser_t;
|
||||
|
||||
const std::string expression_string =
|
||||
" for (var i := 0; i < min(x[],y[],z[]); i += 1) "
|
||||
" { "
|
||||
" z[i] := 3sin(x[i]) + 2log(y[i]); "
|
||||
" } ";
|
||||
" for (var i := 0; i < min(x[], y[], z[]); i += 1) "
|
||||
" { "
|
||||
" z[i] := 3sin(x[i]) + 2log(y[i]); "
|
||||
" } ";
|
||||
|
||||
T x[] = { T(1.1), T(2.2), T(3.3), T(4.4), T(5.5) };
|
||||
T y[] = { T(1.1), T(2.2), T(3.3), T(4.4), T(5.5) };
|
||||
|
Reference in New Issue
Block a user