Jump to content

NimbleThink

Members
  • Posts

    5
  • Joined

  • Last visited

Everything posted by NimbleThink

  1. Has anyone coded up an orthogonal fit regression? This is a Model II regression (error in both Y and X variables). It may be known by references to Deming models or to early published work by York [1]. It is used to perform a linear fit when you have error in both X and Y. Thanks. [1] LEAST-SQUARES FITTING OF A STRAIGHT LINE Derek York Can. J. Phys./Rev. can. phys. 44(5): 1079-1086 (1966)
  2. Depending on what algorithm you require for postprocessing there are open-source programs which can perform the post-processing for you. I use "R" a lot; an open-source version of S-plus, a statistical programming language invented at AT&T Bell Labs. It has many powerful statistical functions and excellent graphics capabilities (better than LabVIEW). The only post-processing I do in LabVIEW are those requiring specialized signal analysis such as trigger detection, FFT's, etc. Leif Kirschenbaum
  3. I think you are on the right track with an array of tasks, however the tracking of the tasks is a problem, as you say. I am working on a similar situation where I have multiple references for various instruments and I need to keep track of what role each instrument performs. My suggestion: create a global which is a cluster put in this cluster an array of tasks add an array of strings [optional] create an ENUM, customize it, edit the list of items and create an item for each valve type ("in", "out", etc.) and save it as a Type Def. customized control. add an array of ENUM Now when you initialize your system you create an array of tasks. At the same time create an array of strings labelling these tasks, in fact you could cleverly construct these strings like "IN:water", "OUT:water", "IN:blue dye", "OUT:HF", or whatever you need. Then write both the array of tasks and the array of strings into the global. Later when you need the valve which controls water output, read the string array from the global, then search the array for the string "OUT:water". (In fact if you have logic which specifies the liquid name and the valve direction you could programmitically construct the search string using the concatenation function.) Then read the tasks array and use the index from the string array search to retrieve the proper task. This way you don't need to keep track of the order of the tasks, you only need to make sure that when you initialize your program that the tasks and the string descriptions are saved in matching order. If needed you can put error checking later in your program which will read the tasks array and the strings array from the global and check to see if they are the same length: if they are not, then throw and error and gracefully exit with a dialog. Best of luck. Leif Kirschenbaum
  4. I have need to replicate elements in an array. The "Interleave 1D Arrays" is not feasible due to: 1) too large a number of replicates (>5) 2) variable number of replicates (345, 625, etc.) I know that a For loop (with a pre-initialized array of size length M x number of replicates N) could work, however I avoid them (for speed) and so came up with the following: Multiply the input array with an array populated with the number of replicates using the Outer Product then reshape from a 2D array back to a 1D array. Any other suggestions?
  5. Here are some questions: Can you convert a sequence structure to a state machine? [assuming that they answer "yes"] Please explain all the advantages and disadvantages of a state machine versus a sequence structure. How might you implement a state machine where the next state not only depends on the current state but also the prior state? -Leif Kirschenbaum QUOTE (jlokanis @ Aug 20 2008, 09:32 AM)
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.