Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
Operators not allowed in user-defined functions
Posted 28 feb 2022, 05:05 GMT-5 RF & Microwave Engineering, Wave Optics, General Version 5.6 1 Reply
Please login with a confirmed email address before reporting spam
Dear all,
I am trying to generate a pulse train using a step function in combination with an analytic function using a summation but it seems like the operator "sum" is not allowed and it generates the error "Operators not allowed in user-defined functions". Does anyone know how can I use the sum operator in comsol or how to define sigma notation for summation? I have used sum(expr,index,lower,upper).
STEP Location: tp from: 1 to: 0
ANALYTIC Expression: sum( S( t-(Np*(1/fr)) ) - S( t-(Np+tp) ), Np, 0, Np-1 ) arguments: t
sum(expr,index,lower,upper); operator sum as defined in comsol
Np: number of pulses fr: repetition rate tp: pulse duration