function buttontransformRAY(hObject, eventdata, parentfig, Empty_Button, Buttons, Footnote, AxesAFS, AxesSOL, Plotsettings, lcs, usmn, usmf, SegTrafo)
set(usmn,'Value',0);
set(usmf,'Value',1);
part = get(hObject,'UserData');
data = get(Empty_Button,'UserData');

save testklein data

if (isfield(data,'ismatrix')*isfield(data,'isnmf')*isfield(data,'isafs') == 0) || (data.ismatrix*data.isnmf*data.isafs == 0)
    if data.ismatrix == 0 set(Footnote,'String',' Warning, no data has been loaded.','ForegroundColor','red');return;end
    if data.isnmf == 0 set(Footnote,'String',' Warning, no NMF has been computed.','ForegroundColor','red');return;end
    if data.isafs == 0 set(Footnote,'String',' Warning, no AFS has been computed.','ForegroundColor','red');return;end
end

bndpts = getsetvar(Plotsettings(1), 1, 200, 1, 1);
nx     = getsetvar(Plotsettings(2), 0, 50, 1, 1);

pv = get(SegTrafo, 'Value');

[data.Sol,tim] = transformRAY(data,bndpts,nx,pv,Footnote,1);

if isempty(data.Sol.A)
    data.Sol.T = data.InitT(pv,:);
    data.Sol.A = data.InitT(pv,:)*data.V';
end

plot(AxesSOL,data.x,data.Sol.A,'color',lcs(pv,:));

set(AxesSOL, 'XLim',data.x([1 end]), 'YLim', [min(0,min(min(data.Sol.A))), max(max(data.Sol.A))]);
