NARX Neuronal Network with feedback target AND non-feedback target?
1 view (last 30 days)
Show older comments
Hello guys, I'm trying to train a NARX Network by seriell-parallel training to simulate later in parallel mode.
My problem is that I want to have 3 Inputs and 2 Outputs, so that the 3 Inputs are not delayed, while 1 Output is delayed and recurrent. The other Output is just a normal Output.
In my understanding I would define the recurrent Output as feedback-target and the standard Output as a non feedback target. Here is my code:
%%delay
dly1 = 0;
dly2 = 1;
n1= 10;
u = [Input2.VEH_v';Input2.Gradient';Input2.a'];
y1 = [Input2.ENG_fr'];
y2 = [Input2.SOC'];
u1 = con2seq(u);
y3 = con2seq(y1);
y4 = con2seq(y2);
narx_net = narxnet(dly1,dly2,n1);
narx_net.divideFcn = '';
narx_net.trainParam.min_grad = 1e-10;
[p,Pi,Ai,t] = preparets(narx_net,u1,y3,y4);
narx_net = train(narx_net,p,t,Pi);
I always get the error: "Error using preparets (line 175) Number of output signals does not match number of network's non-feedback outputs."
Can you please help me solve my problem?
1 Comment
Kylie Meier
on 8 Apr 2022
Hello, I am having a similar issue and would be curious to know the answer to your question. I am wondering if a closed loop or open loop has any affect on this as well.
Answers (0)
See Also
Categories
Find more on Modeling and Prediction with NARX and Time-Delay Networks in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!