#] #] ********************* #] "$d_Qndfs"'symbols flatliner derivations/symbols fix instructions.txt' - #] operators to help [track,fix] common classes of symbol errors # eg - [POIs,parenthesis] www.BillHowell.ca 24May2018 initial, very incomplete 13Aug2018 small clean-up To view this file - use a text editor (not word processor) constant width font (eg courrier 10), tab - 3 spaces # To force reload of ALL symbols-related files during debugging : lq_symbols WARNING : 30Aug2018 13:19 LMDE2 uses SIGNED bytes, RaspPi UNSIGNED!! in "str_to_unicodeList IS OP str " definition in "strings.ndf" : LMDE2 : IF (charrepList@i < 0) THEN RaspPi : IF (charrepList@i > 127) THEN >> I need to code this automatically someday ****************************** #**************************** # Table of Contents, generated with : # $ grep "^#] " "$d_Qndfs""symbols flatliner derivations/symbols fix instructions.txt" | sed 's/^#\]/ /' # ********************* "$d_Qndfs"'symbols flatliner derivations/symbols fix instructions.txt' - operators to help [track,fix] common classes of symbol errors +-----+ DICTIONARY +-----+ EDITING OF F_DERIVATION FILES References Character [lists, groups, unicode] Variables, notations, styles for Bill Lucas, Universal Force (but still general) Math symbols Reserved [words, symbols, expressions] Shorthand unicode Preferred unicode symbols Adding new symbols Warnings, bugs +-----+ START-UP LOADS +-----+ SYMBOL CLEANUP 1. Re-start QNial 2. Run symTranslate_file in "normal mode" 3. manual classification of "d_temp/symDiff bads $symSet.txt" -> move symbols into appropriate symLists 4. manual edits of "d_temp/f_derivations" AND "d_temp/classed later $symSet.txt" 5. manually edit "d_temp/classed translate $symSet.txt" : 6. MANUALLY EDIT the "correct" (2nd column) symbols 7. Post-clean "symList good [HFLN,Lucas].txt" lists of good symbols : 8. edit-run $ bash "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols sort-archive-move, post-manual-class.sh" 9. check file appends and status, and make [corrections,recoveries,panic] as needed 10. qnial> ?symbol_checks? "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols ??.sh" 11. delete d_temp files: CAREFUL!!, then back to step#1 +-----+ CODE MODIFICATIONS 1. Re-start QNial 2. Run symDebug_file to generate output of [sym_stdForm, symExtract, symTranslate] to help fix code a) Create f_derivations_stdForm - consolidate lines with line#'s, output in standard format for symbols b) Create f_derivations_converted - translated [symbols, expressions] of f_derivations_stdForm 3. Use debug output files to [modify, fix, augment, create new] code (manual procedures) a) Get an idea of how frequent is the problematic [symbol, expression] b) Locate a [symbol, expression] in f_derivations_stdForm c) ???? zzz. After that, decide on your approach to [modify, fix, augment, create new] code +-----+ OPERATORS THAT CAN BE USED SEPARATELY sym_stdForm IS OP symList - put [symbols,expressions] in standard format (remove [spaces,tabs], amalgamate lines) Generate a file listing [line-count,filename] of [syms,exprns] OR sym[Diff,List] files f_remove_extra_lineTypes IS OP pname_inn pname_out - removes lineTypes (single characters at start of line) +-----+ TESTING OF SUPPORTING PROGRAMS : [Convenient, multi-operator] test routines "strings- tests.ndf" tests : "symbols extract- tests.ndf" tests : In "symbols translate- tests.ndf" : symbols_Strings_Extract_Translate_alltest $ bash "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols sort unique Lucas.sh" +-----+ WARNING : 30Aug2018 13:19 LMDE2 uses SIGNED bytes, RaspPi UNSIGNED!! +-----+ CODING ADVICE +-----+ APPENDIX 1 - Listing of [data, operators] : # 08********08 #] +-----+ #] DICTIONARY # Definitions : see "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols fix instructions.txt" # includes [str_stdForm, [symAtom, symParn] -> symParn, symExpr, trnType, symTran, genExpr, symList, trnList, sortUp, tblAtom, tblExpr, etc] f_derivation = unicode text files of "step-by-step" derivations angle parenthesis <> denote options below #[sym,trans]Lists # file_translate - translates a given file, according to the trnType, which specifies which tbl[Parn, Expr] to use # sortUp - operator that orders a list to increasing sortKey values, alpahabetical ordering is most often used # str_extractExpr_translate # str_stdForm - standard format of a string as defind by the operator sym_stdForm # - this word "str_stdForm" is also used as an argument of operators to indicate a string of str_stdForm # symExpr_translate_stringOfType - translates symExpr that are in str_stdForm according to trnType # symExpr_translate_string - translates symExpr that are in str_stdForm switching trnType with flags # str_translate_symExpr - translate symExpr in str # symAtom - "atomic symbol" = contiguous chrs_symbols_HFLN, bounded by non-chrs_symbols_HFLN # symExpr - are a combination of [symAtom, symExpr, text] in an "open" expression - symExpr do NOT have OR[start, end] with OR[symAtom, symParen, chrs_strt_paren] # symExpr_translate - operator, translates a given symExpr, according to the trnType, which specifies the tblExpr to use # symGenl - OR sym[Atom, Parn, Expr] # symParnList - a listing of OR[symParn, symExpr] (depending on context) in any order # symExprList - a listing of symExpr in any order # symParn - composed of [, chrs_strt_paren, , chrs_stop_paren] in sequence AND symAtom - does NOT include stand-alone symExpr, ONLY as in [chrs_strt_paren, , chrs_stop_paren] - possibly including : - chrs_blank, chrs_parenthesis, chrs_symbols_HFLN, chrs_math, operators, etc, etc - symAtom, symParn, symGenr - possible nesting (deeper recursion) of [symbol,parenthetical, general] expressions # symParn_translate - operator, translates a given symParn, according to the trnType, which specifies the tblParn to use # tblParn - translation table, convert symParn_old to symParn_new columns are [symParn_old, symParn_new, symParn_cmt] in sequence (cmt = comment) - symAtom_new in standard format, str_stdForm - (1) symAtom_old are NOT in alphabetical order - it is important to list longer symbols FIRST, to avoid premature substitution # tblExpr - translation table from symExpr_old to symExpr_new, in sortUp order (was transExpr_table) columns are [symExpr_old, symExpr_new, symExpr_cmt] in sequence (cmt = comment) - symExpr_new in standard format, str_stdForm - (1) symExpr_old are NOT in alphabetical order - it is important to list longer symbols FIRST, to avoid premature substitution # trnList - a listing of translations of a symList, usually in the same order as the symList # trnType - (was symTrans_lineType) # Notes : # (1) Even though sym[Atom, Expr] are listed in trn by alphabetical order for efficient searches, replacements # cannot be in alpabetical order, as that could premature substitution of shorter symbols and corrupted text. # Furthermore, although Linux bash sort initially sorts the tables, Q'Nial must do the final sort, as Q'Nial is used # to do the translations, and its sort order is different from Linux bash sort. In other words, # missing or bad substitutions will resul with Linux bash sort. # situation. Soon I will # Old New # symTranslate trn[Parn, Expr] eg symExpt_translate_string, str_translate_symExprOfType # symTrans symParn_translate # symTrans_lineType trnType # symTranslate_file file_translate # symExpr_sub symExpt_translate # symExpr_translate_string # symTrans_string str_translate_symExpr # symDebug_file file_translate_debig # xprs_ExtractTranslate str_extractExpr_translate # "qnial> " is the terminal prompt that I use for Q'Nial. # 08********08 #] +-----+ #] EDITING OF F_DERIVATION FILES #] References #] Character [lists, groups, unicode] /media/bill/PROJECTS/Qnial/MY_NDFS/strings.ndf unicode character representation list of unicode and ASCII characters, groups of characters #] Variables, notations, styles for Bill Lucas, Universal Force (but still general) /media/bill/PROJECTS/Lucas - Universal Force/Howell - Variables, notations, styles for Bill Lucas, Universal Force.odt This document describes : Mathematical notations Variable symbols and notations "Howell's Flat-Line Notation" notations for equations Reference frames (observer, objects, ether) Points of Interest (POI)s References to equations in derivations 03Sep2018 add shorthand unicode to this file! also - see below #] Math symbols /media/bill/PROJECTS/Lucas - Universal Force/5_Math symbols.odt Unicode characters - handy symbols and codes Greek Letters vector, calculus, sets, etc Table of set theory symbols Logic math symbols table #] Reserved [words, symbols, expressions] # symTrans_lineType : special characters at beginning of lines : # NOTE : these symbols are "persistent" until changed by a different symTrans_lineType (applies to next use of operators!!) '/*' comment only - no translation or extraction of symbols '/$' applies 'tranList Lucas.txt' to a string '/%' applies 'tranList HFLN.txt' to a string '/^' reverts to previous symTrans_lineType -> useful as a general closure to comments so as not to make simple mistakes symTrans_lineType is PERSISTENT for multiple lines, until a symTrans_lineType appears as the first character on a subsequent line. These symbols (characters) are used to decide when to catenate lines. Presumably this will cause problems when used for other putposes. `= `< `> The following special characters are stylistic, and don't affect sym{Extract, Translate] `. period delimits keywords `, a comma is used to separate items in a list (list QNial atlas) Unfortunately, this is not as aesthetic as spaces, and may at times cause problems #] Shorthand unicode As unicode characters are a pain to type, the following "shorthand" codes are nornmally used when typing : short becomes comments bbb β lower case beta OOO θ lower case theta PII π lower case pi PPP φ lower case phi WATCH-OUT!! - in case you use these shorthand in your derivations #] Preferred unicode symbols It is easiest to manually cut and paste in the source document to be translated # raw unpreferred # `· `• dot product # ` `∫ integral sign # ` `´ forward prime for RFp #] Adding new symbols It might be easier to add new symbols to the [trans,sym]Lists - new symLists help reduce the forgetting to add symbols, and this can be done in one shot, rather than incrementally - handy especially when (cart [developing,revamping] [nomenclature,symbols,expressions]) #] Warnings, bugs # 02Aug2018 WARNING sym_stdForm_file: Start each input file pname_inn with a non-empty line, one that does NOT [start with,contain] one of '=<>#$%' # Problems seem to occur then '' appears in stdForm for first line? # For some unknown reason, first line with '=<>#$%' leads to "mashed unicode" output... # 08********08 #] +-----+ #] START-UP LOADS # ALL symbols-related files are reloaded by qnial -> lq_symbols, which calls "symbols system loaddefs.ndf" # To force reload of ALL symbols-related files during debugging : lq_symTests The list of files includes : lq_symBase IS { loaddefs link d_Qnial_mine 'symbols system loaddefs.ndf' ; loaddefs link d_Qnial_mine 'strings.ndf' ; loaddefs link d_Qnial_mine 'symbols extract.ndf' ; loaddefs link d_Qnial_mine 'symbols translate.ndf' ; loaddefs link d_Qnial_mine 'symbols fix.ndf' ; } lq_symTests IS { lq_symBase ; loaddefs link d_Qnial_tests 'strings- tests.ndf' ; loaddefs link d_Qnial_tests 'symbols extract- tests.ndf' ; loaddefs link d_Qnial_tests 'symbols translate- tests.ndf' ; loaddefs link d_Qnial_tests 'symbols fix- tests.ndf' ; } # 08********08 #] +-----+ #] SYMBOL CLEANUP For EACH of : $symSet=[HFLN,Lucas] Start by defining : qnial> f_derivations := link d_Lucas 'Howell - Background math for Lucas Universal Force, Chapter 4.txt' OR : qnial> f_derivations := link d_Lucas 'Howell - math of Lucas Universal Force.txt' #] 1. Re-start QNial qnial> BYE -> then launch qnial, qnial> lq_symBase -> to re-load Lucas symbols system #] 2. Run symTranslate_file in "normal mode" qnial> symTranslate_file o f_derivations symTranslate_file does formal symbol replacement for f_derivatives via "tranList [HFLN,Lucas].txt" This also runs "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols count in symLists.sh" which outputs : "d_temp/f_derivatives" - a new version of f_derivatives, using formal "tran[Expr,List] [HFLN,Lucas].txt tables lists of "unknown" symbols ([bad,new]) in f_derivatives (working files (not archived)) : "d_temp/symDiff bads $symSet.txt" - a simple text file listing, this will be used by other programs below "d_temp/symbols&count $symSet.txt" - shows the count of each "unknown" symbols, helpful to know scale of problems Explanation of code outputs, from "symTranslate_file" : symExtract_file - extracts all symbols from legal areas of f_derivation (pname_inn) ?? deleted ?? : symbols_compare_Lucas - producing symDiff files of "leftover symbols" symbols file counts Lucas.sh - produces log file append with file counts (of symbols) #] 3. manual classification of "d_temp/symDiff bads $symSet.txt" -> move symbols into appropriate symLists a) edit-run $ bash "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols classify manual.sh" $symSet Manually classify symbols in "d_temp/symDiff bads $symSet.txt" as [(t)ranList,tranE(x)pression,(g)ood,(e)nglish,equatio(n),(l)ater,(i)gnore] i) For symExprs : if problems are with "lower level" symbol components, just ignore it (i) ii) Ignore large symExprs that might have gone over one line of text (carry-over to next line of text) iii) b) check & clean-up : copy-paste symbols between [(t)ranslate,(g)ood,(e)nglish,equatio(n),(l)ater,(i)gnore] #] 4. manual edits of "d_temp/f_derivations" AND "d_temp/classed later $symSet.txt" Normally the list in "symDiff bads $symSet.txt" is too large for "symbol_finds" (see below) which lists [line#,symbol]. Therefore, in this step below, try to greatly reduce the list!!! a) check "symbols&count $symSet.txt" for symbols with zero counts : i) move (cut&paste) good symbols from "symDiff bads $symSet.txt" to "symDiff bads $symSet.txt" ii) delete bad symbols from b) check "d_temp/symDiff bads $symSet.txt" for large blocks of i) "correct" symbols -> MOVE (cut-paste) to "d_temp/classed good $symSet.txt ii) high counts of symbols in "symbols&count $symSet.txt" - where a "complete, erroneous symbol" is defined (eg parenthesis balance etc), do a direct search-&-replace in "d_temp/$f_derivatives", and delete associated symbols in "symDiff bads $symSet.txt" c) search-replace easy symbol problems - and REMOVE symbols from "d_temp/symDiff bads $symSet.txt" d) Do NOT search-replace "incomplete, erroneous symbols" (eg parenthesis DON'T balance etc) - instead classify these for translation in the next step. #] 5. manually edit "d_temp/classed translate $symSet.txt" : a) insert tabs to make columns align!! (should write an operator for that!!) # Column alignments : # trans Lucas->HFLN (L->H : # pattern replacement explanation # trans HFLN->Lucas (H->L) : # pattern replacement explanation a) qnial> symbol_finds (link d_QNial_temp 'classed translate HFLN.txt') (link d_QNial_temp '$f_derivatives') (link d_QNial_temp 'symbol_finds temp.txt') Outputs text file "symbol_finds [HFLN,Lucas].txt". QNial operator symbol_finds is in "symbols extract.ndf" b) $ bash "/media/bill/PROJECTS/Qnial/MY_NDFS/symbol_finds archive-move [HFLN,Lucas].sh" HFLN,Lucas select HFLN or Lucas above to archive_move "symbol_finds [HFLN,Lucas].txt" c) Remove "classed translate $symSet.txt" lines for symbols with NO output in "d_temp/symbol_finds temp.txt" i) possibly augment "symbols compliance POI.sh" with many more "atomic" symbols (worry about this later) ii) search-replace only "parenthetically complete" [syms,Exprs] eg (POIo(t))->(POIo(t),t) d) remove expressions from tranLists -> put directly into "d_Lucas/tranExpr $symSet.txt' #] 6. MANUALLY EDIT the "correct" (2nd column) symbols in "d_temp/classed translate $symSet.txt"!!!!************ a) CAUTIONS : i) do not "upgrade" symbols in tran[Lists,Exprs] : that will cause redundancies !!! ii) do NOT put tranExprs in tranLists! : these won't work (no effect) b) normally, corrections should be obvious - do these directly in "d_temp/classed translate $symSet.txt" c) using 'd_temp/symbol_finds temp.txt', find weird "orphan" symbols in f_derivation and make changes, make notes #] 7. Post-clean "symList good [HFLN,Lucas].txt" lists of good symbols : POI and parenthesis balance & matching compliance : a) qnial> symList_good_badPOIs IS OP d_inn d_tmp d_archive fname_inn extract BAD POI symbols from a file b) qnial> symList_good_fixPOIs IS OP d_inn d_tmp d_archive fname_inn fname_trn - replace bad symbols This also archives key files that are involved. c) qnial> symList_good_badParens IS OP d_inn d_out fname - generate list of lines with mis-matchd parenthesis d) manually fix in source file (maybe later - operator to do so "symList_good_fixParens") #] 8. edit-run $ bash "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols sort-archive-move, post-manual-class.sh" to archive-move lists of symbols : from "d_temp/classed [english,eqn#,{$symSet [good,ignore,later,transl]}].txt" to "d_Luca/[{symList [good,ignore,later,transl]},{tranList $symSet}].ndf" #] 9. check file appends and status, and make [corrections,recoveries,panic] as needed #] 10. qnial> ?symbol_checks? "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols ??.sh" to check for "bad" symbols in updated files : "d_Lucas/[symList good,tranList,tranExpr] $symSet.txt" (NOT needed as an occasional glance will do : "d_Lucas/symList [english,equation numbers]txt") a) parenthesis balance using "symList_good_badParens IS OP d_inn d_out fname" b) proper version of [POIx,t] for root variable z) make changes to files as appropriate #] 11. delete d_temp files: CAREFUL!!, then back to step#1 # 08********08 #] +-----+ #] CODE MODIFICATIONS To [modify, fix, augment, create new] code, extra information that allows the tracking of the origins of [symbols, expressions] is important. First, using a file of derivations (f_derivations), a file (f_derivations_converted) is created that - is in "standard symbol format" (vis sym_stdForm) - amalgamates lines of the Left-Hand-Side (LHS) and Right-Hand-Side (RHS) to get full expressions - has line numbers to be able to be able to cross-reference extracted symbols to the original "f_derivations". This is important for subsequent editing to [correct [symbols, expressions], identify coding problems] etc. For EACH of : $symSet=[HFLN,Lucas] Start by defining : qnial> f_derivations := link d_Lucas 'Howell - Background math for Lucas Universal Force, Chapter 4.txt' OR : qnial> f_derivations := link d_Lucas 'Howell - math of Lucas Universal Force.txt' #] 1. Re-start QNial qnial> BYE -> then launch qnial, qnial> lq_symBase -> to re-load Lucas symbols system #] 2. Run symDebug_file to generate output of [sym_stdForm, symExtract, symTranslate] to help fix code qnial> symDebug_file f_derivations d_QNial_temp symDebug_file runs 2 operators as described below : #] a) Create f_derivations_stdForm - consolidate lines with line#'s, output in standard format for symbols qnial> sym_stdForm_file f_derivations d_Lucas sym_stdForm_file is in "symbols system loaddefs.ndf" #] b) Create f_derivations_converted - translated [symbols, expressions] of f_derivations_stdForm qnial> symTranslate_file l f_derivations #] 3. Use debug output files to [modify, fix, augment, create new] code (manual procedures) #] a) Get an idea of how frequent is the problematic [symbol, expression] This might affect how or whether to proceed with code changes, or to simply change it's use in f_derivations a) copy the [symbol, expression] from "d_QNial_temp/symDiff bads [HFLN, Lucas].txt" b) find that [symbol, expression] in "symbols&count [HFLN, Lucas].txt" and note the number of times it occurs in f_derivations c) low-number -> ??? high-number -> ??? #] b) Locate a [symbol, expression] in f_derivations_stdForm a) copy the [symbol, expression] from "d_QNial_temp/symDiff bads [HFLN, Lucas].txt" b) find that [symbol, expression] in f_derivations_converted (there may be many occurences) and note the line number c) locate that line number in the original f_derivations #] c) ???? #] zzz. After that, decide on your approach to [modify, fix, augment, create new] code # 08********08 #] +-----+ #] OPERATORS THAT CAN BE USED SEPARATELY #] sym_stdForm IS OP symList - put [symbols,expressions] in standard format (remove [spaces,tabs], amalgamate lines) This script is run automatically by symExtract_file, so there won't normally be a need to run it separately see "d_QNial_mine/symbols system loaddefs.ndf" #] Generate a file listing [line-count,filename] of [syms,exprns] OR sym[Diff,List] files This script is run automatically by symExtract_file, so there won't normally be a need to run it separately see "d_QNial_mine/symbols count in file.sh" #] f_remove_extra_lineTypes IS OP pname_inn pname_out - removes lineTypes (single characters at start of line) see "d_QNial_mine/symbols translate.ndf" # 08********08 #] +-----+ #] TESTING OF SUPPORTING PROGRAMS : Normally, testing [ndf,development comment] files are kept in the directory "/media/bill/PROJECTS/Qnial/code develop_test". +-----+ #] [Convenient, multi-operator] test routines The tests help check for side effects [during,after] code [additions,changes]. They are based on a small but hoperfully diverse set of test examples for each operator. Standard answers are included as part of the tests, and [error, sucess] messages are generated. Historical testing results are automatically [dated, archived] for future reference. As per the section "Start-up loads" above, to load all test programs, type "lq_symTests" To run a test, simply append "_test" to the operator name as given in the subsections below. Example : qnial> symExtract_string_test Most tests output to the terminal by default. This can of course be redirected to a file, as per the example : qnial> symExtract_string >"" where is the directory and filename that will receive the output. >1 indicates stdout (terminal screen), which is the default of course. #] "strings- tests.ndf" tests : # str_to_unicodeList IS OP str - convert a string to a list of unicode characters # string_sub IS OP sub_old sub_new str - substitutes sub_new for sub_old in str # sym_stdForm_test IS - - to put [symbols,expressions] in a standard format for comparison - mostly remove [spaces,tabs] # strings_alltest IS - to run ALL string tests, save results to file #] "symbols extract- tests.ndf" tests : # symParen_contents IS OP sym_in - delve into 1st level of parenthesis to extract contents (simply remove 1st paren & matching end paren) # syms_inParens IS OP symList - to extract symbols RECURSIVELY from parenthesized expressions # - recursive stop is by implicit nulls & error conditions stopping loops without damaging returns? # symExtract_stringPosn IS OP str_stdForm - extracts symbol [characters, type, position]s from a string in standard format # symExtract_string IS OP str - returns only symbol [characters, type]s (not positions) from a string in standard format # uses symExtract_stringPosn # symExtract_alltest IS - run all the symbols extract tests, save results to file Later I will have test files & results: # symExtract_file IS OP pname_inn pname_Lucas pname_HFLN - to extract a list of [all, known, unkown] symbols # from a text file, with reference to a dictionary, ignoring comments and descriptions #] In "symbols translate- tests.ndf" : # symTranslate_all_test IS - test correctness of "low-level" translation of of [syms,exprs] examples # symTranslate_file_test IS - test full [extraction,translation] of [syms,exprs] in an f_derivation file The results must be checked and processed manually It is dangerous to make mistakes, as a lot of subsequent work on f_derivations could be lost or hard to [edit,correct] Also check for general messages : "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols translate file_test log.txt" also shows historical symList line-counts #] symbols_Strings_Extract_Translate_alltest #] $ bash "/media/bill/PROJECTS/Qnial/MY_NDFS/symbols sort unique Lucas.sh" - IMPORTANT! edit the file to do symList sorting one-at-a-time after doing the manual editing after symTranslate_file_test #] +-----+ #] WARNING : 30Aug2018 13:19 LMDE2 uses SIGNED bytes, RaspPi UNSIGNED!! # in "str_to_unicodeList IS OP str " definition in "strings.ndf" : LMDE2 : IF (charrepList@i < 0) THEN RaspPi : IF (charrepList@i > 127) THEN >> I need to code this automatically someday # 08********08 #] +-----+ #] CODING ADVICE If you add a new trans_table, using HFLN_to_Lucas as an example : - It may be easiest to copy the file of an existing trans_table In "/media/bill/PROJECTS/Lucas - Universal Force/" : $ cp "symList good Lucas_to_HFLN.txt" "symList good HFLN_to_Lucas.txt" $ cp "symList bads Lucas_to_HFLN.txt" "symList bads HFLN_to_Lucas.txt" In each of the new files : search-replace [file,variable] names : Lucas_to_HFLN -> HFLN_to_Lucas Block copy the initial column in [trans,transExpr]_HFLN_to_Lucas Manually edit the lines in [trans,transExpr]_HFLN_to_Lucas : Redundant first column : collect second-column variables, eg '{B(r´,t´)E(r´,v´)E(r´,t´)}' Delete vacated redundant lines Remove illegitimate variable lines (maybe leave some common errors to translate) - Catenate & sort existing symLists as a start for the new trans_table (if appropriate), example : # Initialize Lucas_to_HFLNs # $ cd "/media/bill/PROJECTS/Lucas - Universal Force/" # $ cat "symList good Lucas.txt" "symList good HFLN.txt" >"/media/bill/ramdisk/temp1.txt" # $ sort --unique "/media/bill/ramdisk/temp1.txt" >"symList good Lucas_to_HFLN.txt" # $ cat "symList bads Lucas.txt" "symList bads HFLN.txt" >"/media/bill/ramdisk/temp1.txt" # $ sort --unique "/media/bill/ramdisk/temp1.txt" >"symList bads Lucas_to_HFLN.txt" If this isn't appropriate, wait for lists to be generated by symTranslate_file_test, and manually edit thos, creating a [good,bad] list file # 08********08 #] +-----+ #] APPENDIX 1 - Listing of [data, operators] : generated by : $ find "/media/bill/PROJECTS/Qnial/MY_NDFS/" -maxdepth 1 -name "*symbols *" | tr \\n \\0 | xargs -0 -IFILE grep --with-filename --line-number "^#.*IS OP" "FILE" > manually clean up (mostly retain only first listing of a filepath, [names, argLists] for several operators out of date) /media/bill/PROJECTS/Qnial/MY_NDFS/symbols fix instructions.txt: 444:# str_to_unicodeList IS OP str - convert a string to a list of unicode characters 445:# string_sub IS OP sub_old sub_new str - substitutes sub_new for sub_old in str 451:# symParen_contents IS OP sym_in - delve into 1st level of parenthesis to extract contents (simply remove 1st paren & matching end paren) 452:# syms_inParens IS OP symList - to extract symbols RECURSIVELY from parenthesized expressions 454:# symExtract_stringPosn IS OP str_stdForm - extracts symbol [characters, type, position]s from a string in standard format 455:# symExtract_string IS OP str - returns only symbol [characters, type]s (not positions) from a string in standard format 460:# symExtract_file IS OP pname_inn pname_Lucas pname_HFLN - to extract a list of [all, known, unkown] symbols /media/bill/PROJECTS/Qnial/MY_NDFS/symbols system loaddefs.ndf: 55:# sym_stdForm IS OP str - to put strings in a standard format for [symbols,expressions] - mostly remove [spaces,tabs] 118:# sym_stdForm_file IS OP pname_inn d_out - consolidate lines with line#'s, output in standard format for symbols 177:# symParen_file IS OP d_inn d_out fname_base - consolidate lines with line#'s, output in standard format /media/bill/PROJECTS/Qnial/MY_NDFS/symbols fix.ndf: 49:# symbol_check_POI_format IS OP symChrList - check if POI format is standard 150:# strExtract_POIs IS OP str - extract POI symbols from a string 212:# symList good_badPOIs IS OP d_inn d_out d_archive fname_inn - extract BAD POI symbols from a file 279:# symList_good_fixPOIs IS OP d_inn d_out d_archive fname_inn fname_trn - replace bad POI in a "symList good" file 343:# symList_good_badParens IS OP d_inn d_out fname_inn - generate a fileList of unbalanced parenthesis in a "symList good" file 421:# symList_good_fixParens IS OP d_inn d_out d_archive fname_inn fname_trn - fix parenthesis in a "symList good" file 437:# file_consolidate_lines IS OP pname_inn pname_out - to 446:# symParen_file_bads IS OP d_inn d_out fname_base - consolidate lines with line#'s, output in standard format /media/bill/PROJECTS/Qnial/MY_NDFS/symbols extract.ndf: 75:# symbol_find IS OP sym_in p_sorc f_outr - find one [normal,weird,orphan] symbol in file, output line#, line 113:# symbol_finds IS OP p_tranList p_sorc p_outr - find tranList [normal,weird,orphan] symbols in file, output line#, line 134:# symParen_contents IS OP sym_in - delve into 1st level of parenthesis to extract contents (simply remove 1st paren & matching end paren) 182:# syms_inParens IS OP symList - to extract symbols RECURSIVELY from parenthesized expressions 254:# strStd_extract_symParnPosn IS OP str_stdForm - extracts symParns from a "standard format string" (sym_stdForm str) 350:# symbols_compare IS OP pn_Lucas pn_HFLN - compare a list of extracted symbols to known symbol lists 391:# file_extract_symParn IS OP pname_stdForm_inn d_out - to extract a list of [all, known, unknown] parn symbols /media/bill/PROJECTS/Qnial/MY_NDFS/symbols translate.ndf: 138:# file_remove_extra_lineTypes IS OP pname_inn pname_out - removes lineTypes (single characters at start of line) 175:# trnInfo IS OP tblName - get translation table info [trn_len trn_new], latter two are strings 209:# strOfType_extract_symGenls IS OP strOfType tblType - produces a list of expressions in strOfType 235:# strOfType_translate_symGenl IS OP strOfType - [extract, translate] cart sym[Parn,Expr] 307:# strStdForm_extractTranslate_symGenl IS OP str_stdForm - prepares a string and a sed expression 354:# file_translate IS OP pname_stdForm_inn d_out - [extraction,translation] of [syms,exprs] in Lucas f_derivation file 426:# file_translate_debug IS OP pname_inn d_out - generate output of [sym_stdForm, symExtract, symTranslate] to help fix code /media/bill/PROJECTS/Qnial/MY_NDFS/symbols zProcess notes.txt: 331:# fileread_list IS OP pname -> from fileops.ndf 357:# fileread_list IS OP pname -> from fileops.ndf # enddoc