Warning: Trying to access array offset on value of type null in /home/site/wwwroot/lib/plugins/move/action/rename.php on line 42

Warning: Cannot modify header information - headers already sent by (output started at /home/site/wwwroot/lib/plugins/move/action/rename.php:42) in /home/site/wwwroot/inc/actions.php on line 38
string_equations [topas wiki]

User Tools

Site Tools


string_equations

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

string_equations [2016/10/26 16:22] – created johnsoevansstring_equations [2022/11/03 15:08] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +====== String Equations ======
 +
 +Topas v6 includes string equations.  Some examples:
 +
 +<code topas>                out_file  aac.out  ‘ This will throw an exception
 +                out_file = aac.out; ‘  This will throw an exception
 +                out_file = "aac.out";
 +                out_file = String(aac.out);
 +                out_file = If(Get(r_wp) < 10, "aac.out", "");
 +                out_file = If(Get(r_wp) < 10, Concat(String(INP_File), ".OUT"), ""); </code>
 +
 +Some new string handling features are:
 +
 +<code topas>                prm aabb = 1.234;
 +                prm sasb = 4.321;
 +                prm sa = "aa";
 +                prm sb = "bb";
 +                prm sc = sb;
 +                prm = Variable_Name_From_String(Concat(sa, sc)); :  1.23400`
 +                prm = Variable_Name_From_String(Concat(String(sa), String(sb))); :  4.32100` </code>
 +
 +String and Variable_Name_From_String are new functions.