Photonics

Photonics

Time domain scripting for dipole source

    • MANNAN
      Subscriber
    • Guilin Sun
      Ansys Employee
      you can use set(set time domain,1); to enable a tab property. One this is enabled, you can set other properties, as you did in the script, such asnset(offset,3e-12);nplease note that the units in scripting are international standard, meter, second, kg etc.nnyou can usen?set; when an object is selected to know all its parametersnorn?setnamed(object_name) to know the parameters for a specific object.nnPlease try and check if all the set results are what you expect.n
    • Guilin Sun
      Ansys Employee
      Please note that since the source is a pulse, even through you set the wavelength bandwidth zero, it will still be a pulse, meaning it will radiate em waves in a broadband. n
    • MANNAN
      Subscriber
      Thanks a lot it worked n
    • Guilin Sun
      Ansys Employee
      Thank you for letting me know this! good luck in your project!n
    • MANNAN
      Subscriber
      Could you please further help in regarding the thisx=linspace(-d/2,d/2,N); # x position vectornnfor (i=1:N) {nadddipole;nset(x,x(i)); nset(y,0);nset(z,0);n}nThis code will make a line of N dipoles along the x-axis between length -d till d. with equal spacingnnSuggestions required in making a script that will make a cone of dipole along xz direction with radius r in x-direction and depth along z-axis nnLooking forward to hearing soon
    • Guilin Sun
      Ansys Employee
      The code looks good for me. In order to make the dipoles to be in a cone in xz plane, you will need to change x(i) and z(i) as a cone, and then place the dipoles there. Please try to modify your script.n
Viewing 6 reply threads
  • You must be logged in to reply to this topic.