EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  <20202021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  <20202021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: matrix multiplication and inversions
From: "Johnson, Andrew N. via Tech-talk" <tech-talk at aps.anl.gov>
To: "Pearson, Matthew R." <pearsonmr at ornl.gov>
Cc: tech-talk <tech-talk at aps.anl.gov>
Date: Thu, 20 Feb 2020 03:36:08 +0000
Hi Matt,

About 25 years ago (wow, was it really?) John Maclean and I devised the controls for the Gemini primary mirror where the IOC did various matrix calculations before passing the results to the dynamic support system actuators via CANbus. We did the maths in subroutine record sub’s using shared global variables to store the small number of large matrices we had to handle, and only used the sub-records to control when the calculations were executed (and to hold scalar parameters and results). We also used waveform records with “devSymb” device support to read and write the shared global variables, although I don’t remember how we synchronized everything to prevent races. The aSub didn’t exist at the time, although Gemini did soon devise the genSub that was its precursor.

Nowadays I would certainly explore your idea of using aSub’s with a standard matrix library. Copying a 5x5x8=200 byte array across a DB link should be reasonably fast as long as you don’t need to do it too much (our matrices were considerably larger and the CPU much slower back then).

HTH,

- Andrew

-- 
Sent from my iPad

> On Feb 19, 2020, at 4:49 PM, Pearson, Matthew R. via Tech-talk <tech-talk at aps.anl.gov> wrote:
> 
> 
> Hi,
> 
> I’m starting a project involving calculating neutron guide positions where the positions are defined by 5 cam based movers. The position calculations involve 5x5 matrix multiplication and inversions, and some of the matrix elements are trigonometric functions. 
> 
> I’m prototyping the calculations in Python, but does anyone have advice on how to implement the calculations in an EPICS database? My first thought is to use aSub records (or a custom record) linking to GSL libraries. 
> 
> I suspect similar work is routinely done on accelerator controls?
> 
> Cheers,
> Matt
> 
> 
> Data Acquisition and Controls Engineer
> Spallation Neutron Source
> Oak Ridge National Lab
> 
> 
> 
> 
> 
> 
> 

Replies:
Re: [EXTERNAL] matrix multiplication and inversions Pearson, Matthew R. via Tech-talk
Re: matrix multiplication and inversions Matt Rippa via Tech-talk
References:
matrix multiplication and inversions Pearson, Matthew R. via Tech-talk

Navigate by Date:
Prev: Re: matrix multiplication and inversions Michael Davidsaver via Tech-talk
Next: RE: matrix multiplication and inversions [SEC=UNOFFICIAL] STARRITT, Andrew via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  <20202021  2022  2023  2024 
Navigate by Thread:
Prev: Re: matrix multiplication and inversions Michael Davidsaver via Tech-talk
Next: Re: [EXTERNAL] matrix multiplication and inversions Pearson, Matthew R. via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  <20202021  2022  2023  2024 
ANJ, 21 Feb 2020 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·