title: Can I derive a register name (available in regmodel) from string
body: <p>I've a simple sequence</p>
  
  <pre><code> regmodel.REGx.write (...)
  </code></pre>
  
  <p>Lets consider I've 8 registers under regmodel viz. REG0, REG1, REG2,....,REG7
  I would like to pass number as a test plus argument, say +NUM=4</p>
  
  <p>Using $sformat or $psprintf, I can create string variable with proper register name
  for e.g.</p>
  
  <pre><code>  if ($value$plusargs ("NUM=%0d", num))
      $display ("Testcase passed %0d num", num);
    else
      num   = 0;
    $sformat (regName, "REG%0d", num);
  </code></pre>
  
  <p>now I've regName but I can't use following:</p>
  
  <pre><code>   regmodel.regName.write (...)
  </code></pre>
  
  <p>regName is of type string and regmodel doens't have any register names regName, Is there any other way to achieve this? I was looking at get_name, get_full_name but those couldn't help in this case.</p>
  
  <p>For now I can have if - else 8 times or a case statement, however it would be really inconvenient for large number of registers.</p>