Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
create valid COMSOL solution from MATLAB vector
Posted 3 giu 2010, 14:50 GMT-4 0 Replies
Please login with a confirmed email address before reporting spam
I need to create a valid COMSOL solution from a MATLAB vector. In 3.5a I could use the femsol function.
I have tried these commands on an existing solution but received the error "Solution not initialized"
PVals = model.sol('sol1').getPVals
PNames = model.sol('sol1').getPNames
model.sol('sol1').clearSolution()
model.sol('sol1').setU(-0.1*ones(size(model.sol('sol1').getU)))
model.sol('sol1').setPVals(PVals)
model.sol('sol1').setPNames(PNames)
model.sol('sol1').createSolution()
Any help is appreciated!
Hello Laurin Wissmeier
Your Discussion has gone 30 days without a reply. If you still need help with COMSOL and have an on-subscription license, please visit our Support Center for help.
If you do not hold an on-subscription license, you may find an answer in another Discussion or in the Knowledge Base.