Home > lattice > Paramgroup > saveparamgroup.m

saveparamgroup

PURPOSE ^

SAVEPARAMGROUP saves the values of multiple physical

SYNOPSIS ^

function NEWPARAMGROUP = saveparamgroup(LATTICE,PARAMGROUP)

DESCRIPTION ^

SAVEPARAMGROUP saves the values of multiple physical 
 parameters of the lattice in the special SavedValue field of 
 AT parameter group structure. The result can be late used 
 with RESTOREPARAMGROUP

 PARAMGROUP = saveparamgroup(LATTICE,PARAMGROUP)
 
 See also: ATPARAMGROUP RESTORPARAMGROUP SETPARAMGROUP

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function NEWPARAMGROUP = saveparamgroup(LATTICE,PARAMGROUP)
0002 %SAVEPARAMGROUP saves the values of multiple physical
0003 % parameters of the lattice in the special SavedValue field of
0004 % AT parameter group structure. The result can be late used
0005 % with RESTOREPARAMGROUP
0006 %
0007 % PARAMGROUP = saveparamgroup(LATTICE,PARAMGROUP)
0008 %
0009 % See also: ATPARAMGROUP RESTORPARAMGROUP SETPARAMGROUP
0010 
0011 NEWPARAMGROUP=PARAMGROUP;
0012 
0013 for i=1:length(PARAMGROUP)
0014    NEWPARAMGROUP(i).SavedValue = ...
0015        getfield(LATTICE{PARAMGROUP(i).ElemIndex},...
0016        PARAMGROUP(i).FieldName,PARAMGROUP(i).FieldIndex);
0017 end

Generated on Thu 24-Aug-2017 18:47:33 by m2html © 2005