<!-- BaNnErBlUrFlE-BoDy-start -->
<!-- Preheader Text : BEGIN -->
<div style="display:none !important;display:none;visibility:hidden;mso-hide:all;font-size:1px;color:#ffffff;line-height:1px;height:0px;max-height:0px;opacity:0;overflow:hidden;">
Dear all, I want to monitor the results at each iteration of TS using vtk format. To do so, I add the following lines to my Monitor function: char vts_File_Name[MAXC]; PetscCall(PetscSNPrintf(vts_File_Name, sizeof(vts_File_Name), ". /xi-MgHx-hcp-cube-x5-x5-x5-TS-BE-%i. vtu",
</div>
<!-- Preheader Text : END -->
<!-- Email Banner : BEGIN -->
<div style="display:none !important;display:none;visibility:hidden;mso-hide:all;font-size:1px;color:#ffffff;line-height:1px;height:0px;max-height:0px;opacity:0;overflow:hidden;">ZjQcmQRYFpfptBannerStart</div>
<!--[if ((ie)|(mso))]>
<table border="0" cellspacing="0" cellpadding="0" width="100%" style="padding: 16px 0px 16px 0px; direction: ltr" ><tr><td>
<table border="0" cellspacing="0" cellpadding="0" style="padding: 0px 10px 5px 6px; width: 100%; border-radius:4px; border-top:4px solid #90a4ae;background-color:#D0D8DC;"><tr><td valign="top">
<table align="left" border="0" cellspacing="0" cellpadding="0" style="padding: 4px 8px 4px 8px">
<tr><td style="color:#000000; font-family: 'Arial', sans-serif; font-weight:bold; font-size:14px; direction: ltr">
This Message Is From an External Sender
</td></tr>
<tr><td style="color:#000000; font-weight:normal; font-family: 'Arial', sans-serif; font-size:12px; direction: ltr">
This message came from outside your organization.
</td></tr>
</table>
</td></tr></table>
</td></tr></table>
<![endif]-->
<![if !((ie)|(mso))]>
<div dir="ltr" id="pfptBannervim1dsw" style="all: revert !important; display:block !important; text-align: left !important; margin:16px 0px 16px 0px !important; padding:8px 16px 8px 16px !important; border-radius: 4px !important; min-width: 200px !important; background-color: #D0D8DC !important; background-color: #D0D8DC; border-top: 4px solid #90a4ae !important; border-top: 4px solid #90a4ae;">
<div id="pfptBannervim1dsw" style="all: unset !important; float:left !important; display:block !important; margin: 0px 0px 1px 0px !important; max-width: 600px !important;">
<div id="pfptBannervim1dsw" style="all: unset !important; display:block !important; visibility: visible !important; background-color: #D0D8DC !important; color:#000000 !important; color:#000000; font-family: 'Arial', sans-serif !important; font-family: 'Arial', sans-serif; font-weight:bold !important; font-weight:bold; font-size:14px !important; line-height:18px !important; line-height:18px">
This Message Is From an External Sender
</div>
<div id="pfptBannervim1dsw" style="all: unset !important; display:block !important; visibility: visible !important; background-color: #D0D8DC !important; color:#000000 !important; color:#000000; font-weight:normal; font-family: 'Arial', sans-serif !important; font-family: 'Arial', sans-serif; font-size:12px !important; line-height:18px !important; line-height:18px; margin-top:2px !important;">
This message came from outside your organization.
</div>
</div>
<div style="clear: both !important; display: block !important; visibility: hidden !important; line-height: 0 !important; font-size: 0.01px !important; height: 0px"> </div>
</div>
<![endif]>
<div style="display:none !important;display:none;visibility:hidden;mso-hide:all;font-size:1px;color:#ffffff;line-height:1px;height:0px;max-height:0px;opacity:0;overflow:hidden;">ZjQcmQRYFpfptBannerEnd</div>
<!-- Email Banner : END -->
<!-- BaNnErBlUrFlE-BoDy-end -->
<html>
<head><!-- BaNnErBlUrFlE-HeAdEr-start -->
<style>
#pfptBannervim1dsw { all: revert !important; display: block !important;
visibility: visible !important; opacity: 1 !important;
background-color: #D0D8DC !important;
max-width: none !important; max-height: none !important }
.pfptPrimaryButtonvim1dsw:hover, .pfptPrimaryButtonvim1dsw:focus {
background-color: #b4c1c7 !important; }
.pfptPrimaryButtonvim1dsw:active {
background-color: #90a4ae !important; }
</style>
<!-- BaNnErBlUrFlE-HeAdEr-end -->
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">
<div>Dear all, </div>
<div><br>
</div>
<div>I want to monitor the results at each iteration of TS using vtk format. To do so, I add the following lines to my Monitor function:</div>
<div><br>
</div>
<div>
<div style="color: rgb(46, 46, 46); background-color: rgb(255, 255, 255); font-family: Menlo, Monaco, "Courier New", monospace; line-height: 18px; white-space: pre;">
<div><span style="color: rgb(63, 151, 223);">char</span> <span style="color: rgb(9, 89, 132);">
vts_File_Name</span><span style="color: rgb(94, 94, 94);">[</span><span style="color: rgb(19, 10, 100);">MAXC</span><span style="color: rgb(94, 94, 94);">];</span></div>
<div><span style="color: rgb(69, 69, 69);">PetscCall</span><span style="color: rgb(94, 94, 94);">(</span><span style="color: rgb(99, 99, 36);">PetscSNPrintf</span><span style="color: rgb(94, 94, 94);">(</span><span style="color: rgb(9, 89, 132);">vts_File_Name</span><span style="color: rgb(94, 94, 94);">,</span>
<span style="color: rgb(63, 151, 223);">sizeof</span><span style="color: rgb(94, 94, 94);">(</span><span style="color: rgb(9, 89, 132);">vts_File_Name</span><span style="color: rgb(94, 94, 94);">),</span></div>
<div><span style="color: rgb(81, 43, 25);">"</span><span style="color: rgb(162, 86, 55);">./xi-MgHx-hcp-cube-x5-x5-x5-TS-BE-</span><span style="color: rgb(9, 89, 132);">%i</span><span style="color: rgb(162, 86, 55);">.vtu</span><span style="color: rgb(81, 43, 25);">"</span><span style="color: rgb(94, 94, 94);">,</span>
<span style="color: rgb(126, 126, 126);">step</span><span style="color: rgb(94, 94, 94);">));</span></div>
<div><span style="color: rgb(69, 69, 69);">PetscCall</span><span style="color: rgb(94, 94, 94);">(</span><span style="color: rgb(99, 99, 36);">TSMonitorSolutionVTK</span><span style="color: rgb(94, 94, 94);">(</span><span style="color: rgb(126, 126, 126);">ts</span><span style="color: rgb(94, 94, 94);">,</span>
<span style="color: rgb(126, 126, 126);">step</span><span style="color: rgb(94, 94, 94);">,</span>
<span style="color: rgb(126, 126, 126);">time</span><span style="color: rgb(94, 94, 94);">,</span>
<span style="color: rgb(126, 126, 126);">X</span><span style="color: rgb(94, 94, 94);">,</span>
<span style="color: rgb(94, 94, 94);">(</span><span style="color: rgb(63, 151, 223);">void</span><span style="color: rgb(94, 94, 94);">*)</span><span style="color: rgb(9, 89, 132);">vts_File_Name</span><span style="color: rgb(94, 94, 94);">));</span></div>
</div>
</div>
<div><br>
</div>
<div>My script compiles and executes without any sort of warning/error messages. However, no output files are produced at the end of the simulation. I’ve also tried the option “<span class="pre" style="white-space: nowrap; box-sizing: border-box; hyphens: none; caret-color: rgb(123, 45, 90); color: rgb(123, 45, 90); font-family: SFMono-Regular, Menlo, Consolas, Monaco, "Liberation Mono", "Lucida Console", monospace; font-size: 13.125px;">-ts_monitor_solution_vtk</span><span style="caret-color: rgb(123, 45, 90); color: rgb(123, 45, 90); font-family: SFMono-Regular, Menlo, Consolas, Monaco, "Liberation Mono", "Lucida Console", monospace; font-size: 13.125px; background-color: rgb(255, 255, 255);"> </span><span class="pre" style="white-space: nowrap; box-sizing: border-box; hyphens: none; caret-color: rgb(123, 45, 90); color: rgb(123, 45, 90); font-family: SFMono-Regular, Menlo, Consolas, Monaco, "Liberation Mono", "Lucida Console", monospace; font-size: 13.125px;"><filename-%03D.vts></span>”,
but I got no results as well. </div>
<div><br>
</div>
<div><span style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0);">I can’t find any similar example on the petsc website and I don’t see what I am doing wrong. Could somebody point me to the right direction?</span></div>
<div><br>
</div>
<div>Thanks,</div>
<div>Miguel</div>
<br>
<br>
</body>
</html>