code: public SDVariable setDiag(String name, SDVariable in, SDVariable diag) {
          SDVariable ret = f().setDiag(in, diag);
          return updateVariableNameAndReference(ret, name);
      }
docs: Set the diagonal value to the specified values<br>
  If input is<br>
  [ a, b, c]<br>
  [ d, e, f]<br>
  [ g, h, i]<br>
  and diag = [ 1, 2, 3] then output is<br>
  [ 1, b, c]<br>
  [ d, 2, f]<br>
  [ g, h, 3]<br>
  
  @param name Name of the output variable
  @param in   Input variable
  @param diag Diagonal
  @return Output variable