예제 #1
0
 def func2():
     F = geteval(core, 'tempF')
     vl = geteval(core, 'vl')
     JacFl = jacobian(F, vl)
     return list(
         regularize_dims(sp.Matrix(F)) -
         matvecprod(JacFl, sp.Matrix(vl)))
예제 #2
0
 def func2():
     temp = sp.zeros(len(geteval(core, 'v')), 1)
     v = geteval(core, 'v')
     Mvv = geteval(core, 'Mvv')
     Mvy = geteval(core, 'Mvy')
     temp += matvecprod(core.I(''), sp.Matrix(v))
     temp -= matvecprod(Mvv, sp.Matrix(core.f()))
     temp -= matvecprod(Mvy, sp.Matrix(core.u))
     return list(temp)
예제 #3
0
 def func():
     Fn1 = geteval(core, 'tempF' + n1)
     vl = geteval(core, 'vl')
     JacFn1l = geteval(
         core,
         'jacF' + n1 + 'l',
     )
     return list(
         regularize_dims(sp.Matrix(Fn1)) -
         matvecprod(JacFn1l, sp.Matrix(vl)))
예제 #4
0
 def func():
     temp = sp.zeros(len(geteval(core, 'v' + n1)), 1)
     v = geteval(core, 'v' + n1)
     Mvvl = geteval(core, 'Mv' + n1 + 'vl')
     Mvvnl = geteval(core, 'Mv' + n1 + 'vnl')
     Mvy = geteval(core, 'Mv' + n1 + 'y')
     temp += matvecprod(core.I(n1), sp.Matrix(v))
     temp -= matvecprod(Mvvl, sp.Matrix(core.fl()))
     temp -= matvecprod(Mvvnl, sp.Matrix(core.fnl()))
     temp -= matvecprod(Mvy, sp.Matrix(core.u))
     return list(temp)
예제 #5
0
파일: method.py 프로젝트: loicforma/pyphs
 def init_args(self):
     def names_lnl(s):
         return [s, s+'l', s+'nl']
     for n in ['x', 'dx', 'w', 'u', 'p', 'v']:
         for name in names_lnl(n):
             try:
                 arg = geteval(self.core, name)
                 self.setarg(name, arg)
             except AttributeError:
                 pass
예제 #6
0
 def func():
     G, v = geteval(core, 'G' + n1), geteval(core, 'v' + n2)
     return jacobian(G, v)
예제 #7
0
 def func():
     F, v = geteval(core, 'tempF' + n1), geteval(core, 'v' + n2)
     return jacobian(F, v)
예제 #8
0
 def func():
     output = geteval(core, 'dxH' + n1) + geteval(core, 'z' + n1)
     return output
예제 #9
0
 def build_struc(self):
     for name in list(self.core.struc_names):
         self.setfunc(name, geteval(self.core, name))
예제 #10
0
 def init_funcs(self):
     for name in list(self.core.exprs_names):
         if not hasattr(self, name + '_expr'):
             self.setfunc(name, geteval(self.core, name))
     self.setfunc('y', geteval(self.core, 'output'))
     self.setfunc('fs', self.fs)
예제 #11
0
파일: method.py 프로젝트: loicforma/pyphs
 def func():
     G, v = geteval(core, 'G'+a), geteval(core, 'v'+b)
     return jacobian(G, v)
예제 #12
0
파일: method.py 프로젝트: loicforma/pyphs
 def func():
     Fa = geteval(core, 'tempF'+a)
     vl = geteval(core, 'vl')
     JacFal = geteval(core, 'jactempF'+a+'l',)
     return list(regularize_dims(sp.Matrix(Fa)) -
                 matvecprod(JacFal, sp.Matrix(vl)))
예제 #13
0
파일: method.py 프로젝트: loicforma/pyphs
 def func():
     output = geteval(core, 'dxH'+suffix)+geteval(core, 'z'+suffix)
     return output
예제 #14
0
파일: method.py 프로젝트: loicforma/pyphs
 def func():
     "Getter"
     output = geteval(core, 'dx'+suffix)+geteval(core, 'w'+suffix)
     return output